[% 'Module' | $T8 %] |
[%- L.select_tag('module', SELF.modules, value_key='module', title_key='description', default=SELF.module, onchange="update_ic_rows();") %] |
[% 'Variable Name' | $T8 %](1) |
[%- L.input_tag("config.name", SELF.config.name, class='initial_focus') %] |
[% 'Variable Description' | $T8 %](2) |
[%- L.input_tag("config.description", SELF.config.description) %] |
[% 'Type' | $T8 %](3) |
[% L.select_tag("config.type", SELF.translated_types, value_key='type', title_key='translation', default=SELF.config.type) %] |
[% 'Default value' | $T8 %](4) |
[%- L.input_tag("config.default_value", SELF.config.type == 'number' ? LxERP.format_amount(SELF.config.default_value, 2) : SELF.config.default_value) %] |
[% 'Options' | $T8 %](5) |
[%- L.input_tag("config.options", SELF.config.options) %] |
[% 'Is Searchable' | $T8 %] |
[% L.radio_button_tag('config.searchable', value='1', id='config_searchable_1', label=LxERP.t8('Yes'), checked=(SELF.config.searchable ? 1 : '')) %]
[% L.radio_button_tag('config.searchable', value='0', id='config_searchable_0', label=LxERP.t8('No'), checked=(SELF.config.searchable ? '' : 1)) %]
|
[% 'Includeable in reports' | $T8 %] |
[% L.radio_button_tag('config.includeable', value='1', id='config_includeable_1', label=LxERP.t8('Yes'), checked=(SELF.config.includeable ? 1 : ''), onclick='update_included_by_default()') %]
[% L.radio_button_tag('config.includeable', value='0', id='config_includeable_0', label=LxERP.t8('No'), checked=(SELF.config.includeable ? '' : 1), onclick='update_included_by_default()') %]
|
[% 'Included in reports by default' | $T8 %] |
[% SET disabled = SELF.config.includeable ? '' : 'disabled' %]
[% L.radio_button_tag('config.included_by_default', value='1', id='config_included_by_default_1', label=LxERP.t8('Yes'), checked=(SELF.config.included_by_default ? 1 : ''), disabled=disabled) %]
[% L.radio_button_tag('config.included_by_default', value='0', id='config_included_by_default_0', label=LxERP.t8('No'), checked=(SELF.config.included_by_default ? '' : 1), disabled=disabled) %]
|
[% 'Editable' | $T8 %](6) |
[% L.radio_button_tag('config.flag_editable', value='1', id='config.flag_editable_1', label=LxERP.t8('Yes'), checked=(SELF.flags.editable ? 1 : '')) %]
[% L.radio_button_tag('config.flag_editable', value='0', id='config.flag_editable_0', label=LxERP.t8('No'), checked=(SELF.flags.editable ? '' : 1)) %]
|
[% L.hidden_tag("action", "CustomVariableConfig/dispatch") %]
[% L.submit_tag("action_" _ (SELF.config.id ? "update" : "create"), LxERP.t8('Save'), onclick="return check_prerequisites();") %]
[%- IF SELF.config.id %]
[% L.submit_tag("action_create", LxERP.t8('Save as new'), onclick="return check_prerequisites();") %]
[% L.submit_tag("action_destroy", LxERP.t8('Delete'), confirm=LxERP.t8('Are you sure?')) %]
[%- END %]
[%- LxERP.t8("Cancel") %]
(1) [% 'The variable name must only consist of letters, numbers and underscores. It must begin with a letter. Example: send_christmas_present' | $T8 %]
(2) [% 'The description is shown on the form. Chose something short and descriptive.' | $T8 %]
(3) [% 'For type "customer" the perl module JSON is required. Please check this on system level: $ ./scripts/installation_check.pl' | $T8 %]
(6)
[%- 'A variable marked as \'editable\' can be changed in each quotation, order, invoice etc.' | $T8 %]
[% 'Otherwise the variable is only available for printing.' | $T8 %]