diff options
-rw-r--r-- | archaeological_finds/views.py | 2 | ||||
-rw-r--r-- | ishtar_common/widgets.py | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/archaeological_finds/views.py b/archaeological_finds/views.py index 7b7bf20ad..2282e0c5d 100644 --- a/archaeological_finds/views.py +++ b/archaeological_finds/views.py @@ -65,7 +65,7 @@ get_find_for_ope = get_item(models.Find, 'get_find', 'find', get_find_for_treatment = get_item( models.Find, 'get_find', 'find', - own_table_cols=models.Find.TABLE_COLS_FOR_OPE, base_request={}) + own_table_cols=get_table_cols_for_ope(), base_request={}) autocomplete_find = get_autocomplete_item(model=models.Find) diff --git a/ishtar_common/widgets.py b/ishtar_common/widgets.py index 5b5f44477..b13e9fe2e 100644 --- a/ishtar_common/widgets.py +++ b/ishtar_common/widgets.py @@ -948,8 +948,8 @@ class JQueryPersonOrganization(forms.TextInput): class DataTable(Select2Media, forms.RadioSelect): - def __init__(self, source, form, associated_model, attrs={}, - table_cols='TABLE_COLS', multiple=False, multiple_cols=[2], + def __init__(self, source, form, associated_model, attrs=None, + table_cols='TABLE_COLS', multiple=False, multiple_cols=None, new=False, new_message="", source_full=None, multiple_select=False, sortname="__default__", col_prefix='', gallery=False, map=False): @@ -982,6 +982,8 @@ class DataTable(Select2Media, forms.RadioSelect): self.table_cols = table_cols self.multiple = multiple self.multiple_select = multiple_select + if not multiple_cols: + multiple_cols = [2] self.multiple_cols = multiple_cols self.new, self.new_message = new, new_message self.source_full = source_full |