Revision a4a745ef
Von Sven Schöling vor fast 3 Jahren hinzugefügt
SL/Controller/RecordLinks.pm | ||
---|---|---|
43 | 43 |
{ title => t8('Sales quotation'), type => 'sales_quotation', model => 'Order', number => 'quonumber', }, |
44 | 44 |
{ title => t8('Sales Order'), type => 'sales_order', model => 'Order', number => 'ordnumber', }, |
45 | 45 |
{ title => t8('Sales delivery order'), type => 'sales_delivery_order', model => 'DeliveryOrder', number => 'donumber', }, |
46 |
{ title => t8('RMA delivery order'), type => 'rma_delivery_order', model => 'DeliveryOrder', number => 'rdonumber', }, |
|
46 | 47 |
{ title => t8('Sales Invoice'), type => 'invoice', model => 'Invoice', number => 'invnumber', }, |
47 | 48 |
{ title => t8('Request for Quotation'), type => 'request_quotation', model => 'Order', number => 'quonumber', }, |
48 | 49 |
{ title => t8('Purchase Order'), type => 'purchase_order', model => 'Order', number => 'ordnumber', }, |
49 | 50 |
{ title => t8('Purchase delivery order'), type => 'purchase_delivery_order', model => 'DeliveryOrder', number => 'donumber', }, |
51 |
{ title => t8('Supplier delivery order'), type => 'supplier_delivery_order', model => 'DeliveryOrder', number => 'sdonumber', }, |
|
50 | 52 |
{ title => t8('Purchase Invoice'), type => 'purchase_invoice', model => 'PurchaseInvoice', number => 'invnumber', }, |
51 | 53 |
{ title => t8('Letter'), type => 'letter', model => 'Letter', number => 'letternumber', description => 'subject', description_title => t8('Subject'), date => 'date', project => undef }, |
52 | 54 |
{ title => t8('Email'), type => 'email_journal', model => 'EmailJournal', number => 'id', description => 'subject', description_title => t8('Subject'), }, |
SL/Presenter/DeliveryOrder.pm | ||
---|---|---|
15 | 15 |
return _do_record($delivery_order, 'sales_delivery_order', %params); |
16 | 16 |
} |
17 | 17 |
|
18 |
sub rma_delivery_order { |
|
19 |
my ($delivery_order, %params) = @_; |
|
20 |
|
|
21 |
return _do_new_record($delivery_order, 'rma_delivery_order', %params); |
|
22 |
} |
|
23 |
|
|
18 | 24 |
sub purchase_delivery_order { |
19 | 25 |
my ($delivery_order, %params) = @_; |
20 | 26 |
|
21 | 27 |
return _do_record($delivery_order, 'purchase_delivery_order', %params); |
22 | 28 |
} |
23 | 29 |
|
30 |
sub supplier_delivery_order { |
|
31 |
my ($delivery_order, %params) = @_; |
|
32 |
|
|
33 |
return _do_new_record($delivery_order, 'supplier_delivery_order', %params); |
|
34 |
} |
|
35 |
|
|
36 |
sub _do_new_record { |
|
37 |
my ($delivery_order, $type, %params) = @_; |
|
38 |
|
|
39 |
$params{display} ||= 'inline'; |
|
40 |
|
|
41 |
croak "Unknown display type '$params{display}'" unless $params{display} =~ m/^(?:inline|table-cell)$/; |
|
42 |
|
|
43 |
my $text = join '', ( |
|
44 |
$params{no_link} ? '' : '<a href="contoller.pl?action=DeliveryOrder/edit&type=' . $type . '&id=' . escape($delivery_order->id) . '">', |
|
45 |
escape($delivery_order->donumber), |
|
46 |
$params{no_link} ? '' : '</a>', |
|
47 |
); |
|
48 |
is_escaped($text); |
|
49 |
} |
|
50 |
|
|
24 | 51 |
sub _do_record { |
25 | 52 |
my ($delivery_order, $type, %params) = @_; |
26 | 53 |
|
SL/Presenter/Record.pm | ||
---|---|---|
48 | 48 |
$output .= _sales_quotation_list( $groups{sales_quotations}, %params) if $groups{sales_quotations}; |
49 | 49 |
$output .= _sales_order_list( $groups{sales_orders}, %params) if $groups{sales_orders}; |
50 | 50 |
$output .= _sales_delivery_order_list( $groups{sales_delivery_orders}, %params) if $groups{sales_delivery_orders}; |
51 |
$output .= _rma_delivery_order_list( $groups{rma_delivery_orders}, %params) if $groups{rma_delivery_orders}; |
|
51 | 52 |
$output .= _sales_invoice_list( $groups{sales_invoices}, %params) if $groups{sales_invoices}; |
52 | 53 |
$output .= _ar_transaction_list( $groups{ar_transactions}, %params) if $groups{ar_transactions}; |
53 | 54 |
|
54 | 55 |
$output .= _request_quotation_list( $groups{purchase_quotations}, %params) if $groups{purchase_quotations}; |
55 | 56 |
$output .= _purchase_order_list( $groups{purchase_orders}, %params) if $groups{purchase_orders}; |
56 | 57 |
$output .= _purchase_delivery_order_list($groups{purchase_delivery_orders}, %params) if $groups{purchase_delivery_orders}; |
58 |
$output .= _supplier_delivery_order_list($groups{supplier_delivery_orders}, %params) if $groups{supplier_delivery_orders}; |
|
57 | 59 |
$output .= _purchase_invoice_list( $groups{purchase_invoices}, %params) if $groups{purchase_invoices}; |
58 | 60 |
$output .= _ap_transaction_list( $groups{ap_transactions}, %params) if $groups{ap_transactions}; |
59 | 61 |
|
... | ... | |
183 | 185 |
shop_orders => sub { (ref($_[0]) eq 'SL::DB::ShopOrder') && $_[0]->id }, |
184 | 186 |
sales_quotations => sub { (ref($_[0]) eq 'SL::DB::Order') && $_[0]->is_type('sales_quotation') }, |
185 | 187 |
sales_orders => sub { (ref($_[0]) eq 'SL::DB::Order') && $_[0]->is_type('sales_order') }, |
186 |
sales_delivery_orders => sub { (ref($_[0]) eq 'SL::DB::DeliveryOrder') && $_[0]->is_sales }, |
|
188 |
sales_delivery_orders => sub { (ref($_[0]) eq 'SL::DB::DeliveryOrder') && $_[0]->is_type('sales_delivery_order') }, |
|
189 |
rma_delivery_orders => sub { (ref($_[0]) eq 'SL::DB::DeliveryOrder') && $_[0]->is_type('rma_delivery_order') }, |
|
187 | 190 |
sales_invoices => sub { (ref($_[0]) eq 'SL::DB::Invoice') && $_[0]->invoice }, |
188 | 191 |
ar_transactions => sub { (ref($_[0]) eq 'SL::DB::Invoice') && !$_[0]->invoice }, |
189 | 192 |
purchase_quotations => sub { (ref($_[0]) eq 'SL::DB::Order') && $_[0]->is_type('request_quotation') }, |
190 | 193 |
purchase_orders => sub { (ref($_[0]) eq 'SL::DB::Order') && $_[0]->is_type('purchase_order') }, |
191 |
purchase_delivery_orders => sub { (ref($_[0]) eq 'SL::DB::DeliveryOrder') && !$_[0]->is_sales }, |
|
194 |
purchase_delivery_orders => sub { (ref($_[0]) eq 'SL::DB::DeliveryOrder') && $_[0]->is_type('purchase_delivery_order') }, |
|
195 |
supplier_delivery_orders => sub { (ref($_[0]) eq 'SL::DB::DeliveryOrder') && $_[0]->is_type('supplier_delivery_order') }, |
|
192 | 196 |
purchase_invoices => sub { (ref($_[0]) eq 'SL::DB::PurchaseInvoice') && $_[0]->invoice }, |
193 | 197 |
ap_transactions => sub { (ref($_[0]) eq 'SL::DB::PurchaseInvoice') && !$_[0]->invoice }, |
194 | 198 |
sepa_collections => sub { (ref($_[0]) eq 'SL::DB::SepaExportItem') && $_[0]->ar_id }, |
... | ... | |
364 | 368 |
); |
365 | 369 |
} |
366 | 370 |
|
371 |
sub _rma_delivery_order_list { |
|
372 |
my ($list, %params) = @_; |
|
373 |
|
|
374 |
return record_list( |
|
375 |
$list, |
|
376 |
title => $::locale->text('RMA Delivery Orders'), |
|
377 |
type => 'rma_delivery_order', |
|
378 |
columns => [ |
|
379 |
[ $::locale->text('Delivery Order Date'), 'transdate' ], |
|
380 |
[ $::locale->text('Delivery Order Number'), sub { $_[0]->presenter->rma_delivery_order(display => 'table-cell') } ], |
|
381 |
[ $::locale->text('Order Number'), 'ordnumber' ], |
|
382 |
[ $::locale->text('Customer'), 'customer' ], |
|
383 |
[ $::locale->text('Transaction description'), 'transaction_description' ], |
|
384 |
[ $::locale->text('Project'), 'globalproject', ], |
|
385 |
[ $::locale->text('Delivered'), 'delivered' ], |
|
386 |
[ $::locale->text('Closed'), 'closed' ], |
|
387 |
], |
|
388 |
%params, |
|
389 |
); |
|
390 |
} |
|
391 |
|
|
367 | 392 |
sub _purchase_delivery_order_list { |
368 | 393 |
my ($list, %params) = @_; |
369 | 394 |
|
... | ... | |
385 | 410 |
); |
386 | 411 |
} |
387 | 412 |
|
413 |
sub _supplier_delivery_order_list { |
|
414 |
my ($list, %params) = @_; |
|
415 |
|
|
416 |
return record_list( |
|
417 |
$list, |
|
418 |
title => $::locale->text('Supplier Delivery Orders'), |
|
419 |
type => 'supplier_delivery_order', |
|
420 |
columns => [ |
|
421 |
[ $::locale->text('Delivery Order Date'), 'transdate' ], |
|
422 |
[ $::locale->text('Delivery Order Number'), sub { $_[0]->presenter->supplier_delivery_order(display => 'table-cell') } ], |
|
423 |
[ $::locale->text('Order Number'), 'ordnumber' ], |
|
424 |
[ $::locale->text('Vendor'), 'vendor' ], |
|
425 |
[ $::locale->text('Transaction description'), 'transaction_description' ], |
|
426 |
[ $::locale->text('Project'), 'globalproject', ], |
|
427 |
[ $::locale->text('Delivered'), 'delivered' ], |
|
428 |
[ $::locale->text('Closed'), 'closed' ], |
|
429 |
], |
|
430 |
%params, |
|
431 |
); |
|
432 |
} |
|
433 |
|
|
388 | 434 |
sub _sales_invoice_list { |
389 | 435 |
my ($list, %params) = @_; |
390 | 436 |
|
... | ... | |
662 | 708 |
|
663 | 709 |
=item * sales delivery orders |
664 | 710 |
|
711 |
=item * rma delivery orders |
|
712 |
|
|
665 | 713 |
=item * sales invoices |
666 | 714 |
|
667 | 715 |
=item * AR transactions |
... | ... | |
672 | 720 |
|
673 | 721 |
=item * purchase delivery orders |
674 | 722 |
|
723 |
=item * supplier delivery orders |
|
724 |
|
|
675 | 725 |
=item * purchase invoices |
676 | 726 |
|
677 | 727 |
=item * AP transactions |
locale/de/all | ||
---|---|---|
2761 | 2761 |
'RFQ Date' => 'Anfragedatum', |
2762 | 2762 |
'RFQ Number' => 'Anfragenummer', |
2763 | 2763 |
'RFQs' => 'Preisanfragen', |
2764 |
'RMA Delivery Orders' => 'Retouren-Lieferscheine', |
|
2765 |
'RMA delivery order' => 'Retouren-Lieferschein', |
|
2764 | 2766 |
'ROP' => 'Mindestlagerbestand', |
2765 | 2767 |
'Ranges of numbers' => 'Nummernkreise', |
2766 | 2768 |
'Re-numbering all sections and function blocks in the order they are currently shown cannot be undone.' => 'Das Neu-Nummerieren aller Abschnitte und Funktionsblöcke kann nicht rückgängig gemacht werden.', |
... | ... | |
3324 | 3326 |
'Sun' => 'So', |
3325 | 3327 |
'Sunday' => 'Sonntag', |
3326 | 3328 |
'Superuser name' => 'Datenbankadministrator', |
3329 |
'Supplier Delivery Orders' => 'Beistell-Lieferscheine', |
|
3330 |
'Supplier delivery order' => 'Beistell-Lieferschein', |
|
3327 | 3331 |
'Supplies' => 'Lieferungen', |
3328 | 3332 |
'Surname' => 'Nachname', |
3329 | 3333 |
'Switzerland' => 'Schweiz', |
Auch abrufbar als: Unified diff
RecordLinks für neue Lieferscheintypen