3a6f126dbcfc2bc5a2abfb7b377b28a1fd48409f
[kivitendo-erp.git] / templates / webpages / fu / add_edit.html
1 [%- USE T8 %]
2 [%- USE L %]
3 [%- USE HTML %]
4 <h1>[% title %]</h1>
5
6  <script type="text/javascript">
7    $(function(){ document.Form.subject.focus(); });
8  </script>
9
10  <form action="fu.pl" method="post" name="Form" id="form">
11
12   [%- IF SAVED_MESSAGE %]
13   <p>[% SAVED_MESSAGE %]</p>
14   [%- END %]
15
16   <input type="hidden" name="id" value="[% HTML.escape(id) %]">
17   <input type="hidden" name="note_id" value="[% HTML.escape(note_id) %]">
18   <input type="hidden" name="callback" value="[% HTML.escape(callback) %]">
19   <input type="hidden" name="POPUP_MODE" value="[% HTML.escape(POPUP_MODE) %]">
20
21   <table>
22     <tr>
23      <td valign="top">[% 'Follow-Up for user' | $T8 %]</td>
24      <td valign="top">
25       <select name="created_for_user">
26        [%- FOREACH row = EMPLOYEES %]
27        <option value="[% HTML.escape(row.id) %]"[% IF created_for_user == row.id %] selected[% END %]>
28         [%- IF row.name %][% HTML.escape(row.name) %] ([% HTML.escape(row.login) %])[% ELSE %][% HTML.escape(row.login) %][% END %]
29        </option>
30        [%- END %]
31       </select>
32      </td>
33     </tr>
34
35     <tr>
36      <td valign="right">[% 'Follow-Up Date' | $T8 %]</td>
37      <td>
38        [% L.date_tag('follow_up_date', follow_up_date) %]
39     </tr>
40
41     <tr>
42      <td valign="right">[% 'Subject' | $T8 %]</td>
43      <td><input name="subject" value="[% HTML.escape(subject) %]" size="50"></td>
44     </tr>
45
46     <tr>
47      <td valign="right" align="top">[% 'Body' | $T8 %]</td>
48      <td align="top"><textarea cols="50" rows="10" name="body">[% HTML.escape(body) %]</textarea></td>
49     </tr>
50   </table>
51
52  [%- IF POPUP_MODE %]
53   <p>
54    <input type="hidden" name="action" value="dispatcher">
55    <input type="submit" class="submit" name="action_save" value="[% 'Save' | $T8 %]">
56    [%- IF id %]
57    <input type="submit" class="submit" name="action_finish" value="[% 'Finish' | $T8 %]">
58    <input type="submit" class="submit" name="action_delete" value="[% 'Delete' | $T8 %]">
59    [%- END %]
60    <input type="submit" class="submit" onclick="window.close()" value="[% 'Cancel' | $T8 %]">
61   </p>
62
63   [%- IF FOLLOW_UPS_PENDING.size %]
64   <hr height="3" noshade>
65
66   <h2>[% 'Existing pending follow-ups for this item' | $T8 %]</h2>
67
68   <table>
69     <tr>
70      <th class="listheading">[% 'Follow-Up Date' | $T8 %]</th>
71      <th class="listheading">[% 'Subject' | $T8 %]</th>
72      <th class="listheading">[% 'Created by' | $T8 %]</th>
73      <th class="listheading">[% 'Follow-up for' | $T8 %]</th>
74     </tr>
75
76     [%- FOREACH row = FOLLOW_UPS_PENDING %]
77     <tr class="listrow[% loop.count % 2 %]">
78      <td valign="top">[% HTML.escape(row.follow_up_date) %]</td>
79      <td valign="top"><a href="fu.pl?action=edit&id=[% HTML.escape(row.id) %][% IF POPUP_MODE %]&POPUP_MODE=1[% END %]">[% HTML.escape(row.subject) %]</a></td>
80      <td valign="top">[% HTML.escape(row.created_by_name) %]</td>
81      <td valign="top">[% HTML.escape(row.created_for_user_name) %]</td>
82     </tr>
83     [%- END %]
84   </table>
85   [%- END %]
86
87   [%- IF FOLLOW_UPS_DONE.size %]
88   <hr height="3" noshade>
89
90   <h2>[% 'Existing finished follow-ups for this item' | $T8 %]</h2>
91
92   <table>
93     <tr>
94      <th class="listheading">[% 'Follow-Up Date' | $T8 %]</th>
95      <th class="listheading">[% 'Subject' | $T8 %]</th>
96      <th class="listheading">[% 'Created by' | $T8 %]</th>
97      <th class="listheading">[% 'Follow-up for' | $T8 %]</th>
98     </tr>
99
100     [%- FOREACH row = FOLLOW_UPS_DONE %]
101     <tr class="listrow[% loop.count % 2 %]">
102      <td valign="top">[% HTML.escape(row.follow_up_date) %]</td>
103      <td valign="top"><a href="fu.pl?action=edit&id=[% HTML.escape(row.id) %][% IF POPUP_MODE %]&POPUP_MODE=1[% END %]">[% HTML.escape(row.subject) %]</a></td>
104      <td valign="top">[% HTML.escape(row.created_by_name) %]</td>
105      <td valign="top">[% HTML.escape(row.created_for_user_name) %]</td>
106     </tr>
107     [%- END %]
108   </table>
109   [%- END %]
110
111  [%- END %]
112
113   [%- FOREACH row = LINKS %]
114   <input type="hidden" name="trans_id_[% loop.count %]"   value="[% HTML.escape(row.trans_id) %]">
115   <input type="hidden" name="trans_type_[% loop.count %]" value="[% HTML.escape(row.trans_type) %]">
116   <input type="hidden" name="trans_info_[% loop.count %]" value="[% HTML.escape(row.trans_info) %]">
117   [%- END %]
118
119   <input type="hidden" name="trans_rowcount" value="[% LINKS.size %]">
120  </form>