5 [%- PROCESS 'amcvar/render_inputs_block.html' %]
8 <input type="button" id="cb_show_details" name="show_details_button" value='[% 'Show details' | $T8 %]'[% IF show_details %] style="display:none"[% END %]>
9 <input type="button" id="cb_hide_details" name="hide_details_button" value='[% 'Hide details' | $T8 %]'[% IF !show_details %] style="display:none"[% END %]>
10 <script type="text/javascript">
11 $('#cb_show_details,#cb_hide_details').click(function(){
12 $('[id^="row2"],#cb_show_details,#cb_hide_details').toggle();
13 if ( $('[id^="row2"]').is(":visible") ) {
14 $("[name='show_details']").val(1);
16 $("[name='show_details']").val(0);
20 <table id='display_row' width="100%">
21 <tr class="listheading">
22 [%- FOREACH header = HEADER %]
23 [%- IF header.display %]
24 <th align="left" nowrap width="[% header.width %]" class="listheading">[% header.value %]</th>
28 [%- FOREACH row = ROWS %]
29 <tr valign="top" class="row [% IF row.error %]error_message[% ELSE %]listrow[% loop.count % 2 %][% END %]">
30 [%- FOREACH row1 = row.ROW1 %]
31 <td[% IF row1.align %] align="[% row1.align %]"[% END %][% IF row1.nowrap %] nowrap[% END %][% IF row1.class %] class="[% row1.class %]"[% END %]>[% row1.value %]</td>
34 <tr style='display:none'>
36 [%- FOREACH hidden = row.HIDDENS %]
41 <tr class="listrow[% loop.count % 2 %]" id="row2.[% loop.count %]" [% UNLESS show_details %]style="display:none;"[% END %]>
42 <td colspan="[% row.colspan %]">
44 [%# render all row2 entries except cvars %]
45 [%- FOREACH row2 = row.ROW2 %]
51 [%# process editable cvars %]
52 <table class='row2-cvars-table'>
54 [%- FOREACH row2 = row.ROW2 %]
55 [%- SET show = ((row2.render_options.var.flag_editable || !row2.render_options.hide_non_editable ) && row2.render_options.valid && !row2.render_options.partsgroup_filtered) %]
56 [%- IF row2.cvar && show %]
57 [%- IF row2.line_break %]
61 [% row2.description %]
64 [% PROCESS cvar_inputs cvar = row2.render_options %]
71 [%# process non editable cvars extra to not disturb the table layout (this will be hidden inputs) %]
72 [%- FOREACH row2 = row.ROW2 %]
73 [%- SET hide = (!row2.render_options.var.flag_editable && row2.render_options.hide_non_editable) %]
74 [%- IF row2.cvar && hide %]
75 [% PROCESS cvar_inputs cvar = row2.render_options %]