Revision 89aa19e4
Von Tamino Steinert vor mehr als 1 Jahr hinzugefügt
SL/DB/MetaSetup/DeliveryOrderItem.pm | ||
---|---|---|
22 | 22 |
longdescription => { type => 'text' }, |
23 | 23 |
marge_price_factor => { type => 'numeric', default => 1, precision => 15, scale => 5 }, |
24 | 24 |
mtime => { type => 'timestamp' }, |
25 |
orderer_id => { type => 'integer' }, |
|
25 | 26 |
ordnumber => { type => 'text' }, |
26 | 27 |
parts_id => { type => 'integer', not_null => 1 }, |
27 | 28 |
position => { type => 'integer', not_null => 1 }, |
... | ... | |
47 | 48 |
key_columns => { delivery_order_id => 'id' }, |
48 | 49 |
}, |
49 | 50 |
|
51 |
orderer => { |
|
52 |
class => 'SL::DB::Employee', |
|
53 |
key_columns => { orderer_id => 'id' }, |
|
54 |
}, |
|
55 |
|
|
50 | 56 |
part => { |
51 | 57 |
class => 'SL::DB::Part', |
52 | 58 |
key_columns => { parts_id => 'id' }, |
SL/DB/MetaSetup/OrderItem.pm | ||
---|---|---|
24 | 24 |
marge_total => { type => 'numeric', precision => 15, scale => 5 }, |
25 | 25 |
mtime => { type => 'timestamp' }, |
26 | 26 |
optional => { type => 'boolean', default => 'false' }, |
27 |
orderer_id => { type => 'integer' }, |
|
27 | 28 |
ordnumber => { type => 'text' }, |
28 | 29 |
parts_id => { type => 'integer' }, |
29 | 30 |
position => { type => 'integer', not_null => 1 }, |
... | ... | |
54 | 55 |
key_columns => { trans_id => 'id' }, |
55 | 56 |
}, |
56 | 57 |
|
58 |
orderer => { |
|
59 |
class => 'SL::DB::Employee', |
|
60 |
key_columns => { orderer_id => 'id' }, |
|
61 |
}, |
|
62 |
|
|
57 | 63 |
part => { |
58 | 64 |
class => 'SL::DB::Part', |
59 | 65 |
key_columns => { parts_id => 'id' }, |
SL/OE.pm | ||
---|---|---|
1289 | 1289 |
o.ordnumber, o.transdate, o.cusordnumber, o.subtotal, o.recurring_billing_mode, o.longdescription, |
1290 | 1290 |
o.price_factor_id, o.price_factor, o.marge_price_factor, o.active_price_source, o.active_discount_source, |
1291 | 1291 |
pr.projectnumber, p.formel, |
1292 |
pg.partsgroup, o.pricegroup_id, (SELECT pricegroup FROM pricegroup WHERE id=o.pricegroup_id) as pricegroup |
|
1292 |
pg.partsgroup, o.pricegroup_id, (SELECT pricegroup FROM pricegroup WHERE id=o.pricegroup_id) as pricegroup, |
|
1293 |
e.name as orderer, e.id as orderer_id |
|
1293 | 1294 |
FROM orderitems o |
1294 | 1295 |
JOIN parts p ON (o.parts_id = p.id) |
1295 | 1296 |
JOIN oe ON (o.trans_id = oe.id) |
... | ... | |
1297 | 1298 |
LEFT JOIN chart c2 ON ((SELECT tc.income_accno_id FROM taxzone_charts tc WHERE tc.taxzone_id = ? and tc.buchungsgruppen_id = p.buchungsgruppen_id) = c2.id) |
1298 | 1299 |
LEFT JOIN chart c3 ON ((SELECT tc.expense_accno_id FROM taxzone_charts tc WHERE tc.taxzone_id = ? and tc.buchungsgruppen_id = p.buchungsgruppen_id) = c3.id) |
1299 | 1300 |
LEFT JOIN project pr ON (o.project_id = pr.id) |
1300 |
LEFT JOIN partsgroup pg ON (p.partsgroup_id = pg.id) | . |
|
1301 |
LEFT JOIN partsgroup pg ON (p.partsgroup_id = pg.id) |
|
1302 |
LEFT JOIN employee e ON (o.orderer_id = e.id) | . |
|
1301 | 1303 |
($form->{id} |
1302 | 1304 |
? qq|WHERE o.trans_id = ?| |
1303 | 1305 |
: qq|WHERE o.trans_id IN (| . join(", ", map("?", @ids)) . qq|)|) . |
... | ... | |
1524 | 1526 |
my @arrays = |
1525 | 1527 |
qw(runningnumber number description longdescription qty qty_nofmt ship ship_nofmt unit bin |
1526 | 1528 |
partnotes serialnumber reqdate sellprice sellprice_nofmt listprice listprice_nofmt netprice netprice_nofmt |
1529 |
orderer |
|
1527 | 1530 |
discount discount_nofmt p_discount discount_sub discount_sub_nofmt nodiscount_sub nodiscount_sub_nofmt |
1528 | 1531 |
linetotal linetotal_nofmt nodiscount_linetotal nodiscount_linetotal_nofmt tax_rate projectnumber projectdescription |
1529 | 1532 |
price_factor price_factor_name partsgroup weight weight_nofmt lineweight lineweight_nofmt optional); |
bin/mozilla/io.pl | ||
---|---|---|
175 | 175 |
# position of serialnr is used below! |
176 | 176 |
my @row2_sort = qw( |
177 | 177 |
tax_chart tax serialnr projectnr reqdate subtotal recurring_billing_mode marge listprice lastcost onhand |
178 |
orderer |
|
178 | 179 |
); |
179 | 180 |
# serialnr is important for delivery_orders |
180 | 181 |
if ($form->{type} eq 'sales_delivery_order') { |
... | ... | |
212 | 213 |
vendor_partnumber => { width => 8, value => $locale->text('Vendor Part Number'), display => $is_delivery_order && $is_purchase, }, |
213 | 214 |
tax_chart => { value => "", display => $is_purchase && $is_invoice }, |
214 | 215 |
tax => { value => $locale->text('Tax'), display => $is_purchase && $is_invoice }, |
216 |
orderer => { width => 10, value => $locale->text('Orderer'), display => 1, }, |
|
215 | 217 |
); |
216 | 218 |
my @HEADER = map { $column_def{$_} } @header_sort; |
217 | 219 |
|
... | ... | |
497 | 499 |
default => $::form->{"recurring_billing_mode_$i"} || 'always', |
498 | 500 |
); |
499 | 501 |
|
502 |
# Orderer |
|
503 |
$column_data{orderer} = qq|: $form->{"orderer_$i"}|; |
|
504 |
|
|
500 | 505 |
# begin marge calculations |
501 | 506 |
$form->{"lastcost_$i"} *= 1; |
502 | 507 |
$form->{"marge_percent_$i"} = 0; |
... | ... | |
580 | 585 |
$cgi->hidden("-name" => "price_new_$i", "-value" => $form->format_amount(\%myconfig, $form->{"price_new_$i"})), |
581 | 586 |
map { ($cgi->hidden("-name" => $_, "-id" => $_, "-value" => $form->{$_})); } map { $_."_$i" } |
582 | 587 |
(qw(bo price_old id inventory_accno bin partsgroup partnotes active_price_source active_discount_source |
588 |
orderer_id |
|
583 | 589 |
income_accno expense_accno listprice part_type taxaccounts ordnumber donumber transdate cusordnumber |
584 | 590 |
longdescription basefactor marge_absolut marge_percent marge_price_factor weight), @hidden_vars) |
585 | 591 |
); |
locale/de/all | ||
---|---|---|
2607 | 2607 |
'Order/RFQ Number' => 'Belegnummer', |
2608 | 2608 |
'OrderItem' => 'Position', |
2609 | 2609 |
'Ordered' => 'Von Kunden bestellt', |
2610 |
'Orderer' => 'BestellerIn', |
|
2610 | 2611 |
'Orders' => 'Aufträge', |
2611 | 2612 |
'Orders / Delivery Orders deleteable' => 'Aufträge / Lieferscheine löschbar', |
2612 | 2613 |
'Orders in Webshop' => 'Bestellungen in Webshop', |
locale/en/all | ||
---|---|---|
2606 | 2606 |
'Order/RFQ Number' => '', |
2607 | 2607 |
'OrderItem' => '', |
2608 | 2608 |
'Ordered' => '', |
2609 |
'Orderer' => '', |
|
2609 | 2610 |
'Orders' => '', |
2610 | 2611 |
'Orders / Delivery Orders deleteable' => '', |
2611 | 2612 |
'Orders in Webshop' => '', |
sql/Pg-upgrade2/add_orderer.sql | ||
---|---|---|
1 |
-- @tag: add_orderer |
|
2 |
-- @description: Neue Spalte Besteller in Angebots- und Lieferscheinpositionen |
|
3 |
-- @depends: release_3_8_0 |
|
4 |
-- @ignore: 0 |
|
5 |
|
|
6 |
ALTER TABLE orderitems ADD COLUMN orderer_id INTEGER REFERENCES employee(id); |
|
7 |
ALTER TABLE delivery_order_items ADD COLUMN orderer_id INTEGER REFERENCES employee(id); |
t/workflow/delivery_order_reclamation.t | ||
---|---|---|
281 | 281 |
"sales_delivery_order_items to sales_reclamation_items", |
282 | 282 |
qw( |
283 | 283 |
id delivery_order_id reclamation_id itime mtime |
284 |
cusordnumber marge_price_factor ordnumber transdate |
|
284 |
cusordnumber marge_price_factor ordnumber transdate orderer_id
|
|
285 | 285 |
description reason_description_ext reason_description_int reason_id |
286 | 286 |
)); |
287 | 287 |
} @sales_delivery_order_items, @converted_sales_reclamation_items; |
... | ... | |
301 | 301 |
"sales_reclamation_items to sales_delivery_order_items", |
302 | 302 |
qw( |
303 | 303 |
id delivery_order_id reclamation_id itime mtime |
304 |
cusordnumber marge_price_factor ordnumber transdate |
|
304 |
cusordnumber marge_price_factor ordnumber transdate orderer_id
|
|
305 | 305 |
description reason_description_ext reason_description_int reason_id |
306 | 306 |
)); |
307 | 307 |
} @sales_reclamation_items, @converted_sales_delivery_order_items; |
... | ... | |
323 | 323 |
"purchase_delivery_order_items to purchase_reclamation_items", |
324 | 324 |
qw( |
325 | 325 |
id delivery_order_id reclamation_id itime mtime |
326 |
cusordnumber marge_price_factor ordnumber transdate |
|
326 |
cusordnumber marge_price_factor ordnumber transdate orderer_id
|
|
327 | 327 |
description reason_description_ext reason_description_int reason_id |
328 | 328 |
)); |
329 | 329 |
} @purchase_delivery_order_items, @converted_purchase_reclamation_items; |
... | ... | |
343 | 343 |
"purchase_reclamation_items to purchase_delivery_order_items", |
344 | 344 |
qw( |
345 | 345 |
id delivery_order_id reclamation_id itime mtime |
346 |
cusordnumber marge_price_factor ordnumber transdate |
|
346 |
cusordnumber marge_price_factor ordnumber transdate orderer_id
|
|
347 | 347 |
description reason_description_ext reason_description_int reason_id |
348 | 348 |
)); |
349 | 349 |
} @purchase_reclamation_items, @converted_purchase_delivery_order_items; |
t/workflow/order_reclamation.t | ||
---|---|---|
282 | 282 |
"sales_order_items to sales_reclamation_items", |
283 | 283 |
qw( |
284 | 284 |
id trans_id reclamation_id itime mtime |
285 |
cusordnumber marge_percent marge_price_factor marge_total optional ordnumber ship subtotal transdate |
|
285 |
cusordnumber marge_percent marge_price_factor marge_total optional ordnumber ship subtotal transdate orderer_id
|
|
286 | 286 |
reason_description_ext reason_description_int reason_id |
287 | 287 |
recurring_billing_mode recurring_billing_invoice_id |
288 | 288 |
)); |
... | ... | |
302 | 302 |
"sales_reclamation_items to sales_order_items", |
303 | 303 |
qw( |
304 | 304 |
id trans_id reclamation_id itime mtime |
305 |
cusordnumber marge_percent marge_price_factor marge_total optional ordnumber ship subtotal transdate |
|
305 |
cusordnumber marge_percent marge_price_factor marge_total optional ordnumber ship subtotal transdate orderer_id
|
|
306 | 306 |
reason_description_ext reason_description_int reason_id |
307 | 307 |
recurring_billing_mode recurring_billing_invoice_id |
308 | 308 |
)); |
... | ... | |
323 | 323 |
"purchase_order_items to purchase_reclamation_items", |
324 | 324 |
qw( |
325 | 325 |
id trans_id reclamation_id itime mtime |
326 |
cusordnumber marge_percent marge_price_factor marge_total optional ordnumber ship subtotal transdate |
|
326 |
cusordnumber marge_percent marge_price_factor marge_total optional ordnumber ship subtotal transdate orderer_id
|
|
327 | 327 |
reason_description_ext reason_description_int reason_id |
328 | 328 |
recurring_billing_mode recurring_billing_invoice_id |
329 | 329 |
)); |
... | ... | |
343 | 343 |
"purchase_reclamation_items to purchase_order_items", |
344 | 344 |
qw( |
345 | 345 |
id trans_id reclamation_id itime mtime |
346 |
cusordnumber marge_percent marge_price_factor marge_total optional ordnumber ship subtotal transdate |
|
346 |
cusordnumber marge_percent marge_price_factor marge_total optional ordnumber ship subtotal transdate orderer_id
|
|
347 | 347 |
reason_description_ext reason_description_int reason_id |
348 | 348 |
recurring_billing_mode recurring_billing_invoice_id |
349 | 349 |
)); |
Auch abrufbar als: Unified diff
Besteller zu Auftrags- und Lieferscheinpositionen hinzugefügt