diff --git a/etemplate/inc/class.etemplate_widget_nextmatch.inc.php b/etemplate/inc/class.etemplate_widget_nextmatch.inc.php index 3e6befe428..08a43dd4a2 100644 --- a/etemplate/inc/class.etemplate_widget_nextmatch.inc.php +++ b/etemplate/inc/class.etemplate_widget_nextmatch.inc.php @@ -174,7 +174,14 @@ class etemplate_widget_nextmatch extends etemplate_widget if(!$value['no_cat'] && !$value['cat_is_select']) { $cat_app = $value['cat_app'] ? $value['cat_app'] : $GLOBALS['egw_info']['flags']['current_app']; - $value['options-cat_id'] = array('' => lang('all')) + + $value['options-cat_id'] = array(); + + // Add 'All', if not already there + if(!$value['options-cat_id'][''] && !($value['options-cat_id'][0] && $value['options-cat_id'][0]['value'] == '')) + { + $value['options-cat_id'][''] = lang('all'); + } + $value['options-cat_id'] += etemplate_widget_menupopup::typeOptions('select-cat', ',,'.$cat_app,$no_lang,false,$value['cat_id']) + (array)$value['options-cat_id']; etemplate_widget_menupopup::fix_encoded_options($value['options-cat_id']);