forked from 0x2620/oxjs
misc fixes
This commit is contained in:
parent
33f08f3a41
commit
b881f74c7e
3 changed files with 18 additions and 9 deletions
|
|
@ -66,7 +66,11 @@ Ox.Filter = function(options, self) {
|
|||
{id: '<', title: 'is less than'},
|
||||
{id: '>', title: 'is greater than'},
|
||||
{id: '-', title: 'is between'},
|
||||
{id: '!-', title: 'is not between'}
|
||||
{id: '!-', title: 'is not between'}/*,
|
||||
{id: '^', title: 'starts with'},
|
||||
{id: '!^', title: 'does not start with'},
|
||||
{id: '$', title: 'ends with'},
|
||||
{id: '!$', title: 'does not end with'}*/
|
||||
],
|
||||
string: [
|
||||
{id: '=', title: 'is'},
|
||||
|
|
@ -356,9 +360,9 @@ Ox.Filter = function(options, self) {
|
|||
: [self.options.query.conditions[pos].conditions[subpos]],
|
||||
isUseless = false;
|
||||
Ox.forEach(conditions, function(condition) {
|
||||
isUseless = Ox.getObjectById(
|
||||
self.options.findKeys, condition.key
|
||||
).type == 'text'
|
||||
isUseless = ['string', 'text'].indexOf(
|
||||
Ox.getObjectById(self.options.findKeys, condition.key).type
|
||||
) > -1
|
||||
&& condition.operator == (self.options.query.operator == '&' ? '' : '!')
|
||||
&& condition.value == ''
|
||||
return isUseless;
|
||||
|
|
|
|||
|
|
@ -196,7 +196,7 @@ Ox.Select = function(options, self) {
|
|||
that.selectItem = function(id) {
|
||||
//Ox.print('selectItem', id, Ox.getObjectById(self.options.items, id).title)
|
||||
self.options.type == 'text' && self.$title.html(
|
||||
Ox.getObjectById(self.options.items, id).title[0] // fixme: title should not have become an array
|
||||
Ox.getObjectById(self.options.items, id).title
|
||||
);
|
||||
self.$menu.checkItem(id);
|
||||
self.checked = self.optionGroup.checked();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue