View | Details | Raw Unified | Return to bug 35329
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc (-2 / +7 lines)
Lines 240-248 Link Here
240
            var extended_attribute_types = [% To.json(extended_attribute_types || []) | $raw %];
240
            var extended_attribute_types = [% To.json(extended_attribute_types || []) | $raw %];
241
        [% END %]
241
        [% END %]
242
242
243
        $(document).ready(function() {
243
        $(document).on("shown.bs.modal", function(){
244
            $('select[name="sort1_filter"]').select2({allowClear:true});
244
            $('select[name="sort1_filter"]').select2({allowClear:true});
245
            $('select[name="sort2_filter"]').select2({allowClear:true});
245
            $('select[name="sort2_filter"]').select2({allowClear:true});
246
        }).on("hidden.bs.modal", function(){
247
            ["sort1_filter", "sort2_filter"].forEach(function(item){
248
                if( $('select[name=' +  item + ']').data("select2") ){
249
                    $('select[name=' +  item + ']').select2("destroy");
250
                }
251
            });
246
        });
252
        });
247
    </script>
253
    </script>
248
254
249
- 

Return to bug 35329