9 <th align="right">[% 'Contacts' | $T8 %]</th>
16 default = SELF.contact.cp_id,
18 empty_title = LxERP.t8('New contact'),
20 title_key = 'full_name',
21 onchange = "kivi.CustomerVendor.selectContact({onFormSet: function(){ contactsMapWidget.testInputs(); local_reinit_widgets(); }});",
28 <th align="right" nowrap>[% 'Gender' | $T8 %]</th>
34 [['m', LxERP.t8('male')], ['f', LxERP.t8('female')]],
35 default = SELF.contact.cp_gender
42 <th align="right" nowrap>[% 'Title' | $T8 %]</th>
45 [% L.input_tag('contact.cp_title', SELF.contact.cp_title, size = 40) %]
46 [% L.select_tag('contact_cp_title_select', SELF.all_titles, with_empty = 1, onchange = '$("#contact_cp_title").val(this.value);') %]
51 <th align="right" nowrap>[% 'Department' | $T8 %]</th>
54 [% L.input_tag('contact.cp_abteilung', SELF.contact.cp_abteilung, size = 40) %]
55 [% L.select_tag('contact_cp_abteilung_select', SELF.all_departments, default = SELF.contact.cp_abteilung, with_empty = 1, onchange = '$("#contact_cp_abteilung").val(this.value);') %]
60 <th align="right" nowrap>[% 'Function/position' | $T8 %]</th>
63 [% L.input_tag('contact.cp_position', SELF.contact.cp_position, size = 40) %]
68 <th align="right" nowrap>[% 'Given Name' | $T8 %]</th>
71 [% L.input_tag('contact.cp_givenname', SELF.contact.cp_givenname, size = 40) %]
76 <th align="right" nowrap>[% 'Surname' | $T8 %]</th>
79 [% L.input_tag('contact.cp_name', SELF.contact.cp_name, size = 40) %]
84 <th align="right" nowrap>[% 'E-mail' | $T8 %]</th>
87 [% L.input_tag('contact.cp_email', SELF.contact.cp_email, size = 40) %]
92 <th align="right" nowrap>[% 'Phone1' | $T8 %]</th>
95 [% L.input_tag('contact.cp_phone1', SELF.contact.cp_phone1, size = 40) %]
100 <th align="right" nowrap>[% 'Phone2' | $T8 %]</th>
103 [% L.input_tag('contact.cp_phone2', SELF.contact.cp_phone2, size = 40) %]
108 <th align="right" nowrap>[% 'Fax' | $T8 %]</th>
111 [% L.input_tag('contact.cp_fax', SELF.contact.cp_fax, size = 40) %]
116 <th align="right" nowrap>[% 'Mobile1' | $T8 %]</th>
119 [% L.input_tag('contact.cp_mobile1', SELF.contact.cp_mobile1, size = 40) %]
124 <th align="right" nowrap>[% 'Mobile2' | $T8 %]</th>
127 [% L.input_tag('contact.cp_mobile2', SELF.contact.cp_mobile2, size = 40) %]
132 <th align="right" nowrap>[% 'Sat. Phone' | $T8 %]</th>
135 [% L.input_tag('contact.cp_satphone', SELF.contact.cp_satphone, size = 40) %]
140 <th align="right" nowrap>[% 'Sat. Fax' | $T8 %]</th>
143 [% L.input_tag('contact.cp_satfax', SELF.contact.cp_satfax, size = 40) %]
148 <th align="right" nowrap>[% 'Project' | $T8 %]</th>
151 [% L.input_tag('contact.cp_project', SELF.contact.cp_project, size = 40) %]
156 <th align="right" nowrap>[% 'Street' | $T8 %]</th>
159 [% L.input_tag('contact.cp_street', SELF.contact.cp_street, size = 40) %]
160 <span id="contact_map"></span>
161 <script type="text/javascript">
162 var contactsMapWidget = new kivi.CustomerVendor.MapWidget('contact_cp_');
164 contactsMapWidget.render($('#contact_map'));
171 <th align="right" nowrap>[% 'Zip, City' | $T8 %]</th>
174 [% L.input_tag('contact.cp_zipcode', SELF.contact.cp_zipcode, size = 5) %]
175 [% L.input_tag('contact.cp_city', SELF.contact.cp_city, size = 25) %]
180 <th align="right" nowrap>[% 'Private Phone' | $T8 %]</th>
183 [% L.input_tag('contact.cp_privatphone', SELF.contact.cp_privatphone, size = 40) %]
188 <th align="right" nowrap>[% 'Private E-mail' | $T8 %]</th>
191 [% L.input_tag('contact.cp_privatemail', SELF.contact.cp_privatemail, size = 40) %]
196 <th align="right" nowrap>[% 'Birthday' | $T8 %]</th>
199 [% L.date_tag('contact.cp_birthday', SELF.contact.cp_birthday) %]
203 [% contact_cvars = SELF.contact.cvars_by_config %]
205 [% IF ( contact_cvars.size ) %]
212 [% FOREACH var = contact_cvars %]
214 <th align="right" valign="top" nowrap>[% var.config.description | html %]</th>
217 [% INCLUDE 'common/render_cvar_input.html'
218 cvar_name_prefix = 'contact_cvars.'
227 [% L.button_tag('submitInputButton(this);', LxERP.t8('Delete Contact'), name = 'action_delete_contact', class = 'submit') %]
228 [% IF ( !SELF.contact.cp_id ) %]
229 <script type="text/javascript">
230 $('#action_delete_contact').hide();