]> wagnertech.de Git - mfinanz.git/blob - templates/design40_webpages/record_template/dialog.html
date error in mapping
[mfinanz.git] / templates / design40_webpages / record_template / dialog.html
1 [% USE T8 %]
2 [% USE L %]
3 [% USE LxERP %]
4 [% USE HTML %]
5 [% USE JavaScript %]
6
7 [% L.hidden_tag("", SELF.template_type, id="record_template_dialog_template_type",
8                 "data-controller"=SELF.data.controller,
9                 "data-load_action"=SELF.data.load_action,
10                 "data-save_action"=SELF.data.save_action,
11                 "data-form_selector"=SELF.data.form_selector) %]
12
13 <h2>[% LxERP.t8("Add new record template") %]</h2>
14
15 <p>
16  [% LxERP.t8("Name") %]:
17  [% L.input_tag("", "", id="record_template_dialog_new_template_name") %]
18  [% L.button_tag("kivi.RecordTemplate.create()", LxERP.t8("Save")) %]
19 </p>
20
21 <h2 class="listheading">[% LxERP.t8("Filter record template") %]</h2>
22 <p>
23 <form method="post" action="javascript:kivi.RecordTemplate.filter_templates()">
24  [% LxERP.t8("Name") %]:
25  [% L.input_tag("template_filter", SELF.template_filter) %]
26  [% L.submit_tag('', LxERP.t8("Filter")) %]
27  [% L.button_tag('$("#template_filter").val("")', LxERP.t8('Reset')) %]
28 </form>
29 </p>
30
31 [% SET templates = SELF.templates.as_list %]
32
33 [% IF templates.size %]
34
35 <h2>[% LxERP.t8("Existing templates") %]</h2>
36
37 <table>
38  <thead>
39   <tr>
40    <th>[% LxERP.t8("Action") %]</th>
41    <th>[% LxERP.t8("Name") %]</th>
42    <th>[% LxERP.t8("Modification date") %]</th>
43   </tr>
44  </thead>
45
46  <tbody>
47 [% FOREACH template = templates %]
48   <tr class="listrow">
49    <td>
50     [% L.hidden_tag("", template.template_name, id="record_template_dialog_template_name_" _ template.id) %]
51     [% L.button_tag("kivi.RecordTemplate.load(" _ template.id _ ")", LxERP.t8("Load")) %]
52     [% L.button_tag("kivi.RecordTemplate.save(" _ template.id _ ")", LxERP.t8("Save")) %]
53     [% L.button_tag("kivi.RecordTemplate.rename(" _ template.id _ ")", LxERP.t8("Rename")) %]
54     [% L.button_tag("kivi.RecordTemplate.delete(" _ template.id _ ")", LxERP.t8("Delete")) %]
55    </td>
56    <td>[% HTML.escape(template.template_name) %]</td>
57    <td>[% HTML.escape(template.mtime.to_kivitendo) %] [% HTML.escape(template.mtime.to_kivitendo_time) %]</td>
58   </tr>
59 [% END %]
60  </tbody>
61
62 </table>
63 [% ELSE %]
64
65 <p>[% LxERP.t8("There are no record templates yet.") %]</p>
66
67 [% END %]