diff --git a/source/Ox.UI/js/List/IconList.js b/source/Ox.UI/js/List/IconList.js index d4d03bb3..7bd1a67f 100644 --- a/source/Ox.UI/js/List/IconList.js +++ b/source/Ox.UI/js/List/IconList.js @@ -18,6 +18,7 @@ Ox.IconList IconList Object min minimum of selcted items orientation orientation ("horizontal", "vertical" or "both") pageLength Number of items per page (if orientation != "both") + query Query selected array of selected items size list size sort sort keys @@ -44,6 +45,7 @@ Ox.IconList = function(options, self) { min: 0, orientation: 'both', pageLength: 100, + query: {conditions: [], operator: '&'}, selected: [], size: 128, sort: [], @@ -52,14 +54,17 @@ Ox.IconList = function(options, self) { .options(options || {}) .update({ items: function() { - that.$element.options('items', self.options.items); + that.$element.options({items: self.options.items}); + }, + query: function() { + that.$element.options({query: self.options.query}); }, selected: function() { - that.$element.options('selected', self.options.selected); + that.$element.options({selected: self.options.selected}); }, sort: function() { updateKeys(); - that.$element.options('sort', self.options.sort); + that.$element.options({sort: self.options.sort}); } }); @@ -89,6 +94,7 @@ Ox.IconList = function(options, self) { min: self.options.min, orientation: self.options.orientation, pageLength: self.options.pageLength, + query: self.options.query, selected: self.options.selected, sort: self.options.sort, type: 'icon', diff --git a/source/Ox.UI/js/List/InfoList.js b/source/Ox.UI/js/List/InfoList.js index d19e7432..082fdf4f 100644 --- a/source/Ox.UI/js/List/InfoList.js +++ b/source/Ox.UI/js/List/InfoList.js @@ -20,6 +20,7 @@ Ox.InfoList = function(options, self) { keys: [], max: -1, min: 0, + query: {conditions: [], operator: '&'}, selected: [], size: 192, sort: [], @@ -28,14 +29,17 @@ Ox.InfoList = function(options, self) { .options(options || {}) .update({ items: function() { - that.$element.options('items', self.options.items); + that.$element.options({items: self.options.items}); + }, + query: function() { + that.$element.options({query: self.options.query}); }, selected: function() { - that.$element.options('selected', self.options.selected); + that.$element.options({selected: self.options.selected}); }, sort: function() { updateKeys(); - that.$element.options('sort', self.options.sort); + that.$element.options({sort: self.options.sort}); }, width: function() { var width = getItemWidth(); @@ -45,7 +49,6 @@ Ox.InfoList = function(options, self) { $parent.css({width: width - 144}); $parent.parent().css({width: width - 144}); $parent.parent().parent().css({width: width - 8}); - Ox.Log('List', '@@@', this.className, id) Ox.UI.elements[id].options({width: width - 152}); }); } @@ -67,6 +70,7 @@ Ox.InfoList = function(options, self) { min: self.options.min, orientation: 'vertical', pageLength: 10, + query: self.options.query, selected: self.options.selected, sort: self.options.sort, type: 'info', diff --git a/source/Ox.UI/js/List/TextList.js b/source/Ox.UI/js/List/TextList.js index 6d86afde..60b57508 100644 --- a/source/Ox.UI/js/List/TextList.js +++ b/source/Ox.UI/js/List/TextList.js @@ -31,6 +31,7 @@ Ox.TextList TextList Object max Maximum number of items that can be selected (-1 for all) min Minimum number of items that must be selected pageLength Number of items per page + query Query scrollbarVisible If true, the scrollbar is always visible selected <[s]|[]> Array of selected ids sort <[o]|[s]|[]> ['+foo', ...] or [{key: 'foo', operator: '+'}, ...] @@ -64,6 +65,7 @@ Ox.TextList = function(options, self) { max: -1, min: 0, pageLength: 100, + query: {conditions: [], operator: '&'}, scrollbarVisible: false, selected: [], sort: [], @@ -73,17 +75,20 @@ Ox.TextList = function(options, self) { .options(options || {}) .update({ items: function() { - that.$body.options('items', self.options.items); + that.$body.options({items: self.options.items}); }, paste: function() { - that.$body.options('paste', self.options.paste); + that.$body.options({paste: self.options.paste}); + }, + query: function() { + that.$body.options({query: self.options.query}); }, selected: function() { - that.$body.options('selected', self.options.selected); + that.$body.options({selected: self.options.selected}); }, sort: function() { updateColumn(); - that.$body.options('sort', self.options.sort); + that.$body.options({sort: self.options.sort}); } }) .addClass('OxTextList') @@ -226,9 +231,10 @@ Ox.TextList = function(options, self) { }).concat(self.options.keys), max: self.options.max, min: self.options.min, + orientation: 'vertical', pageLength: self.options.pageLength, paste: self.options.paste, - orientation: 'vertical', + query: self.options.query, selected: self.options.selected, sort: self.options.sort, sortable: self.options.sortable,