push @values, like($form->{parts_description});
}
+ if ($form->{show_not_mailed}) {
+ $where .= <<SQL;
+ AND NOT EXISTS (
+ SELECT rl.to_id
+ FROM record_links rl
+ WHERE (rl.from_id = a.id)
+ AND (rl.to_table = 'email_journal')
+ LIMIT 1
+ )
+SQL
+ }
+
if ($form->{show_marked_as_closed}) {
$query .= '
LEFT JOIN (
my @hidden_variables = map { "l_${_}" } @columns;
push @hidden_variables, "l_subtotal", qw(open closed customer invnumber ordnumber cusordnumber transaction_description notes project_id transdatefrom transdateto duedatefrom duedateto
- employee_id salesman_id business_id parts_partnumber parts_description department_id show_marked_as_closed);
+ employee_id salesman_id business_id parts_partnumber parts_description department_id show_marked_as_closed show_not_mailed);
push @hidden_variables, map { "cvar_$_->{name}" } @ct_searchable_custom_variables;
$href = build_std_url('action=ar_transactions', grep { $form->{$_} } @hidden_variables);
'Show mappings (csv_import)' => 'Spaltenzuordnungen anzeigen',
'Show old dunnings' => 'Alte Mahnungen anzeigen',
'Show only marked as paid invoices' => 'Nur "als geschlossen markiert" zeigen',
+ 'Show only not mailed invoices' => 'Nur "nicht per E-Mail versendete" anzeigen',
'Show order' => 'Bestellung anzeigen',
'Show overdue sales quotations and requests for quotations...' => 'Überfällige Angebote und Preisanfragen anzeigen...',
'Show parts' => 'Artikel anzeigen',
<th>[% 'Show only marked as paid invoices' | $T8 %]</th>
<td>[% L.checkbox_tag('show_marked_as_closed') %]</td>
</tr>
+ [% IF INSTANCE_CONF.get_email_journal %]
+ <tr>
+ <th>[% 'Show only not mailed invoices' | $T8 %]</th>
+ <td>[% L.checkbox_tag('show_not_mailed') %]</td>
+ </tr>
+ [% END %]
<tr>
<th align=right nowrap>[% 'Invoice Date' | $T8 %]</th>
<td>