mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 14:41:29 +01:00
Add 'All' option to category filter if missing to match old etemplate
This commit is contained in:
parent
09542d6327
commit
4c41c36251
@ -1136,6 +1136,13 @@ var et2_nextmatch_header_bar = et2_DOMWidget.extend(et2_INextmatchHeader, {
|
||||
}
|
||||
}
|
||||
|
||||
// Legacy: Add in 'All' option for cat_id, if not provided.
|
||||
if(name == 'cat_id' && typeof options[''] == 'undefined' && typeof options[0] == 'undefined')
|
||||
{
|
||||
widget_options.empty_label = this.egw().lang('All');
|
||||
this.egw().debug('warn', 'Nextmatch category filter had no "All" option. Added, but you should fix that.');
|
||||
}
|
||||
|
||||
// Create widget
|
||||
var select = et2_createWidget(type, widget_options, this);
|
||||
|
||||
@ -1165,7 +1172,7 @@ var et2_nextmatch_header_bar = et2_DOMWidget.extend(et2_INextmatchHeader, {
|
||||
// Real submits cause all sorts of problems
|
||||
if(onchange.match(/this\.form\.submit/))
|
||||
{
|
||||
this.egw().debug("warn","%s tries to submit form",name);
|
||||
this.egw().debug("warn","%s tries to submit form, which is not allowed. Filter changes automatically refresh data with no reload.",name);
|
||||
onchange = onchange.replace(/this\.form\.submit\([^)]*\);?/,'return true;');
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user