diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2020-09-29 18:06:04 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2021-02-28 12:15:20 +0100 |
commit | 143b337b67195504ebbbe54984ab2e4b42ff6f2d (patch) | |
tree | 53ee5c521dba28a415f184f97cd21ee8c947eeff /ishtar_common/views_item.py | |
parent | 3b0d8214cb1c4a05a3a2de392e49181ffeaf2ff6 (diff) | |
download | Ishtar-143b337b67195504ebbbe54984ab2e4b42ff6f2d.tar.bz2 Ishtar-143b337b67195504ebbbe54984ab2e4b42ff6f2d.zip |
Warehouse sheet: display divisions table, display number of items, divisions, containers
Diffstat (limited to 'ishtar_common/views_item.py')
-rw-r--r-- | ishtar_common/views_item.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ishtar_common/views_item.py b/ishtar_common/views_item.py index 33d817a25..1ef98e3c2 100644 --- a/ishtar_common/views_item.py +++ b/ishtar_common/views_item.py @@ -705,11 +705,11 @@ def _manage_bool_fields(model, bool_fields, reversed_bool_fields, dct, or_reqs): for k in bool_fields: if k not in dct: continue - elif dct[k] == u"1": + elif dct[k] == "1": dct.pop(k) continue - dct[k] = dct[k].replace(u'"', u'') - if dct[k] in [u"2", u"yes", str(_(u"Yes")).lower()]: + dct[k] = dct[k].replace('"', '') + if dct[k] in ["2", "yes", str(_("Yes")).lower(), "True"]: dct[k] = True else: dct[k] = False @@ -1399,7 +1399,7 @@ def get_item(model, func_name, default_name, extra_request_keys=None, :param own_table_cols: :param relation_types_prefix: :param do_not_deduplicate: duplication of id can occurs on large queryset a - mecanism of deduplication is used. But duplicate ids can be normal (for + mechanism of deduplication is used. But duplicate ids can be normal (for instance for record_relations view). :param model_for_perms: use another model to check permission :param alt_query_own: name of alternate method to get query_own |