1 |
1 |
package SL::DB::DeliveryOrder::TypeData;
|
2 |
2 |
|
3 |
3 |
use strict;
|
|
4 |
use Carp;
|
4 |
5 |
use Exporter qw(import);
|
5 |
6 |
use Scalar::Util qw(weaken);
|
6 |
7 |
use SL::Locale::String qw(t8);
|
... | ... | |
25 |
26 |
saved => t8('Delivery Order has been saved'),
|
26 |
27 |
add => t8("Add Sales Delivery Order"),
|
27 |
28 |
edit => t8("Edit Sales Delivery Order"),
|
|
29 |
attachment => t8("sales_delivery_order_list"),
|
28 |
30 |
},
|
29 |
31 |
show_menu => {
|
30 |
32 |
save_and_quotation => 0,
|
... | ... | |
51 |
53 |
saved => t8('Delivery Order has been saved'),
|
52 |
54 |
add => t8("Add Purchase Delivery Order"),
|
53 |
55 |
edit => t8("Edit Purchase Delivery Order"),
|
|
56 |
attachment => t8("purchase_delivery_order_list"),
|
54 |
57 |
},
|
55 |
58 |
show_menu => {
|
56 |
59 |
save_and_quotation => 0,
|
... | ... | |
77 |
80 |
saved => t8('Delivery Order has been saved'),
|
78 |
81 |
add => t8("Add Supplier Delivery Order"),
|
79 |
82 |
edit => t8("Edit Supplier Delivery Order"),
|
|
83 |
attachment => t8("supplier_delivery_order_list"),
|
80 |
84 |
},
|
81 |
85 |
show_menu => {
|
82 |
86 |
save_and_quotation => 0,
|
... | ... | |
103 |
107 |
saved => t8('Delivery Order has been saved'),
|
104 |
108 |
add => t8("Add RMA Delivery Order"),
|
105 |
109 |
edit => t8("Edit RMA Delivery Order"),
|
|
110 |
attachment => t8("rma_delivery_order_list"),
|
106 |
111 |
},
|
107 |
112 |
show_menu => {
|
108 |
113 |
save_and_quotation => 0,
|
... | ... | |
143 |
148 |
}
|
144 |
149 |
|
145 |
150 |
sub validate_type {
|
146 |
|
my ($self, $type) = @_;
|
|
151 |
my ($type) = @_;
|
147 |
152 |
|
148 |
|
return $valid_types{$type} // die "invalid type";
|
|
153 |
return $valid_types{$type} // confess "invalid type '$type'";
|
149 |
154 |
}
|
150 |
155 |
|
151 |
156 |
sub get {
|
... | ... | |
161 |
166 |
sub get3 {
|
162 |
167 |
my ($type, $topic, $key) = @_;
|
163 |
168 |
|
164 |
|
my $ret = $type_data{$type}{$topic}{$key} // die "unknown property '$key' in topic '$topic'";
|
|
169 |
my $ret = $type_data{$type}{$topic}{$key} // die "unknown property '$key' in topic '$topic' for type '$type'";
|
165 |
170 |
|
166 |
171 |
ref $ret eq 'CODE'
|
167 |
172 |
? $ret->()
|
DeliveryOrder: namen für Anhänge und bessere Fehlermeldungen