Revision eefbbed3
Von Jan Büren vor mehr als 4 Jahren hinzugefügt
SL/VK.pm | ||
---|---|---|
56 | 56 |
# so we extract both versions in our query and later overwrite the description in article mode |
57 | 57 |
|
58 | 58 |
my $query = |
59 |
qq|SELECT ct.id as customerid, ct.name as customername,ct.customernumber,ct.country,ar.invnumber,ar.id,ar.transdate,p.partnumber,p.description as description, pg.partsgroup,i.parts_id,i.qty,i.price_factor,i.discount,i.description as invoice_description,i.lastcost,i.sellprice,i.fxsellprice,i.marge_total,i.marge_percent,i.unit,b.description as business,e.name as employee,e2.name as salesman, to_char(ar.transdate,'Month') as month, to_char(ar.transdate, 'YYYYMM') as nummonth, p.unit as parts_unit, p.weight, ar.taxincluded | . |
|
59 |
qq|SELECT ct.id as customerid, ct.name as customername,ct.customernumber,ct.country,ar.invnumber,ar.shipvia,ar.id,ar.transdate,p.partnumber,p.description as description, pg.partsgroup,i.parts_id,i.qty,i.price_factor,i.discount,i.description as invoice_description,i.lastcost,i.sellprice,i.fxsellprice,i.marge_total,i.marge_percent,i.unit,b.description as business,e.name as employee,e2.name as salesman, to_char(ar.transdate,'Month') as month, to_char(ar.transdate, 'YYYYMM') as nummonth, p.unit as parts_unit, p.weight, ar.taxincluded | .
|
|
60 | 60 |
qq|, COALESCE(er.buy, 1) | . |
61 | 61 |
qq|FROM invoice i | . |
62 | 62 |
qq|RIGHT JOIN ar on (i.trans_id = ar.id) | . |
bin/mozilla/vk.pl | ||
---|---|---|
137 | 137 |
$form->{title} = $locale->text('Sales Report'); |
138 | 138 |
|
139 | 139 |
@columns = |
140 |
qw(description invnumber transdate customernumber customername partnumber partsgroup country business transdate qty parts_unit weight sellprice sellprice_total discount lastcost lastcost_total marge_total marge_percent employee salesman); |
|
140 |
qw(description invnumber transdate shipvia customernumber customername partnumber partsgroup country business transdate qty parts_unit weight sellprice sellprice_total discount lastcost lastcost_total marge_total marge_percent employee salesman);
|
|
141 | 141 |
|
142 | 142 |
my @includeable_custom_variables = grep { $_->{includeable} } @{ $cvar_configs_ic }, @{ $cvar_configs_ct }; |
143 | 143 |
my @searchable_custom_variables = grep { $_->{searchable} } @{ $cvar_configs_ic }, @{ $cvar_configs_ct }; |
... | ... | |
171 | 171 |
'salesman' => { 'text' => $locale->text('Salesperson'), }, |
172 | 172 |
'invnumber' => { 'text' => $locale->text('Invoice Number'), }, |
173 | 173 |
'transdate' => { 'text' => $locale->text('Invoice Date'), }, |
174 |
'shipvia' => { 'text' => $locale->text('Ship via'), }, |
|
174 | 175 |
'qty' => { 'text' => $locale->text('Quantity'), }, |
175 | 176 |
'parts_unit' => { 'text' => $locale->text('Base unit'), }, |
176 | 177 |
'weight' => { 'text' => $locale->text('Weight'), }, |
... | ... | |
209 | 210 |
push @options, $locale->text('Department') . " : " . SL::DB::Department->new(id => $form->{department_id})->load->description if $form->{department_id}; |
210 | 211 |
push @options, $locale->text('Invoice Number') . " : $form->{invnumber}" if $form->{invnumber}; |
211 | 212 |
push @options, $locale->text('Invoice Date') . " : $form->{invdate}" if $form->{invdate}; |
213 |
push @options, $locale->text('Ship via') . " : $form->{shipvia}" if $form->{shipvia}; |
|
212 | 214 |
push @options, $locale->text('Part Number') . " : $form->{partnumber}" if $form->{partnumber}; |
213 | 215 |
push @options, $locale->text('Partsgroup') . " : " . SL::DB::PartsGroup->new(id => $form->{partsgroup_id})->load->partsgroup if $form->{partsgroup_id}; |
214 | 216 |
push @options, $locale->text('Country') . " : $form->{country}" if $form->{country}; |
templates/webpages/vk/search_invoice.html | ||
---|---|---|
218 | 218 |
<td align=left><input name="l_country" class=checkbox type=checkbox value=Y>[% 'Country' | $T8 %]</td> |
219 | 219 |
<td align=left><input name="l_business" class=checkbox type=checkbox value=Y>[% 'Customer type' | $T8 %]</td> |
220 | 220 |
</tr> |
221 |
|
|
221 |
<tr> |
|
222 |
<td align=left><input name="l_shipvia" class=checkbox type=checkbox value=Y>[% 'Ship via' | $T8 %]</td> |
|
223 |
</tr> |
|
222 | 224 |
<tr> |
223 | 225 |
<th colspan="4" align="left"> |
224 | 226 |
[% 'Customer variables' | $T8 %] ([% 'Only shown in item mode' | $T8 %]) |
Auch abrufbar als: Unified diff
Verkaufsbericht: Transportmittel in Bericht mitausgeben