mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
translations fo true/false yes /no
This commit is contained in:
parent
2be78f5d4c
commit
7a0a901c2b
@ -268,6 +268,10 @@ function loadBomTable(table, options) {
|
|||||||
field: 'optional',
|
field: 'optional',
|
||||||
title: '{% trans "Optional" %}',
|
title: '{% trans "Optional" %}',
|
||||||
searchable: false,
|
searchable: false,
|
||||||
|
formatter: function(value) {
|
||||||
|
if (value == '1') return '{% trans "true" %}';
|
||||||
|
if (value == '0') return '{% trans "false" %}';
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
cols.push({
|
cols.push({
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
|
{% load i18n %}
|
||||||
|
|
||||||
{% if value %}
|
{% if value %}
|
||||||
<span class='label label-success'>Yes</span>
|
<span class='label label-success'>{% trans 'Yes' %}</span>
|
||||||
{% else %}
|
{% else %}
|
||||||
<span class='label label-warning'>No</span>
|
<span class='label label-warning'>{% trans 'No' %}</span>
|
||||||
{% endif %}
|
{% endif %}
|
Loading…
Reference in New Issue
Block a user