[%- USE HTML %] [%- USE T8 %] [%- USE L %] [%- USE P %] [%- USE LxERP %]

[% title | html %]

[%- INCLUDE 'common/flash.html' %]
[% 'Customer' | $T8 %]: [% P.customer_vendor_picker('letter.vc_id', letter.vc_id, type='customer') %] [%- IF letter.customer_id %] [%- END %]
[% 'Contact Person' | $T8 %] [% L.select_tag('letter.cp_id', letter.cp_id ? letter.customer.contacts : [], value_key='cp_id', title_key='full_name', default=letter.cp_id) %]
[% 'Your Reference' | $T8 %]:
[% 'Letternumber' | $T8 %]:
[% 'Date' | $T8 %]: [% L.date_tag('letter.date_as_date', letter.date_as_date, readonly=readonly) %]
[% 'Subject' | $T8 %]
[% 'Greeting' | $T8 %]
[% 'Body' | $T8 %] [% L.textarea_tag('letter.body_as_restricted_html', letter.body_as_restricted_html, style='width:100%', rows=20, class="texteditor") %]
[% 'Internal Notes' | $T8 %]
[% 'Employee' | $T8 %]
[%- L.select_tag('letter.employee_id', employees, default=letter.employee_id, title_key='safe_name', class='bold', allow_empty=1, style='width:70%') %]
[% 'Salesman' | $T8 %]
[%- L.select_tag('letter.salesman_id', employees, default=letter.salesman_id, title_key='safe_name', class='bold', allow_empty=1, style='width:70%') %]

[% print_options %]
[%- LxERP.t8("Loading...") %]
[%- IF letter.letternumber %] [% END %] [% L.submit_tag('action_delete', LxERP.t8('Delete'), confirm=LxERP.t8('Are you sure you want to delete this letter?')) %]