kivi.Part.js: real_id wird nicht mehr benötigt
[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>[% L.select_tag('payment_id', payment_terms, default = payment_id, title_key = 'description', with_empty = 1, style="width: 250px") %]
28                  <script type='text/javascript'>$('#payment_id').change(function(){ kivi.SalesPurchase.set_duedate_on_reference_date_change("invdate"); })</script>
29                </td>
30              </tr>
31              <tr>
32                <th align="right">[% 'Delivery Terms' | $T8 %] </th>
33                <td>
34                  [% L.select_tag('delivery_term_id', ALL_DELIVERY_TERMS, default = delivery_term_id, with_empty = 1, title_key = 'description', style = 'width: 250px') %]
35                </td>
36              </tr>
37              <tr>
38                <th align="right">[% 'direct debit' | $T8 %]</th>
39                <td>
40                  [%- L.checkbox_tag('direct_debit', 'checked', direct_debit) %]
41                </td>
42              </tr>
43            </table>
44          </td>
45         </tr>
46 [%- IF id && follow_ups.size %]
47         <tr>
48           <td colspan="2">
49             [%- LxERP.t8('There are #1 unfinished follow-ups of which #2 are due.', follow_ups.size, follow_ups_unfinished) | html %]
50           <td>
51         </tr>
52 [%- END %]
53        </table>
54       </td>
55 [%- IF show_weight %]
56       <td>
57        <table>
58         <tr>
59          <th  align=left>[% 'Total weight' | $T8 %]</th>
60          <td>
61           [% LxERP.format_amount(totalweight) %] [% HTML.escape(weightunit) %]
62          </td>
63         </tr>
64        </table>
65       </td>
66 [%- END %]
67       <td>
68        <table>
69         <tr>
70          <th  align=left>[% 'Ertrag' | $T8 %]</th>
71          <td>
72           [% LxERP.format_amount(marge_total, 2, 0) %]
73           <input type=hidden name="marge_total" value="[% marge_total %]">
74          </td>
75         </tr>
76         <tr>
77          <th  align=left>[% 'Ertrag prozentual' | $T8 %]</th>
78          <td>
79           [% LxERP.format_amount(marge_percent, 2, 0) %] %
80           <input type=hidden name="marge_percent" value="[% marge_percent %]">
81          </td>
82         </tr>
83        </table>
84       </td>
85       <td align="right">
86   [%- IF taxaccounts %]
87        <input type="hidden" name="taxincluded_changed_by_user" id="taxincluded_changed_by_user" value="[% taxincluded_changed_by_user ? '1' : '0' %]">
88        <input name="taxincluded" onclick="document.getElementById('taxincluded_changed_by_user').value = '1';" class="checkbox" type="checkbox" [% IF taxincluded %]checked[% END %]>
89        <b>[% 'Tax Included' | $T8 %]</b>
90        <br>
91        <br>
92   [%- END %]
93        <table>
94
95 [%- UNLESS taxincluded %]
96         <tr>
97          <th align="right">[% 'Subtotal' | $T8 %]</th>
98          <td align="right">[% LxERP.format_amount(invsubtotal, 2) %]</td>
99        </tr>
100 [%- END %]
101
102 [%# tax %]
103 [% FOREACH item = taxaccounts_array %]
104 [% SET description_ref = item _ '_description' %]
105 [% SET rate_ref        = item _ '_rate' %]
106 [% SET total_ref       = item _ '_total' %]
107 [% SET netto_ref       = item _ '_netto' %]
108        <tr>
109         <th align="right">[% 'Including' | $T8 %] [% $description_ref | html %]&nbsp;[% $rate_ref * 100 %]%</th>
110         <td align="right">[% LxERP.format_amount($total_ref, 2) %]</td>
111        </tr>
112   [%- IF taxincluded %]
113        <tr>
114         <th align="right">[% 'Net amount' | $T8 %]</th>
115         <td align="right">[% LxERP.format_amount($netto_ref, 2) %]</td>
116        </tr>
117   [%- END %]
118 [%- END %]
119
120 [%- IF rounding %]
121         <tr>
122           <th align='right'>[% 'Rounding' | $T8 %]</th>
123           <td align='right'>[% LxERP.format_amount(rounding, 2) %]</td>
124         </tr>
125 [%- END %]
126
127         <tr>
128          <th align="right">[% 'Total' | $T8 %]</th>
129          <td align="right">[% LxERP.format_amount(invtotal, 2) %]</td>
130         </tr>
131        </table>
132       </td>
133      </tr>
134     </table>
135    </td>
136   </tr>
137
138 [% PROCESS 'is/_payments.html' %]
139  </table>
140 </div>
141 [% PROCESS 'webdav/_list.html' %]
142 <div id="ui-tabs-1">
143  [% LxERP.t8('Loading...') %]
144 </div>
145 </div>
146
147 <hr size="3" noshade>
148
149 <p>[% print_options %]</p>
150
151 <div id='form_action_bar'>
152   <input type="hidden" id="action" name="action" value="dispatcher">
153
154   [% IF id %]
155     <input class="submit" type="submit" accesskey="u" name="action_update" id="update_button" value="[% 'Update' | $T8 %]">
156     <input class="submit" type="submit" name="action_ship_to" value="[% 'Ship to' | $T8 %]">
157     <input class="submit" type="submit" name="action_print" id="action_print" value="[% 'Print' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
158     <input class="submit" type="submit" name="action_e_mail" value="[% 'E-mail' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
159 [% IF  show_storno %]
160     [% L.submit_tag("action_storno", LxERP.t8("Storno"), "data-require-transaction-description"=INSTANCE_CONF.get_require_transaction_description_ps, confirm=LxERP.t8('Do you really want to cancel this invoice?')) %]
161 [% END %]
162     <input class="submit" type="submit" name="action_post_payment" value="[% 'Post Payment' | $T8 %]">
163     <input class="submit" type="submit" name="action_use_as_new" value="[% 'Use As New' | $T8 %]">
164
165 [% IF id && !is_type_credit_note %]
166     <input class="submit" type="submit" name="action_credit_note" value="[% 'Credit Note' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
167 [% END %]
168 [% IF show_delete && (!storno || storno_id) %]
169     [% L.submit_tag("action_delete", LxERP.t8("Delete"), confirm=LxERP.t8('Do you really want to delete this invoice?')) %]
170 [% END %]
171 [% IF show_delete && !storno %]
172     <input class="submit" type="submit" name="action_post" value="[% 'Post' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
173 [% END %]
174     <input class="submit" type="submit" name="action_order" value="[% 'Order' | $T8 %]">
175     <input type="button" class="submit" onclick="follow_up_window()" value="[% 'Follow-Up' | $T8 %]">
176
177  [% ELSE # no id %]
178    [% UNLESS locked %]
179       <input class="submit" type="submit" name="action_update" id="update_button" value="[% 'Update' | $T8 %]">
180       <input class="submit" type="submit" name="action_ship_to" value="[% 'Ship to' | $T8 %]">
181       <input class="submit" type="submit" name="action_preview" value="[% 'Preview' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
182       <input class="submit" type="submit" name="action_post_and_e_mail" value="[% 'Post and E-mail' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
183       <input class="submit" type="submit" name="action_print_and_post" value="[% 'Print and Post' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
184       <input class="submit" type="submit" name="action_post" value="[% 'Post' | $T8 %]" data-require-transaction-description="[% INSTANCE_CONF.get_require_transaction_description_ps %]">
185       [% L.button_tag('kivi.Draft.popup("is", "invoice", "' _ draft_id _ '", "' _ draft_description _ '")', LxERP.t8('Drafts')) %]
186    [%- END %]
187  [% END # id %]
188
189   [% IF id %]
190       [%#- button for saving history %]
191       <input type="button" class="submit" onclick="set_history_window([% id | html %], 'glid');" name="history" id="history" value="[% 'history' | $T8 %]">
192       [% IF INSTANCE_CONF.get_is_show_mark_as_paid %]
193         [% L.submit_tag("action_mark_as_paid", LxERP.t8('mark as paid'), confirm=LxERP.t8('This will remove the invoice from showing as unpaid even if the unpaid amount does not match the amount. Proceed?')) %]
194       [% END %]
195   [% END %]
196
197   [% IF callback %]
198     <a href="[% callback %]">[% 'back' | $T8  %]</a>
199   [% END %]
200 </div>
201
202 <input type="hidden" name="rowcount" value="[% rowcount %]">
203 <input type="hidden" name="callback" value="[% callback | html %]">
204 [% P.hidden_tag('draft_id', draft_id) %]
205 [% P.hidden_tag('draft_description', draft_description) %]
206 <input type="hidden" name="customer_discount" value="[% customer_discount %]">
207 <input type="hidden" name="gldate" value="[% gldate %]">
208 </form>
209 <script type='text/javascript'>
210  $(kivi.SalesPurchase.init_on_submit_checks);
211 </script>