1 [% USE HTML %][% USE LxERP %]
2 <body onLoad="fokus()">
4 <div class="listtop">[% title %]</div>
6 <form method="post" name="ct" action="ct.pl" onKeyUp="highlight(event)" onClick="highlight(event)">
8 <ul id="maintab" class="shadetabs">
9 <li class="selected"><a href="#" rel="billing"><translate>Billing Address</translate></a></li>
10 <li><a href="#" rel="shipto"><translate>Shipping Address</translate></a></li>
11 <li><a href="#" rel="contacts">Ansprechpartner</a></li>
12 <li><a href="#" rel="deliveries"><translate>Lieferungen</translate></a></li>
13 <li><a href="#" rel="vcnotes"><translate>Notes</translate></a></li>
14 [%- IF CUSTOM_VARIABLES.size %]
15 <li><a href="#" rel="custom_variables"><translate>Custom Variables</translate></a></li>
19 <div class="tabcontentstyle">
21 <div id="billing" class="tabcontent">
25 [% IF conf_vertreter %]
27 <th align="right">[% IF is_customer %]<translate>Type of Customer</translate>[%- ELSE %]<translate>Type of Vendor</translate>[%- END %]</th>
29 [%- INCLUDE generic/multibox.html
34 label_key = 'description',
39 <th align="right"><translate>Representative</translate></th>
41 [%- INCLUDE generic/multibox.html
43 DATA = ALL_SALESMAN_CUSTOMERS,
52 <th align="right" nowrap><translate>Customer Number</translate></th>
53 <td><input name="customernumber" size="35" value="[% HTML.escape(customernumber) %]"></td>
55 <th align="right" nowrap><translate>Vendor Number</translate></th>
56 <td><input name="vendornumber" size="35" value="[% HTML.escape(vendornumber) %]"></td>
61 <th align="right" nowrap><translate>Greeting</translate></th>
63 <input id="greeting" name="greeting" size="30" value="[% HTML.escape(greeting) %]">
64 [%- INCLUDE generic/multibox.html
65 name = 'selected_company_greeting',
66 DATA = MB_COMPANY_GREETINGS,
69 label_key = 'description',
75 <th align="right" nowrap>[% IF is_customer %]<translate>Customer Name</translate>[%- ELSE %]<translate>Vendor Name</translate>[%- END %]</th>
76 <td><input name="name" size="35" maxlength="75" value="[% HTML.escape(name) %]"></td>
80 <th align="right" nowrap><translate>Department</translate></th>
82 <input name="department_1" size="16" maxlength="75" value="[% HTML.escape(department_1) %]">
83 <input name="department_2" size="16" maxlength="75" value="[% HTML.escape(department_2) %]">
88 <th align="right" nowrap><translate>Street</translate></th>
89 <td><input name="street" size="35" maxlength="75" value="[% HTML.escape(street) %]"></td>
93 <th align="right" nowrap><translate>Zipcode</translate>/<translate>City</translate></th>
95 <input name="zipcode" size="5" maxlength="10" value="[% HTML.escape(zipcode) %]">
96 <input name="city" size="30" maxlength="75" value="[% HTML.escape(city) %]">
101 <th align="right" nowrap><translate>Country</translate></th>
102 <td><input name="country" size="35" maxlength="75" value="[% HTML.escape(country) %]"></td>
106 <th align="right" nowrap><translate>Contact</translate></th>
107 <td><input name="contact" size="28" maxlength="75" value="[% HTML.escape(contact) %]"></td>
111 <th align="right" nowrap><translate>Phone</translate></th>
112 <td><input name="phone" size="30" maxlength="30" value="[% HTML.escape(phone) %]"></td>
116 <th align="right" nowrap><translate>Fax</translate></th>
117 <td><input name="fax" size="30" maxlength="30" value="[% HTML.escape(fax) %]"></td>
121 <th align="right" nowrap><translate>E-mail</translate></th>
122 <td><input name="email" size="45" value="[% HTML.escape(email) %]"></td>
126 <th align="right" nowrap><translate>Homepage</translate></th>
127 <td><input name="homepage" size="45" value="[% HTML.escape(homepage) %]"></td>
133 <th align="right"><translate>Credit Limit</translate></th>
134 <td><input name="creditlimit" size="9" value="[% LxERP.format_amount(creditlimit, 0) %]"></td>
135 <input type="hidden" name="terms" value="[% HTML.escape(terms) %]">
136 <th align="right"><translate>Payment Terms</translate></th>
138 [%- INCLUDE generic/multibox.html
140 DATA = payment_terms,
143 label_key = 'description',
147 <th align="right"><translate>Discount</translate></th>
148 <td><input name="discount" size="4" value="[% LxERP.format_amount(discount) %]"> %</td>
152 <th align="right"><translate>Tax Number / SSN</translate></th>
153 <td><input name="taxnumber" size="20" value="[% HTML.escape(taxnumber) %]"></td>
154 <!-- 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 -->
155 <th align="right"><translate>sales tax identification number</translate></th>
156 <td><input name="ustid" maxlength="14" size="20" value="[% HTML.escape(ustid) %]"></td>
157 [%- IF is_customer %]
158 <th align="right"><translate>our vendor number at customer</translate></th>
159 <td><input name="c_vendor_id" size="10" value="[% HTML.escape(c_vendor_id) %]"></td>
161 <th align="right"><translate>Customer Number</translate></th>
162 <td><input name="v_customer_id" size="10" value="[% HTML.escape(v_customer_id) %]"></td>
167 <th align="right"><translate>Account Number</translate></th>
168 <td><input name="account_number" size="10" maxlength="100" value="[% HTML.escape(account_number) %]"></td>
169 <th align="right"><translate>Bank Code Number</translate></th>
170 <td><input name="bank_code" size="10" maxlength="100" value="[% HTML.escape(bank_code) %]"></td>
171 <th align="right"><translate>Bank</translate></th>
172 <td><input name="bank" size="20" value="[% HTML.escape(bank) %]"></td>
176 <th align="right"><translate>IBAN</translate></th>
177 <td><input name="iban" size="10" maxlength="100" value="[% HTML.escape(iban) %]"></td>
178 <th align="right"><translate>BIC</translate></th>
179 <td><input name="bic" size="10" maxlength="100" value="[% HTML.escape(bic) %]"></td>
182 [%- IF conf_vertreter %]
184 <th align="right"><translate>Username</translate></th>
185 <td><input name="username" maxlength="50" value="[% HTML.escape(username) %]"></td>
186 <th align="right"><translate>Password</translate></th>
187 <td><input name="user_password" value="[% HTML.escape(user_password) %]"></td>
192 [% UNLESS conf_vertreter %]
193 <th align="right">[% IF is_customer %]<translate>Type of Customer</translate>[% ELSE %]<translate>Type of Vendor</translate>[%- END %]</th>
195 [%- INCLUDE generic/multibox.html
200 label_key = 'description',
204 <th align="right"><translate>Language</translate></th>
206 [%- INCLUDE generic/multibox.html
207 name = 'language_id',
211 label_key = 'description',
215 [%- IF is_customer %]
216 <th align="right"><translate>Preisklasse</translate></th>
218 [%- INCLUDE generic/multibox.html
220 DATA = all_pricegroup,
223 label_key = 'pricegroup',
230 <td align="right"><translate>Obsolete</translate></td>
231 <td><input name="obsolete" class="checkbox" type="checkbox" value="1" [% IF obsolete %]checked[% END %]></td>
232 <td align="right"><translate>direct debit</translate></td>
233 <td><input name="direct_debit" class="checkbox" type="checkbox" value="1" [% IF direct_debit %]checked[% END %]></td>
237 <th align="right"><translate>Steuersatz</translate></th>
239 [%- INCLUDE generic/multibox.html
244 label_key = 'description',
247 [%- IF is_customer && !conf_vertreter %]
248 <th align="right"><translate>Salesman</translate></th>
250 [%- INCLUDE generic/multibox.html
251 name = 'salesman_id',
255 label_sub = 'salesman_label',
264 <th align="left" nowrap><translate>Notes</translate></th>
268 <td><textarea name="notes" rows="3" cols="60" wrap="soft">[% HTML.escape(notes) %]</textarea></td>
272 <br style="clear: left" />
275 <div id="shipto" class="tabcontent">
279 <th align="right"><translate>Shipping Address</translate></th>
281 [%- INCLUDE generic/multibox.html
285 onChange = "get_shipto(['shipto_id__' + this.value], ['shiptoname','shiptodepartment_1', 'shiptodepartment_2','shiptostreet','shiptozipcode','shiptocity','shiptocountry','shiptocontact','shiptophone','shiptofax','shiptoemail',enable_delete_shipto,set_gender])",
286 id_key = 'shipto_id',
287 label_sub = 'shipto_label',
288 label_key = 'shipto_label',
294 <th align="right" nowrap><translate>Company Name</translate></th>
295 <td><input id="shiptoname" name="shiptoname" size="35" maxlength="75" value="[% HTML.escape(shiptoname) %]"></td>
299 <th align="right" nowrap><translate>Abteilung</translate></th>
301 <input id="shiptodepartment_1" name="shiptodepartment_1" size="16" maxlength="75" value="[% HTML.escape(shiptodepartment_1) %]">
302 <input id="shiptodepartment_2" name="shiptodepartment_2" size="16" maxlength="75" value="[% HTML.escape(shiptodepartment_2) %]">
307 <th align="right" nowrap><translate>Street</translate></th>
308 <td><input id="shiptostreet" name="shiptostreet" size="35" maxlength="75" value="[% HTML.escape(shiptostreet) %]"></td>
312 <th align="right" nowrap><translate>Zipcode</translate>/<translate>City</translate></th>
314 <input id="shiptozipcode" name="shiptozipcode" size="5" maxlength="75" value="[% HTML.escape(shiptozipcode) %]">
315 <input id="shiptocity" name="shiptocity" size="30" maxlength="75" value="[% HTML.escape(shiptocity) %]">
320 <th align="right" nowrap><translate>Country</translate></th>
321 <td><input id="shiptocountry" name="shiptocountry" size="35" maxlength="75" value="[% HTML.escape(shiptocountry) %]"></td>
325 <th align="right" nowrap><translate>Contact</translate></th>
326 <td><input id="shiptocontact" name="shiptocontact" size="30" maxlength="75" value="[% HTML.escape(shiptocontact) %]"></td>
330 <th align="right" nowrap><translate>Phone</translate></th>
331 <td><input id="shiptophone" name="shiptophone" size="30" maxlength="30" value="[% HTML.escape(shiptophone) %]"></td>
335 <th align="right" nowrap><translate>Fax</translate></th>
336 <td><input id="shiptofax" name="shiptofax" size="30" maxlength="30" value="[% HTML.escape(shiptofax) %]"></td>
340 <th align="right" nowrap><translate>E-mail</translate></th>
341 <td><input id="shiptoemail" name="shiptoemail" size="45" value="[% HTML.escape(shiptoemail) %]"></td>
352 <input type="submit" id="delete_shipto" name="action" value="<translate>Delete Shipto</translate>" disabled>
353 <br style="clear: left" />
356 <div id="contacts" class="tabcontent">
358 <input type="hidden" name="cp_id" value="[% HTML.escape(cp_id) %]">
360 <th align="right"><translate>Ansprechpartner</translate></th>
362 [%- INCLUDE generic/multibox.html
366 onChange = "get_contact(['cp_id__'+this.value],['cp_name','cp_title','cp_givenname','cp_phone1','cp_phone2','cp_email','cp_abteilung','cp_fax','cp_mobile1','cp_mobile2','cp_satphone','cp_satfax','cp_project','cp_privatphone','cp_privatemail','cp_birthday',enable_delete_contact,set_gender])",
368 label_sub = 'contacts_label',
374 <th align="left" nowrap><translate>Gender</translate></th>
376 <select id="cp_gender" name="cp_gender">
377 <option value="m"[% IF cp_gender == 'm' %] selected[% END %]><translate>male</translate></option>
378 <option value="f"[% IF cp_gender == 'f' %] selected[% END %]><translate>female</translate></option>
385 <th align="left" nowrap><translate>Title</translate></th>
387 <input id="cp_title" name="cp_title" size="40" maxlength="75" value="[% HTML.escape(cp_title) %]">
388 [%- INCLUDE generic/multibox.html
389 name = 'selected_cp_title',
393 label_key = 'description',
399 <th align="left" nowrap><translate>Department</translate></th>
401 <input id="cp_abteilung" name="cp_abteilung" size="40" value="[% HTML.escape(cp_abteilung) %]">
402 [%- INCLUDE generic/multibox.html
403 name = 'selected_cp_abteilung',
404 DATA = MB_DEPARTMENT,
407 label_key = 'description',
413 <th align="left" nowrap><translate>Given Name</translate></th>
414 <td><input id="cp_givenname" name="cp_givenname" size="40" maxlength="75" value="[% HTML.escape(cp_givenname) %]"></td>
418 <th align="left" nowrap><translate>Name</translate></th>
419 <td><input id="cp_name" name="cp_name" size="40" maxlength="75" value="[% HTML.escape(cp_name) %]"></td>
423 <th align="left" nowrap><translate>Phone1</translate></th>
424 <td><input id="cp_phone1" name="cp_phone1" size="40" maxlength="75" value="[% HTML.escape(cp_phone1) %]"></td>
428 <th align="left" nowrap><translate>Phone2</translate></th>
429 <td><input id="cp_phone2" name="cp_phone2" size="40" maxlength="75" value="[% HTML.escape(cp_phone2) %]"></td>
433 <th align="left" nowrap><translate>Fax</translate></th>
434 <td><input id="cp_fax" name="cp_fax" size="40" value="[% HTML.escape(cp_fax) %]"></td>
438 <th align="left" nowrap><translate>Mobile1</translate></th>
439 <td><input id="cp_mobile1" name="cp_mobile1" size="40" value="[% HTML.escape(cp_mobile1) %]"></td>
443 <th align="left" nowrap><translate>Mobile2</translate></th>
444 <td><input id="cp_mobile2" name="cp_mobile2" size="40" value="[% HTML.escape(cp_mobile2) %]"></td>
448 <th align="left" nowrap><translate>Sat. Phone</translate></th>
449 <td><input id="cp_satphone" name="cp_satphone" size="40" value="[% HTML.escape(cp_satphone) %]"></td>
453 <th align="left" nowrap><translate>Sat. Fax</translate></th>
454 <td><input id="cp_satfax" name="cp_satfax" size="40" value="[% HTML.escape(cp_satfax) %]"></td>
458 <th align="left" nowrap><translate>Project</translate></th>
459 <td><input id="cp_project" name="cp_project" size="40" value="[% HTML.escape(cp_project) %]"></td>
463 <th align="left" nowrap><translate>E-mail</translate></th>
464 <td><input id="cp_email" name="cp_email" size="40" value="[% HTML.escape(cp_email) %]"></td>
468 <th align="left" nowrap><translate>Private Phone</translate></th>
469 <td><input id="cp_privatphone" name="cp_privatphone" size="40" value="[% HTML.escape(cp_privatphone) %]"></td>
473 <th align="left" nowrap><translate>Private E-mail</translate></th>
474 <td><input id="cp_privatemail" name="cp_privatemail" size="40" value="[% HTML.escape(cp_privatemail) %]"></td>
478 <th align="left" nowrap><translate>Birthday</translate></th>
479 <td><input id="cp_birthday" name="cp_birthday" size="40" value="[% HTML.escape(cp_birthday) %]"></td>
483 <td colspan="2"><hr></td>
487 <th align="left" nowrap><translate>Bcc</translate></th>
488 <td><input name="bcc" size="40" value="[% HTML.escape(bcc) %]"></td>
492 <input type="submit" id="delete_contact" name="action" value="<translate>Delete Contact</translate>" disabled>
493 <br style="clear: left" />
496 <div id="deliveries" class="tabcontent">
499 <th align="right"><translate>Shipping Address</translate></th>
501 [%- INCLUDE generic/multibox.html
502 name = 'delivery_id',
505 onChange = "get_delivery(['shipto_id__' + this.value, 'from__' + from.value, 'to__' + to.value, 'id__' + cvid.value, 'db__' + db.value], ['delivery'])",
506 id_key = 'shipto_id',
507 label_sub = 'shipto_label',
513 <th align="right" nowrap><translate>From</translate></th>
515 <input id="from" name="from" size="10" maxlength="10" onChange="get_delivery(['shipto_id__' + delivery_id.value, 'from__' + this.value, 'to__' + to.value, 'id__' + cvid.value, 'db__' + db.value], ['delivery'])" value="[% HTML.escape(from) %]">
516 <input type="button" name="fromB" id="trigger_from" value="?">
518 <th align="right" nowrap><translate>To (time)</translate></th>
520 <input id="to" name="to" size="10" maxlength="10" onChange="get_delivery(['shipto_id__' + delivery_id.value, 'from__' + from.value, 'to__' + this.value, 'id__' + cvid.value, 'db__' + db.value], ['delivery'])" value="[% HTML.escape(to) %]">
521 <input type="button" name="toB" id="trigger_to" value="?">
533 <br style="clear: left" />
536 <div id="vcnotes" class="tabcontent">
538 [%- IF NOTES && NOTES.size %]
542 <th class="listheading"><translate>Delete</translate></th>
543 <th class="listheading"><translate>Subject</translate></th>
544 <th class="listheading"><translate>Created on</translate></th>
545 <th class="listheading"><translate>Created by</translate></th>
546 <th class="listheading"><translate>Follow-Up Date</translate></th>
547 <th class="listheading"><translate>Follow-Up for</translate></th>
548 <th class="listheading"><translate>Follow-Up done</translate></th>
551 [%- FOREACH row = NOTES %]
552 <tr class="listrow[% loop.count % 2 %]">
553 <input type="hidden" name="NOTE_id_[% loop.count %]" value="[% HTML.escape(row.id) %]">
554 <td>[% UNLESS NOTE_id && (NOTE_id == row.id) %]<input type="checkbox" name="NOTE_delete_[% loop.count %]" value="1">[% END %]</td>
555 <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>
556 <td>[% HTML.escape(row.created_on) %]</td>
557 <td>[% IF row.created_by_name %][% HTML.escape(row.created_by_name) %][% ELSE %][% HTML.escape(row.created_by_login) %][% END %]</td>
558 <td>[% HTML.escape(row.follow_up_date) %]</td>
559 <td>[% IF row.created_for_name %][% HTML.escape(row.created_for_name) %][% ELSE %][% HTML.escape(row.created_for_login) %][% END %]</td>
560 <td>[% IF row.follow_up_date %][% IF row.follow_up_done %]<translate>Yes</translate>[% ELSE %]<translate>No</translate>[% END %][% END %]</td>
564 <input type="hidden" name="NOTES_rowcount" value="[% NOTES.size %]">
570 <div class="listtop">[% IF NOTE_id %]<translate>Edit note</translate>[% ELSE %]<translate>Add note</translate>[% END %]</div>
572 <input type="hidden" name="NOTE_id" value="[% HTML.escape(NOTE_id) %]">
573 <input type="hidden" name="FU_id" value="[% HTML.escape(FU_id) %]">
578 <td valign="right"><translate>Subject</translate></td>
579 <td><input name="NOTE_subject" value="[% HTML.escape(NOTE_subject) %]" size="50"></td>
583 <td valign="right" align="top"><translate>Body</translate></td>
584 <td align="top"><textarea cols="50" rows="10" name="NOTE_body">[% HTML.escape(NOTE_body) %]</textarea></td>
588 <td valign="right"><translate>Follow-Up On</translate></td>
590 <input name="FU_date" id="FU_date" value="[% HTML.escape(FU_date) %]" size="12">
591 <input type="button" name="FU_date_button" id="FU_date_trigger" value="?">
592 <translate>for</translate>
593 <select name="FU_created_for_user">
594 [%- FOREACH row = ALL_EMPLOYEES %]
595 <option value="[% HTML.escape(row.id) %]"[% IF (NOTE_id && (row.id == FU_created_for_user)) || (row.login == login) %] selected[% END %]>
596 [%- IF row.name %][%- HTML.escape(row.name) %] ([% HTML.escape(row.login) %])[% ELSE %][% HTML.escape(row.login) %][% END %]
606 <input type="checkbox" name="FU_done" id="FU_done" value="1"[% IF FU_done %] checked[% END %]>
607 <label for="FU_done"><translate>Follow-Up done</translate></label>
613 <br style="clear: left" />
616 [%- IF CUSTOM_VARIABLES.size %]
617 <div id="custom_variables" class="tabcontent">
621 [%- FOREACH var = CUSTOM_VARIABLES %]
623 <td align="right" valign="top">[% HTML.escape(var.description) %]</td>
624 <td valign="top">[% var.HTML_CODE %]</td>
630 <br style="clear: left" />
636 <script type="text/javascript">
638 function set_gender(gender) {
639 var s = document.getElementById('cp_gender');
641 s.selectedIndex = (gender == 'f') ? 1 : 0;