Revision 4a06c433
Von Moritz Bunkus vor fast 9 Jahren hinzugefügt
SL/DO.pm | ||
---|---|---|
push @values, conv_date($form->{insertdateto});
|
||
}
|
||
|
||
if ($form->{parts_partnumber}) {
|
||
push @where, <<SQL;
|
||
EXISTS (
|
||
SELECT delivery_order_items.delivery_order_id
|
||
FROM delivery_order_items
|
||
LEFT JOIN parts ON (delivery_order_items.parts_id = parts.id)
|
||
WHERE (delivery_order_items.delivery_order_id = dord.id)
|
||
AND (parts.partnumber ILIKE ?)
|
||
LIMIT 1
|
||
)
|
||
SQL
|
||
push @values, like($form->{parts_partnumber});
|
||
}
|
||
|
||
if ($form->{parts_description}) {
|
||
push @where, <<SQL;
|
||
EXISTS (
|
||
SELECT delivery_order_items.delivery_order_id
|
||
FROM delivery_order_items
|
||
WHERE (delivery_order_items.delivery_order_id = dord.id)
|
||
AND (delivery_order_items.description ILIKE ?)
|
||
LIMIT 1
|
||
)
|
||
SQL
|
||
push @values, like($form->{parts_description});
|
||
}
|
||
|
||
if (@where) {
|
||
$query .= " WHERE " . join(" AND ", map { "($_)" } @where);
|
||
}
|
bin/mozilla/do.pl | ||
---|---|---|
my @hidden_variables = map { "l_${_}" } @columns;
|
||
push @hidden_variables, $form->{vc}, qw(l_closed l_notdelivered open closed delivered notdelivered donumber ordnumber serialnumber cusordnumber
|
||
transaction_description transdatefrom transdateto reqdatefrom reqdateto
|
||
type vc employee_id salesman_id project_id
|
||
type vc employee_id salesman_id project_id parts_partnumber parts_description
|
||
insertdatefrom insertdateto business_id);
|
||
|
||
my $href = build_std_url('action=orders', grep { $form->{$_} } @hidden_variables);
|
||
... | ... | |
if ($form->{transaction_description}) {
|
||
push @options, $locale->text('Transaction description') . " : $form->{transaction_description}";
|
||
}
|
||
if ($form->{parts_description}) {
|
||
push @options, $locale->text('Part Description') . " : $form->{parts_description}";
|
||
}
|
||
if ($form->{parts_partnumber}) {
|
||
push @options, $locale->text('Part Number') . " : $form->{parts_partnumber}";
|
||
}
|
||
if ( $form->{transdatefrom} or $form->{transdateto} ) {
|
||
push @options, $locale->text('Delivery Order Date');
|
||
push @options, $locale->text('From') . " " . $locale->date(\%myconfig, $form->{transdatefrom}, 1) if $form->{transdatefrom};
|
templates/webpages/do/search.html | ||
---|---|---|
|
||
<tr>
|
||
<th align="right">[% 'Transaction description' | $T8 %]</th>
|
||
<td colspan="3"><input name="transaction_description" class="fixed_width"></td>
|
||
<td><input name="transaction_description" class="fixed_width"></td>
|
||
<th align="right">[% 'Part Description' | $T8 %]</th>
|
||
<td><input name="parts_description" size="20"></td>
|
||
</tr>
|
||
|
||
<tr>
|
||
<th align="right">[% 'Project Number' | $T8 %]</th>
|
||
<td colspan="3">
|
||
<td>
|
||
<select name="project_id" class="fixed_width">
|
||
<option></option>
|
||
[%- FOREACH row = ALL_PROJECTS %]
|
||
... | ... | |
[%- END %]
|
||
</select>
|
||
</td>
|
||
<th align="right">[% 'Part Number' | $T8 %]</th>
|
||
<td><input name="parts_partnumber" size="20"></td>
|
||
</tr>
|
||
|
||
<tr>
|
Auch abrufbar als: Unified diff
Lieferscheine: Suche nach Artikelnummer/-beschreibung in Positionen