Revision 4f775679
Von Sven Schöling vor fast 3 Jahren hinzugefügt
SL/Controller/CsvImport/DeliveryOrder.pm | ||
---|---|---|
9 | 9 |
|
10 | 10 |
use SL::Controller::CsvImport::Helper::Consistency; |
11 | 11 |
use SL::DB::DeliveryOrder; |
12 |
use SL::DB::DeliveryOrder::TypeData qw(:types); |
|
12 | 13 |
use SL::DB::DeliveryOrderItem; |
13 | 14 |
use SL::DB::DeliveryOrderItemsStock; |
14 | 15 |
use SL::DB::Part; |
... | ... | |
215 | 216 |
{ name => 'globalprojectnumber', description => $::locale->text('Document Project (number)') }, |
216 | 217 |
{ name => 'globalproject_id', description => $::locale->text('Document Project (database ID)') }, |
217 | 218 |
{ name => 'intnotes', description => $::locale->text('Internal Notes') }, |
218 |
{ name => 'is_sales', description => $::locale->text('Is sales') }, |
|
219 | 219 |
{ name => 'language', description => $::locale->text('Language (name)') }, |
220 | 220 |
{ name => 'language_id', description => $::locale->text('Language (database ID)') }, |
221 | 221 |
{ name => 'notes', description => $::locale->text('Notes') }, |
222 |
{ name => 'order_type', description => $::locale->text('Delivery Order Type') }, |
|
222 | 223 |
{ name => 'ordnumber', description => $::locale->text('Order Number') }, |
223 | 224 |
{ name => 'payment', description => $::locale->text('Payment terms (name)') }, |
224 | 225 |
{ name => 'payment_id', description => $::locale->text('Payment terms (database ID)') }, |
... | ... | |
553 | 554 |
push @{ $entry->{errors} }, $::locale->text('Error: Customer/vendor missing'); |
554 | 555 |
} |
555 | 556 |
|
556 |
$self->handle_is_sales($entry);
|
|
557 |
$self->handle_type($entry);
|
|
557 | 558 |
$self->check_contact($entry); |
558 | 559 |
$self->check_language($entry); |
559 | 560 |
$self->check_payment($entry); |
... | ... | |
685 | 686 |
} |
686 | 687 |
} |
687 | 688 |
|
688 |
sub handle_is_sales {
|
|
689 |
sub handle_type {
|
|
689 | 690 |
my ($self, $entry) = @_; |
690 | 691 |
|
691 |
if (!exists $entry->{raw_data}->{is_sales}) { |
|
692 |
$entry->{object}->is_sales(!!$entry->{object}->customer_id); |
|
692 |
if (!exists $entry->{raw_data}->{order_type}) { |
|
693 |
# if no type is present - set to sales delivery order or purchase delivery |
|
694 |
# order depending on is_sales or customer/vendor |
|
695 |
|
|
696 |
$entry->{object}->order_type( |
|
697 |
$entry->{object}->customer_id ? SALES_DELIVERY_ORDER_TYPE : |
|
698 |
$entry->{object}->vendor_id ? PURCHASE_DELIVERY_ORDER_TYPE : |
|
699 |
$entry->{raw_data}->{is_sales} ? SALES_DELIVERY_ORDER_TYPE : |
|
700 |
PURCHASE_DELIVERY_ORDER_TYPE |
|
701 |
); |
|
693 | 702 |
} |
694 | 703 |
} |
695 | 704 |
|
js/locale/de.js | ||
---|---|---|
177 | 177 |
"Today":"heute", |
178 | 178 |
"Toggle marker":"Markierung umschalten", |
179 | 179 |
"Transaction description":"Vorgangsbezeichnung", |
180 |
"Transfer stock":"Lagerbewebungen",
|
|
180 |
"Transfer stock":"Lagerbewegungen",
|
|
181 | 181 |
"Tue":"Di", |
182 | 182 |
"Tuesday":"Dienstag", |
183 | 183 |
"Update":"Erneuern", |
locale/de/all | ||
---|---|---|
1038 | 1038 |
'Delivery Order Date' => 'Lieferscheindatum', |
1039 | 1039 |
'Delivery Order Date missing!' => 'Lieferscheindatum fehlt!', |
1040 | 1040 |
'Delivery Order Number' => 'Lieferscheinnummer', |
1041 |
'Delivery Order Type' => 'Lieferschein Typ', |
|
1041 | 1042 |
'Delivery Order created' => 'Lieferschein erstellt', |
1042 | 1043 |
'Delivery Order deleted!' => 'Lieferschein gelöscht!', |
1043 | 1044 |
'Delivery Order has been deleted' => 'Lieferschein wurde gelöscht', |
... | ... | |
1855 | 1856 |
'Invoices with payments cannot be canceled.' => 'Rechnungen mit Zahlungen können nicht storniert werden.', |
1856 | 1857 |
'Invoices, Credit Notes & AR Transactions' => 'Rechnungen, Gutschriften & Debitorenbuchungen', |
1857 | 1858 |
'Is Searchable' => 'Durchsuchbar', |
1858 |
'Is sales' => 'Verkauf', |
|
1859 | 1859 |
'Is this a summary account to record' => 'Sammelkonto für', |
1860 | 1860 |
'It can be changed later but must be unique within the installation.' => 'Er ist nachträglich änderbar, muss aber im System eindeutig sein.', |
1861 | 1861 |
'It is not allowed that a summary account occurs in a drop-down menu!' => 'Ein Sammelkonto darf nicht in Aufklappmenüs aufgenommen werden!', |
Auch abrufbar als: Unified diff
CsvImport: Anpassungen für order_type in Lieferscheinen