Revision c40c19ef
Von Hans P. Schlaepfer vor etwa 4 Jahren hinzugefügt
templates/webpages/requirement_spec/_form.html | ||
---|---|---|
1 |
[%- DEFAULT id_prefix = 'basic_settings_form' |
|
2 |
submit_as = 'post' |
|
3 | 1 |
[% USE LxERP %] |
4 | 2 |
[% USE L %] |
5 | 3 |
[% USE HTML %] |
4 |
[% |
|
5 |
DEFAULT id_prefix = 'basic_settings_form' |
|
6 |
submit_as = 'post' |
|
6 | 7 |
%] |
7 | 8 |
<form method="post" action="controller.pl" id="[% id_prefix %]"[% UNLESS submit_as == 'post' %] class="edit-basic-settings-context-menu"[% END %]> |
8 |
<h2>[% LxERP.t8("Edit general settings") %]</h2>
|
|
9 |
<div class="wrapper">
|
|
9 | 10 |
|
10 |
[% L.hidden_tag("id", SELF.requirement_spec.id, id=id_prefix _ '_id') %]
|
|
11 |
[% L.hidden_tag("requirement_spec.is_template", SELF.requirement_spec.is_template, id=id_prefix _ '_is_template') %]
|
|
11 |
[% L.hidden_tag("id", SELF.requirement_spec.id, id=id_prefix _ '_id') %] |
|
12 |
[% L.hidden_tag("requirement_spec.is_template", SELF.requirement_spec.is_template, id=id_prefix _ '_is_template') %] |
|
12 | 13 |
|
13 |
<table class="rs_input_field"> |
|
14 |
<tr> |
|
15 |
<td>[% LxERP.t8("Title") %]</td> |
|
16 |
<td>[% L.input_tag("requirement_spec.title", SELF.requirement_spec.title, id=id_prefix _ '_title') %]</td> |
|
17 |
</tr> |
|
14 |
<table class="tbl-horizontal rs_input_field"> |
|
15 |
<caption>[% LxERP.t8("Edit general settings") %]</caption> |
|
16 |
<tbody> |
|
17 |
<tr> |
|
18 |
<th>[% LxERP.t8("Title") %]</th> |
|
19 |
<td>[% L.input_tag("requirement_spec.title", SELF.requirement_spec.title, id=id_prefix _ '_title') %]</td> |
|
20 |
</tr> |
|
21 |
<tr> |
|
22 |
<th>[% LxERP.t8("Requirement Spec Type") %]</th> |
|
23 |
<td>[% L.select_tag("requirement_spec.type_id", SELF.types, default=SELF.requirement_spec.type_id, title_key="description", id=id_prefix _ '_type_id') %]</td> |
|
24 |
</tr> |
|
25 |
[% UNLESS SELF.requirement_spec.is_template %] |
|
26 |
<tr> |
|
27 |
<th>[% LxERP.t8("Requirement Spec Status") %]</th> |
|
28 |
<td>[% L.select_tag("requirement_spec.status_id", SELF.statuses, default=SELF.requirement_spec.status_id, title_key="description", id=id_prefix _ '_status_id') %]</td> |
|
29 |
</tr> |
|
30 |
<tr> |
|
31 |
<th>[% LxERP.t8("Customer") %]</th> |
|
32 |
<td>[% |
|
33 |
L.select_tag("requirement_spec.customer_id", SELF.customers, default=SELF.requirement_spec.customer_id, title_key="name", id=id_prefix _ '_customer_id', |
|
34 |
onchange="kivi.requirement_spec.basic_settings_customer_changed('#" _ id_prefix _ "_customer_id', '#" _ id_prefix _ "_hourly_rate_as_number')") |
|
35 |
%]</td> |
|
36 |
</tr> |
|
37 |
<tr> |
|
38 |
<th>[% LxERP.t8("Hourly Rate") %]</th> |
|
39 |
<td>[% L.input_tag("requirement_spec.hourly_rate_as_number", SELF.requirement_spec.hourly_rate_as_number, id=id_prefix _ '_hourly_rate_as_number') %]</td> |
|
40 |
</tr> |
|
41 |
[% END %] |
|
42 |
[% cvars = SELF.requirement_spec.cvars_by_config %] |
|
43 |
[% FOREACH var = cvars %] |
|
44 |
<tr> |
|
45 |
<th>[% HTML.escape(var.config.description) %]</th> |
|
46 |
<td>[% INCLUDE 'common/render_cvar_input.html' |
|
47 |
cvar_name_prefix = 'cvars.' %]</td> |
|
48 |
</tr> |
|
49 |
[% END %] |
|
50 |
</tbody> |
|
51 |
</table> |
|
18 | 52 |
|
19 |
<tr> |
|
20 |
<td>[% LxERP.t8("Requirement Spec Type") %]</td> |
|
21 |
<td>[% L.select_tag("requirement_spec.type_id", SELF.types, default=SELF.requirement_spec.type_id, title_key="description", id=id_prefix _ '_type_id') %]</td> |
|
22 |
</tr> |
|
23 |
|
|
24 |
[%- UNLESS SELF.requirement_spec.is_template %] |
|
25 |
|
|
26 |
<tr> |
|
27 |
<td>[% LxERP.t8("Requirement Spec Status") %]</td> |
|
28 |
<td>[% L.select_tag("requirement_spec.status_id", SELF.statuses, default=SELF.requirement_spec.status_id, title_key="description", id=id_prefix _ '_status_id') %]</td> |
|
29 |
</tr> |
|
30 |
|
|
31 |
<tr> |
|
32 |
<td>[% LxERP.t8("Customer") %]</td> |
|
33 |
<td>[% L.select_tag("requirement_spec.customer_id", SELF.customers, default=SELF.requirement_spec.customer_id, title_key="name", id=id_prefix _ '_customer_id', |
|
34 |
onchange="kivi.requirement_spec.basic_settings_customer_changed('#" _ id_prefix _ "_customer_id', '#" _ id_prefix _ "_hourly_rate_as_number')") %]</td> |
|
35 |
</tr> |
|
36 |
|
|
37 |
<tr> |
|
38 |
<td>[% LxERP.t8("Hourly Rate") %]</td> |
|
39 |
<td>[% L.input_tag("requirement_spec.hourly_rate_as_number", SELF.requirement_spec.hourly_rate_as_number, id=id_prefix _ '_hourly_rate_as_number') %]</td> |
|
40 |
</tr> |
|
41 |
|
|
42 |
[%- END %] |
|
43 |
|
|
44 |
[% cvars = SELF.requirement_spec.cvars_by_config %] |
|
45 |
|
|
46 |
[% FOREACH var = cvars %] |
|
47 |
<tr> |
|
48 |
<td>[% HTML.escape(var.config.description) %]</td> |
|
49 |
|
|
50 |
<td> |
|
51 |
[% INCLUDE 'common/render_cvar_input.html' |
|
52 |
cvar_name_prefix = 'cvars.' |
|
53 |
%] |
|
54 |
</td> |
|
55 |
</tr> |
|
56 |
[% END %] |
|
57 |
|
|
58 |
</table> |
|
59 |
|
|
60 |
[%- IF SELF.copy_source %] |
|
61 |
[%- L.hidden_tag('copy_source_id', SELF.copy_source.id) %] |
|
62 |
|
|
63 |
<p> |
|
64 |
[%- IF SELF.requirement_spec.is_template %] |
|
65 |
[%- LxERP.t8("The new requirement spec template will be a copy of '#1'.", SELF.copy_source.title) %] |
|
66 |
[%- ELSE %] |
|
67 |
[%- LxERP.t8("The new requirement spec will be a copy of '#1' for customer '#2'.", SELF.copy_source.title, SELF.copy_source.customer.name) %] |
|
68 |
[%- END %] |
|
69 |
</p> |
|
70 |
[%- END %] |
|
53 |
[% IF SELF.copy_source %] |
|
54 |
[% L.hidden_tag('copy_source_id', SELF.copy_source.id) %] |
|
55 |
<p> |
|
56 |
[% IF SELF.requirement_spec.is_template %] |
|
57 |
[% LxERP.t8("The new requirement spec template will be a copy of '#1'.", SELF.copy_source.title) %] |
|
58 |
[% ELSE %] |
|
59 |
[% LxERP.t8("The new requirement spec will be a copy of '#1' for customer '#2'.", SELF.copy_source.title, SELF.copy_source.customer.name) %] |
|
60 |
[% END %] |
|
61 |
</p> |
|
62 |
[% END %] |
|
71 | 63 |
|
72 |
<p>
|
|
64 |
<div class="buttons">
|
|
73 | 65 |
[% IF submit_as != 'post' %] |
74 | 66 |
[% L.ajax_submit_tag("controller.pl?action=RequirementSpec/update", "#" _ id_prefix, LxERP.t8("Save"), id=id_prefix _ '_submit') %] |
75 | 67 |
<script type="text/javascript"><!-- |
... | ... | |
84 | 76 |
}); |
85 | 77 |
--></script> |
86 | 78 |
[% END %] |
87 |
</p> |
|
79 |
</div><!-- /.buttons --> |
|
80 |
</div><!-- /.wrapper --> |
|
88 | 81 |
</form> |
Auch abrufbar als: Unified diff
Neues Design 2019 Standard-Code templates/webpages/requirement_spec/_form.html