addField($this->isTemplateDashboard() ? null : new CWidgetFieldMultiSelectGroup('groupids', _('Host groups')) ) ->addField($this->isTemplateDashboard() ? null : new CWidgetFieldMultiSelectHost('hostids', _('Hosts')) ) ->addField( new CWidgetFieldTextBox('problem', _('Problem')) ) ->addField( new CWidgetFieldSeverities('severities', _('Severity')) ) ->addField( (new CWidgetFieldRadioButtonList('evaltype', _('Problem tags'), [ TAG_EVAL_TYPE_AND_OR => _('And/Or'), TAG_EVAL_TYPE_OR => _('Or') ]))->setDefault(TAG_EVAL_TYPE_AND_OR) ) ->addField( new CWidgetFieldTags('tags') ) ->addField( (new CWidgetFieldIntegerBox('show_lines', _('Trigger count'), ZBX_MIN_WIDGET_LINES, ZBX_MAX_WIDGET_LINES )) ->setDefault(self::DEFAULT_TRIGGER_COUNT) ->setFlags(CWidgetField::FLAG_LABEL_ASTERISK) ); } }