mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-27 00:58:55 +01:00
Use select account filter nextmatch header for custom filters of type 'select-account'
This commit is contained in:
parent
ecd1ad3628
commit
59d1f23bb0
@ -2930,18 +2930,21 @@ var et2_nextmatch_customfields = et2_customfields_list.extend(et2_INextmatchHead
|
||||
|
||||
// Create widget by type
|
||||
var widget = null;
|
||||
|
||||
if(field.type == 'select')
|
||||
if(field.type == 'select' || field.type == 'select-account')
|
||||
{
|
||||
if(field.values && typeof field.values[''] !== 'undefined')
|
||||
{
|
||||
delete(field.values['']);
|
||||
}
|
||||
widget = et2_createWidget("nextmatch-filterheader", {
|
||||
widget = et2_createWidget(
|
||||
field.type == 'select-account' ? 'nextmatch-accountfilter' : "nextmatch-filterheader",
|
||||
{
|
||||
id: cf_id,
|
||||
empty_label: field.label,
|
||||
select_options: field.values
|
||||
}, this);
|
||||
},
|
||||
this
|
||||
);
|
||||
}
|
||||
else if (apps[field.type])
|
||||
{
|
||||
@ -3209,12 +3212,6 @@ var et2_nextmatch_accountfilterheader = et2_selectAccount.extend([et2_INextmatch
|
||||
|
||||
},
|
||||
|
||||
set_select_options: function(_options) {
|
||||
// Tell framework to ignore, or it will reset it to ''/empty when it does loadingFinished()
|
||||
this.attributes.select_options.ignore = true;
|
||||
this._super.apply(this, arguments);
|
||||
},
|
||||
|
||||
/**
|
||||
* Set nextmatch is the function which has to be implemented for the
|
||||
* et2_INextmatchHeader interface.
|
||||
|
Loading…
Reference in New Issue
Block a user