use SL::IS;
use SL::DN;
+use SL::DB::Department;
use SL::DB::Dunning;
use SL::Helper::Flash qw(flash);
use SL::Locale::String qw(t8);
$main::auth->assert('dunning_edit');
- # setup customer selection
- $form->all_vc(\%myconfig, "customer", "AR");
-
DN->get_config(\%myconfig, \%$form);
- $form->{SHOW_CUSTOMER_SELECTION} = $form->{all_customer} && scalar @{ $form->{all_customer} };
$form->{SHOW_DUNNING_LEVEL_SELECTION} = $form->{DUNNING} && scalar @{ $form->{DUNNING} };
$form->{SHOW_DEPARTMENT_SELECTION} = $form->{all_departments} && scalar @{ $form->{all_departments} || [] };
<tr>
<th align="right">[% 'Customer' | $T8 %]</th>
<td colspan="3">
- [% IF SHOW_CUSTOMER_SELECTION %]
- <select name="customer" class="initial_focus">
- <option></option>
- [% FOREACH row = all_customer %]<option>[% HTML.escape(row.name) %]--[% HTML.escape(row.id) %]</option>[% END %]
- </select>
- [% ELSE %]
<input name="customer" size="35" class="initial_focus">
- [% END %]
</td>
</tr>
</tr>
[% END %]
- [% IF SHOW_DEPARTMENT_SELECTION %]
- <tr>
- <th align="right">[% 'Department' | $T8 %]</th>
- <td colspan="3">
- <select name="department">
- <option></option>
- [% FOREACH row = all_departments %]<option>[% HTML.escape(row.description) %]--[% HTML.escape(row.id) %]</option>[% END %]
- </select>
- </td>
- </tr>
- [% END %]
-
<tr>
<th align="right" nowrap>[% 'Invoice Number' | $T8 %]</th>
<td colspan="3"><input name="invnumber" size="20"></td>