%::myconfig dem Client javascript zur Verfügung stellen.
[kivitendo-erp.git] / templates / webpages / is / form_footer.html
1 [%- USE T8 %]
2 [%- USE HTML %]
3 [%- USE LxERP %]
4 [%- USE L %][%- USE P -%]
5   <tr>
6    <td>
7     <table width="100%">
8      <tr valign="bottom">
9       <td>
10        <table>
11         <tr>
12          <th align="left">[% 'Notes (will appear on hard copy)' | $T8 %]</th>
13          <th align="left">[% 'Internal Notes' | $T8 %]</th>
14          <th align="right">[% 'Payment / Delivery Options' | $T8 %]</th>
15         </tr>
16         <tr valign="top">
17          <td>
18           [% L.textarea_tag("notes", notes, wrap="soft", style="width: 350px; height: 150px", class="texteditor") %]
19          </td>
20          <td>
21           <textarea name="intnotes" rows="[% rows %]" cols="35">[% intnotes %]</textarea>
22          </td>
23          <td>
24            <table>
25              <tr>
26                <th align="right">[% 'Payment Terms' | $T8 %]</th>
27                <td>
28                  [%- INCLUDE 'generic/multibox.html'
29                    name          = 'payment_id',
30                    style         = 'width: 250px',
31                    DATA          = payment_terms,
32                    id_key        = 'id',
33                    label_key     = 'description',
34                    show_empty    = 1
35                    allow_textbox = 0 -%]
36                  <script type='text/javascript'>$('#payment_id').change(function(){ if (this.value) set_duedate()})</script>
37                </td>
38              </tr>
39              <tr>
40                <th align="right">[% 'Delivery Terms' | $T8 %] </th>
41                <td>
42                  [% L.select_tag('delivery_term_id', ALL_DELIVERY_TERMS, default = delivery_term_id, with_empty = 1, title_key = 'description', style = 'width: 250px') %]
43                </td>
44              </tr>
45              <tr>
46                <th align="right">[% 'direct debit' | $T8 %]</th>
47                <td>
48                  [%- L.checkbox_tag('direct_debit', 'checked', direct_debit) %]
49                </td>
50              </tr>
51            </table>
52          </td>
53         </tr>
54 [%- IF id && follow_ups.size %]
55         <tr>
56           <td colspan="2">
57             [%- LxERP.t8('There are #1 unfinished follow-ups of which #2 are due.', follow_ups.size, follow_ups_unfinished) | html %]
58           <td>
59         </tr>
60 [%- END %]
61        </table>
62       </td>
63 [%- IF show_weight %]
64       <td>
65        <table>
66         <tr>
67          <th  align=left>[% 'Total weight' | $T8 %]</th>
68          <td>
69           [% LxERP.format_amount(totalweight) %] [% HTML.escape(weightunit) %]
70          </td>
71         </tr>
72        </table>
73       </td>
74 [%- END %]
75       <td>
76        <table>
77         <tr>
78          <th  align=left>[% 'Ertrag' | $T8 %]</th>
79          <td>
80           [% LxERP.format_amount(marge_total, 2, 0) %]
81           <input type=hidden name="marge_total" value="[% marge_total %]">
82          </td>
83         </tr>
84         <tr>
85          <th  align=left>[% 'Ertrag prozentual' | $T8 %]</th>
86          <td>
87           [% LxERP.format_amount(marge_percent, 2, 0) %] %
88           <input type=hidden name="marge_percent" value="[% marge_percent %]">
89          </td>
90         </tr>
91        </table>
92       </td>
93       <td align="right">
94   [%- IF taxaccounts %]
95        <input type="hidden" name="taxincluded_changed_by_user" id="taxincluded_changed_by_user" value="[% taxincluded_changed_by_user ? '1' : '0' %]">
96        <input name="taxincluded" onclick="document.getElementById('taxincluded_changed_by_user').value = '1';" class="checkbox" type="checkbox" [% IF taxincluded %]checked[% END %]>
97        <b>[% 'Tax Included' | $T8 %]</b>
98        <br>
99        <br>
100   [%- END %]
101        <table>
102
103 [%- UNLESS taxincluded %]
104         <tr>
105          <th align="right">[% 'Subtotal' | $T8 %]</th>
106          <td align="right">[% LxERP.format_amount(invsubtotal, 2) %]</td>
107        </tr>
108 [%- END %]
109
110 [%# tax %]
111 [% FOREACH item = taxaccounts_array %]
112 [% SET description_ref = item _ '_description' %]
113 [% SET rate_ref        = item _ '_rate' %]
114 [% SET total_ref       = item _ '_total' %]
115 [% SET netto_ref       = item _ '_netto' %]
116        <tr>
117         <th align="right">[% 'Including' | $T8 %] [% $description_ref | html %]&nbsp;[% $rate_ref * 100 %]%</th>
118         <td align="right">[% LxERP.format_amount($total_ref, 2) %]</td>
119        </tr>
120   [%- IF taxincluded %]
121        <tr>
122         <th align="right">[% 'Net amount' | $T8 %]</th>
123         <td align="right">[% LxERP.format_amount($netto_ref, 2) %]</td>
124        </tr>
125   [%- END %]
126 [%- END %]
127
128         <tr>
129          <th align="right">[% 'Total' | $T8 %]</th>
130          <td align="right">[% LxERP.format_amount(invtotal, 2) %]</td>
131         </tr>
132        </table>
133       </td>
134      </tr>
135     </table>
136    </td>
137   </tr>
138
139 [% PROCESS 'is/_payments.html' %]
140  </table>
141 </div>
142 [% PROCESS 'webdav/_list.html' %]
143 <div id="ui-tabs-1">
144  [% LxERP.t8('Loading...') %]
145 </div>
146 </div>
147
148 <hr size="3" noshade>
149
150 <p>[% print_options %]</p>
151
152   [% IF id %]
153
154     <input class="submit" type="submit" accesskey="u" name="action" id="update_button" value="[% 'Update' | $T8 %]">
155     <input class="submit" type="submit" name="action" value="[% 'Ship to' | $T8 %]">
156     <input class="submit" type="submit" name="action" value="[% 'Print' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
157     <input class="submit" type="submit" name="action" value="[% 'E-mail' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
158 [% IF  show_storno %]
159     <input class="submit" type="submit" name="action" value="[% 'Storno' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
160 [% END %]
161     <input class="submit" type="submit" name="action" value="[% 'Post Payment' | $T8 %]">
162     <input class="submit" type="submit" name="action" value="[% 'Use As New' | $T8 %]">
163
164 [% IF id && !is_type_credit_note %]
165     <input class="submit" type="submit" name="action" value="[% 'Credit Note' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
166 [% END %]
167 [% IF show_delete && !storno %]
168     <input class="submit" type="submit" name="action" value="[% 'Delete' | $T8 %]">
169     <input class="submit" type="submit" name="action" value="[% 'Post' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
170 [% END %]
171     <input class="submit" type="submit" name="action" value="[% 'Order' | $T8 %]">
172     <input type="button" class="submit" onclick="follow_up_window()" value="[% 'Follow-Up' | $T8 %]">
173
174  [% ELSE # no id %]
175    [% UNLESS locked %]
176       <input class="submit" type="submit" name="action" id="update_button" value="[% 'Update' | $T8 %]">
177       <input class="submit" type="submit" name="action" value="[% 'Ship to' | $T8 %]">
178       <input class="submit" type="submit" name="action" value="[% 'Preview' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
179       <input class="submit" type="submit" name="action" value="[% 'Post and E-mail' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
180       <input class="submit" type="submit" name="action" value="[% 'Print and Post' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
181       <input class="submit" type="submit" name="action" value="[% 'Post' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
182       <input class="submit" type="submit" name="action" value="[% 'Save Draft' | $T8 %]">
183    [%- END %]
184  [% END # id %]
185
186   [% IF id %]
187       [%#- button for saving history %]
188       <input type="button" class="submit" onclick="set_history_window([% id | html %], 'glid');" name="history" id="history" value="[% 'history' | $T8 %]">
189       [% IF INSTANCE_CONF.get_is_show_mark_as_paid %]
190           <input type="submit" class="submit" name="action" value="[% 'mark as paid' | $T8 %]">
191       [% END %]
192   [% END %]
193
194 <input type="hidden" name="rowcount" value="[% rowcount %]">
195 <input type="hidden" name="callback" value="[% callback | html %]">
196 <input type="hidden" name="draft_id" value="[% draft_id %]">
197 <input type="hidden" name="draft_description" value="[% draft_description %]">
198 <input type="hidden" name="customer_discount" value="[% customer_discount %]">
199 <input type="hidden" name="gldate" value="[% gldate %]">
200 </form>
201 <script type='text/javascript'>
202  $(kivi.SalesPurchase.init_on_submit_checks);
203 </script>