X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=templates%2Fwebpages%2Famcvar%2Frender_inputs_block.html;h=8f0b20f3ef99063232f77cd13f522912ec074317;hb=18a2ca336c2e4c87bd1d6fe55bc9d83e177584a5;hp=33623f61d43026feba817efe66536d1e6f79bbb0;hpb=67079598f8f98a12e12a8acddc3afbf12bb58c5d;p=kivitendo-erp.git
diff --git a/templates/webpages/amcvar/render_inputs_block.html b/templates/webpages/amcvar/render_inputs_block.html
index 33623f61d..8f0b20f3e 100644
--- a/templates/webpages/amcvar/render_inputs_block.html
+++ b/templates/webpages/amcvar/render_inputs_block.html
@@ -1,45 +1,78 @@
[%- USE T8 %]
[%- USE HTML %]
[%- USE L %]
-[%- USE LxERP %]
-[%- BLOCK cvar_name %][% HTML.escape(cvar.name_prefix) _ "cvar_" _ HTML.escape(cvar.var.name) _ HTML.escape(cvar.name_postfix) -%][% END %]
+[%- USE LxERP %][%- USE P -%]
[%- BLOCK cvar_inputs %]
-[% render_input_blocks__cvar_name = PROCESS cvar_name %]
-[%- %]
-[%- IF cvar.hide_non_editable && !cvar.var.flag_editable %]
-
-[%- ELSIF !cvar.valid %]
+[%- SET render_cvar_tag_options = {};
+ render_cvar_tag_options.import(cvar_tag_options) IF cvar_tag_options;
+ SET cvar_tag_name = HTML.escape(cvar.name_prefix) _ "cvar_" _ HTML.escape(cvar.var.name) _ HTML.escape(cvar.name_postfix);
+ IF !render_cvar_tag_options.id && (cvar.var.type != 'select');
+ SET render_cvar_tag_options.no_id = 1;
+ END;
+%]
+
+[%- IF (!cvar.hide_non_editable || cvar.var.flag_editable) && !cvar.partsgroup_filtered %]
+
+[%- IF !cvar.valid %]
[%- IF show_disabled_message %]
[% 'Element disabled' | $T8 %]
[%- END %]
+
[%- ELSIF cvar.var.type == 'bool' %]
-
+[%- render_cvar_tag_options.import(checked=cvar.value, value=1);
+ L.checkbox_tag(cvar_tag_name, render_cvar_tag_options) %]
+
[%- ELSIF cvar.var.type == 'textfield' %]
-[% L.textarea_tag(render_input_blocks__cvar_name, cvar.value, cols=cvar.var.width, rows=cvar.var.height) %]
+[% render_cvar_tag_options.import(cols=cvar.var.width, rows=cvar.var.height);
+ L.textarea_tag(cvar_tag_name, cvar.value, render_cvar_tag_options) %]
+
[%- ELSIF cvar.var.type == 'date' %]
-[%- L.date_tag(render_input_blocks__cvar_name, cvar.value) %]
+[%- L.date_tag(cvar_tag_name, cvar.value, render_cvar_tag_options) %]
[%- ELSIF cvar.var.type == 'timestamp' %]
-
+[%- L.input_tag(cvar_tag_name, cvar.value, render_cvar_tag_options) %]
+
[%- ELSIF cvar.var.type == 'select' %]
-