10 |
10 |
|
11 |
11 |
use SL::DB::Default;
|
12 |
12 |
|
13 |
|
my $oe_scoping = sub {
|
|
13 |
sub oe_scoping {
|
14 |
14 |
SL::DB::Manager::Order->type_filter($_[0]);
|
15 |
|
};
|
|
15 |
}
|
16 |
16 |
|
17 |
|
my $do_scoping = sub {
|
|
17 |
sub do_scoping {
|
18 |
18 |
SL::DB::Manager::DeliveryOrder->type_filter($_[0]);
|
19 |
|
};
|
20 |
|
|
21 |
|
my %specs = ( ar => { number_column => 'invnumber', fill_holes_in_range => 1 },
|
22 |
|
sales_quotation => { number_column => 'quonumber', number_range_column => 'sqnumber', scoping => $oe_scoping, },
|
23 |
|
sales_order => { number_column => 'ordnumber', number_range_column => 'sonumber', scoping => $oe_scoping, },
|
24 |
|
request_quotation => { number_column => 'quonumber', number_range_column => 'rfqnumber', scoping => $oe_scoping, },
|
25 |
|
purchase_order => { number_column => 'ordnumber', number_range_column => 'ponumber', scoping => $oe_scoping, },
|
26 |
|
sales_delivery_order => { number_column => 'donumber', number_range_column => 'sdonumber', scoping => $do_scoping, fill_holes_in_range => 1 },
|
27 |
|
purchase_delivery_order => { number_column => 'donumber', number_range_column => 'pdonumber', scoping => $do_scoping, fill_holes_in_range => 1 },
|
28 |
|
customer => { number_column => 'customernumber', number_range_column => 'customernumber', },
|
29 |
|
vendor => { number_column => 'vendornumber', number_range_column => 'vendornumber', },
|
|
19 |
}
|
|
20 |
|
|
21 |
sub parts_scoping {
|
|
22 |
SL::DB::Manager::Part->type_filter($_[0]);
|
|
23 |
}
|
|
24 |
|
|
25 |
my %specs = ( ar => { number_column => 'invnumber', fill_holes_in_range => 1 },
|
|
26 |
sales_quotation => { number_column => 'quonumber', number_range_column => 'sqnumber', scoping => \&oe_scoping, },
|
|
27 |
sales_order => { number_column => 'ordnumber', number_range_column => 'sonumber', scoping => \&oe_scoping, },
|
|
28 |
request_quotation => { number_column => 'quonumber', number_range_column => 'rfqnumber', scoping => \&oe_scoping, },
|
|
29 |
purchase_order => { number_column => 'ordnumber', number_range_column => 'ponumber', scoping => \&oe_scoping, },
|
|
30 |
sales_delivery_order => { number_column => 'donumber', number_range_column => 'sdonumber', scoping => \&do_scoping, fill_holes_in_range => 1 },
|
|
31 |
purchase_delivery_order => { number_column => 'donumber', number_range_column => 'pdonumber', scoping => \&do_scoping, fill_holes_in_range => 1 },
|
|
32 |
customer => { number_column => 'customernumber', number_range_column => 'customernumber', },
|
|
33 |
vendor => { number_column => 'vendornumber', number_range_column => 'vendornumber', },
|
|
34 |
part => { number_column => 'partnumber', number_range_column => 'articlenumber', scoping => \&parts_scoping },
|
|
35 |
service => { number_column => 'partnumber', number_range_column => 'servicenumber', scoping => \&parts_scoping },
|
|
36 |
assembly => { number_column => 'partnumber', number_range_column => 'articlenumber', scoping => \&parts_scoping },
|
30 |
37 |
);
|
31 |
38 |
|
32 |
39 |
sub get_next_trans_number {
|
Artikelnummernvergabe im TransNumberGenerator