2 [% USE HTML %][% USE LxERP %]
8 [% PROCESS 'common/flash.html' %]
10 <form method="post" name="ct" action="ct.pl" >
12 <ul id="maintab" class="shadetabs">
13 <li class="selected"><a href="#" rel="billing">[% 'Billing Address' | $T8 %]</a></li>
14 <li><a href="#" rel="shipto">[% 'Shipping Address' | $T8 %]</a></li>
15 <li><a href="#" rel="contacts">[% 'Contacts' | $T8 %]</a></li>
17 <li><a href="#" rel="deliveries">[% 'Supplies' | $T8 %]</a></li>
19 <li><a href="#" rel="vcnotes">[% 'Notes' | $T8 %]</a></li>
20 [%- IF CUSTOM_VARIABLES.CT.size %]
21 <li><a href="#" rel="custom_variables">[% 'Custom Variables' | $T8 %]</a></li>
25 <div class="tabcontentstyle">
27 <div id="billing" class="tabcontent">
31 [% IF conf_vertreter %]
33 <th align="right">[% IF is_customer %][% 'Type of Customer' | $T8 %][%- ELSE %][% 'Type of Vendor' | $T8 %][%- END %]</th>
35 [%- INCLUDE generic/multibox.html
40 label_key = 'description',
46 <th align="right">[% 'Representative' | $T8 %]</th>
48 <input type="hidden" name="salesman_id" value="[%- HTML.escape(salesman_id) %]"%>
49 [%- HTML.escape(salesman) %]
56 [% 'Representative' | $T8 %]
58 [% 'Change representative to' | $T8 %]
62 [%- INCLUDE generic/multibox.html
63 name = 'new_salesman_id',
64 DATA = ALL_SALESMAN_CUSTOMERS,
74 <th align="right" nowrap>[% 'Customer Number' | $T8 %]</th>
75 <td><input name="customernumber" size="35" value="[% HTML.escape(customernumber) %]"></td>
77 <th align="right" nowrap>[% 'Vendor Number' | $T8 %]</th>
78 <td><input name="vendornumber" size="35" value="[% HTML.escape(vendornumber) %]"></td>
83 <th align="right" nowrap>[% 'Greeting' | $T8 %]</th>
85 <input id="greeting" name="greeting" size="30" value="[% HTML.escape(greeting) %]">
86 [%- INCLUDE generic/multibox.html
87 name = 'selected_company_greeting',
88 DATA = MB_COMPANY_GREETINGS,
91 label_key = 'description',
97 <th align="right" nowrap>[% IF is_customer %][% 'Customer Name' | $T8 %][%- ELSE %][% 'Vendor Name' | $T8 %][%- END %]</th>
98 <td><input name="name" size="35" maxlength="75" value="[% HTML.escape(name) %]"></td>
102 <th align="right" nowrap>[% 'Department' | $T8 %]</th>
104 <input name="department_1" size="16" maxlength="75" value="[% HTML.escape(department_1) %]">
105 <input name="department_2" size="16" maxlength="75" value="[% HTML.escape(department_2) %]">
110 <th align="right" nowrap>[% 'Street' | $T8 %]</th>
111 <td><input name="street" size="35" maxlength="75" value="[% HTML.escape(street) %]"></td>
115 <th align="right" nowrap>[% 'Zipcode' | $T8 %]/[% 'City' | $T8 %]</th>
117 <input name="zipcode" size="5" maxlength="10" value="[% HTML.escape(zipcode) %]">
118 <input name="city" size="30" maxlength="75" value="[% HTML.escape(city) %]">
123 <th align="right" nowrap>[% 'Country' | $T8 %]</th>
124 <td><input name="country" size="35" maxlength="75" value="[% HTML.escape(country) %]"></td>
128 <th align="right" nowrap>[% 'Contact' | $T8 %]</th>
129 <td><input name="contact" size="28" maxlength="75" value="[% HTML.escape(contact) %]"></td>
133 <th align="right" nowrap>[% 'Phone' | $T8 %]</th>
134 <td><input name="phone" size="30" value="[% HTML.escape(phone) %]"></td>
138 <th align="right" nowrap>[% 'Fax' | $T8 %]</th>
139 <td><input name="fax" size="30" maxlength="30" value="[% HTML.escape(fax) %]"></td>
143 <th align="right" nowrap>[% 'E-mail' | $T8 %]</th>
144 <td><input name="email" size="45" value="[% HTML.escape(email) %]"></td>
148 <th align="right" nowrap>
149 [% IF homepage %]<a href="[% HTML.escape(homepage) %]" title="[% 'Open this Website' | $T8 %]" target="_blank">[% 'Homepage' | $T8 %]</a>
150 [% ELSE %][% 'Homepage' | $T8 %]
153 <td><input name="homepage" size="45" title="[% 'Example: http://kivitendo.de' | $T8 %]" value="[% HTML.escape(homepage) %]"></td>
157 <th align="right" nowrap>[% 'Username' | $T8 %]</th>
158 <td><input name="username" size="45" value="[% HTML.escape(username) %]"></td>
162 <th align="right" nowrap>[% 'Password' | $T8 %]</th>
163 <td><input name="user_password" size="45" value="[% HTML.escape(user_password) %]"></td>
169 <th align="right">[% 'Credit Limit' | $T8 %]</th>
170 <td><input name="creditlimit" size="9" value="[% LxERP.format_amount(creditlimit, 0) %]"></td>
171 <input type="hidden" name="terms" value="[% HTML.escape(terms) %]">
172 <th align="right">[% 'Payment Terms' | $T8 %]</th>
174 [%- INCLUDE generic/multibox.html
176 DATA = payment_terms,
179 label_key = 'description',
183 <th align="right">[% 'Discount' | $T8 %]</th>
184 <td><input name="discount" size="4" value="[% LxERP.format_amount(discount) %]"> %</td>
188 <th align="right">[% 'Tax Number / SSN' | $T8 %]</th>
189 <td><input name="taxnumber" size="20" value="[% HTML.escape(taxnumber) %]"></td>
190 <!-- Anm.: R&B 15.11.2008 VAT Reg No ist Ust-ID in GB, aber generell sollte es laut Richardson die sales tax id sein -->
191 <th align="right">[% 'sales tax identification number' | $T8 %]</th>
192 <td><input name="ustid" id="ustid" maxlength="14" size="20" value="[% HTML.escape(ustid) %]"></td>
193 [%- IF is_customer %]
194 <th align="right">[% 'our vendor number at customer' | $T8 %]</th>
195 <td><input name="c_vendor_id" size="10" value="[% HTML.escape(c_vendor_id) %]"></td>
197 <th align="right">[% 'Customer Number' | $T8 %]</th>
198 <td><input name="v_customer_id" size="10" value="[% HTML.escape(v_customer_id) %]"></td>
203 <th align="right">[% 'Account Number' | $T8 %]</th>
204 <td><input name="account_number" size="10" maxlength="100" value="[% HTML.escape(account_number) %]"></td>
205 <th align="right">[% 'Bank Code Number' | $T8 %]</th>
206 <td><input name="bank_code" size="10" maxlength="100" value="[% HTML.escape(bank_code) %]"></td>
207 <th align="right">[% 'Bank' | $T8 %]</th>
208 <td><input name="bank" size="20" value="[% HTML.escape(bank) %]"></td>
212 <th align="right">[% 'IBAN' | $T8 %]</th>
213 <td><input name="iban" size="10" maxlength="100" value="[% HTML.escape(iban) %]"></td>
214 <th align="right">[% 'BIC' | $T8 %]</th>
215 <td><input name="bic" size="10" maxlength="100" value="[% HTML.escape(bic) %]"></td>
216 [%- IF ALL_CURRENCIES.size %]
217 <th align="right">[% 'Currency' | $T8 %]</th>
218 <td>[% L.select_tag('currency', ALL_CURRENCIES, default = currency, with_empty = 1) %]</td>
223 [% UNLESS conf_vertreter %]
224 <th align="right">[% IF is_customer %][% 'Type of Customer' | $T8 %][% ELSE %][% 'Type of Vendor' | $T8 %][%- END %]</th>
226 [%- INCLUDE generic/multibox.html
231 label_key = 'description',
235 <th align="right">[% 'Language' | $T8 %]</th>
237 [%- INCLUDE generic/multibox.html
238 name = 'language_id',
239 default = default_language_id,
243 label_key = 'description',
247 [%- IF is_customer %]
248 <th align="right">[% 'Preisklasse' | $T8 %]</th>
250 [%- INCLUDE generic/multibox.html
252 DATA = all_pricegroup,
255 label_key = 'pricegroup',
262 <td align="right">[% 'Obsolete' | $T8 %]</td>
263 <td><input name="obsolete" class="checkbox" type="checkbox" value="1" [% IF obsolete %]checked[% END %]></td>
264 <td align="right">[% 'direct debit' | $T8 %]</td>
265 <td><input name="direct_debit" class="checkbox" type="checkbox" value="1" [% IF direct_debit %]checked[% END %]></td>
269 <th align="right">[% 'Steuersatz' | $T8 %]</th>
271 [%- INCLUDE generic/multibox.html
277 label_key = 'description',
280 [%- IF is_customer && !conf_vertreter %]
281 <th align="right">[% 'Salesman' | $T8 %]</th>
282 <td>[% L.select_tag('salesman_id', ALL_SALESMEN, default = salesman_id, with_empty = 1, title_key = 'safe_name') %]</td>
289 <th align="left" nowrap>[% 'Internal Notes' | $T8 %]</th>
293 <td><textarea name="notes" rows="3" cols="60" wrap="soft">[% HTML.escape(notes) %]</textarea></td>
297 <br style="clear: left" />
300 <div id="shipto" class="tabcontent">
301 [% INCLUDE 'ct/_shipto.html' %]
304 <div id="contacts" class="tabcontent">
305 [% INCLUDE 'ct/_contact.html' %]
308 <div id="deliveries" class="tabcontent">
311 <th align="right">[% 'Shipping Address' | $T8 %]</th>
313 [% L.select_tag('delivery_id', SHIPTO_ALL, title_sub = \shipto_label, with_empty = 1,
314 onchange = "\$('#delivery').load('ct.pl?action=get_delivery&id=' + \$('#cvid').attr('value') + '&db=' + \$('#db').attr('value') + '&shipto_id=' + this.value)") %]
319 <th align="right" nowrap>[% 'From' | $T8 %]</th>
321 [% L.date_tag('from',
323 onchange => "\$('#delivery').load('ct.pl?action=get_delivery&shipto_id='+ \$('#delivery_id').val() +'&from='+ \$('#from').val() +'&to='+ \$('#to').val() +'&id='+ \$('#cvid').val() +'&db='+ \$('#db').val())")
326 <th align="right" nowrap>[% 'To (time)' | $T8 %]</th>
330 onchange => "\$('#delivery').load('ct.pl?action=get_delivery&shipto_id='+ \$('#delivery_id').val() +'&from='+ \$('#from').val() +'&to='+ \$('#to').val() +'&id='+ \$('#cvid').val() +'&db='+ \$('#db').val())")
343 <br style="clear: left" />
346 <div id="vcnotes" class="tabcontent">
348 [%- IF NOTES && NOTES.size %]
352 <th class="listheading">[% 'Delete' | $T8 %]</th>
353 <th class="listheading">[% 'Subject' | $T8 %]</th>
354 <th class="listheading">[% 'Created on' | $T8 %]</th>
355 <th class="listheading">[% 'Created by' | $T8 %]</th>
356 <th class="listheading">[% 'Follow-Up Date' | $T8 %]</th>
357 <th class="listheading">[% 'Follow-Up for' | $T8 %]</th>
358 <th class="listheading">[% 'Follow-Up done' | $T8 %]</th>
361 [%- FOREACH row = NOTES %]
362 <tr class="listrow[% loop.count % 2 %]">
363 <input type="hidden" name="NOTE_id_[% loop.count %]" value="[% HTML.escape(row.id) %]">
364 <td>[% UNLESS NOTE_id && (NOTE_id == row.id) %]<input type="checkbox" name="NOTE_delete_[% loop.count %]" value="1">[% END %]</td>
365 <td><a href="ct.pl?action=edit&db=[% HTML.url(db) %]&id=[% HTML.url(id) %]&edit_note_id=[% HTML.url(row.id) %]">[% HTML.escape(row.subject) %]</a></td>
366 <td>[% HTML.escape(row.created_on) %]</td>
367 <td>[% IF row.created_by_name %][% HTML.escape(row.created_by_name) %][% ELSE %][% HTML.escape(row.created_by_login) %][% END %]</td>
368 <td>[% HTML.escape(row.follow_up_date) %]</td>
369 <td>[% IF row.created_for_name %][% HTML.escape(row.created_for_name) %][% ELSE %][% HTML.escape(row.created_for_login) %][% END %]</td>
370 <td>[% IF row.follow_up_date %][% IF row.follow_up_done %][% 'Yes' | $T8 %][% ELSE %][% 'No' | $T8 %][% END %][% END %]</td>
374 <input type="hidden" name="NOTES_rowcount" value="[% NOTES.size %]">
380 <div class="listtop">[% IF NOTE_id %][% 'Edit note' | $T8 %][% ELSE %][% 'Add note' | $T8 %][% END %]</div>
382 <input type="hidden" name="NOTE_id" value="[% HTML.escape(NOTE_id) %]">
383 <input type="hidden" name="FU_id" value="[% HTML.escape(FU_id) %]">
388 <td valign="right">[% 'Subject' | $T8 %]</td>
389 <td><input name="NOTE_subject" value="[% HTML.escape(NOTE_subject) %]" size="50"></td>
393 <td valign="right" align="top">[% 'Body' | $T8 %]</td>
394 <td align="top"><textarea cols="50" rows="10" name="NOTE_body">[% HTML.escape(NOTE_body) %]</textarea></td>
398 <td valign="right">[% 'Follow-Up On' | $T8 %]</td>
400 [% L.date_tag('FU_date', FU_date) %]
402 [% L.select_tag('FU_created_for_user', ALL_EMPLOYEES, default = (FU_created_for_user ? FU_created_for_user : USER.id), title='safe_name') %]
409 <input type="checkbox" name="FU_done" id="FU_done" value="1"[% IF FU_done %] checked[% END %]>
410 <label for="FU_done">[% 'Follow-Up done' | $T8 %]</label>
416 <br style="clear: left" />
419 [%- IF CUSTOM_VARIABLES.CT.size %]
420 <div id="custom_variables" class="tabcontent">
424 [%- FOREACH var = CUSTOM_VARIABLES.CT %]
426 <td align="right" valign="top">[% HTML.escape(var.description) %]</td>
427 <td valign="top">[% var.HTML_CODE %]</td>
433 <br style="clear: left" />
439 <script type="text/javascript">
441 function set_gender(gender) {
442 var s = document.getElementById('cp_gender');
444 s.selectedIndex = (gender == 'f') ? 1 : 0;