From 368f144b970a4b307a50d82bb398e704d65eec43 Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Thu, 13 Jun 2013 17:37:22 +0200 Subject: [PATCH] Mandantenkonfiguration vereinfacht & in mehrere Dateien gespalten und in Tab-Dialog eingebettet --- SL/Controller/ClientConfig.pm | 135 +++---- .../_datev_check_configuration.html | 35 ++ .../client_config/_miscellaneous.html | 17 + .../client_config/_orders_deleteable.html | 27 ++ .../client_config/_posting_configuration.html | 87 +++++ .../webpages/client_config/_warehouse.html | 81 ++++ templates/webpages/client_config/form.html | 361 +++--------------- 7 files changed, 352 insertions(+), 391 deletions(-) create mode 100644 templates/webpages/client_config/_datev_check_configuration.html create mode 100644 templates/webpages/client_config/_miscellaneous.html create mode 100644 templates/webpages/client_config/_orders_deleteable.html create mode 100644 templates/webpages/client_config/_posting_configuration.html create mode 100644 templates/webpages/client_config/_warehouse.html diff --git a/SL/Controller/ClientConfig.pm b/SL/Controller/ClientConfig.pm index e16b090b7..3585e6a8e 100644 --- a/SL/Controller/ClientConfig.pm +++ b/SL/Controller/ClientConfig.pm @@ -5,116 +5,85 @@ use parent qw(SL::Controller::Base); use SL::DB::Default; use SL::Helper::Flash; +use SL::Locale::String qw(t8); __PACKAGE__->run_before('check_auth'); +use Rose::Object::MakeMethods::Generic ( + 'scalar --get_set_init' => [ qw(defaults all_warehouses posting_options payment_options accounting_options inventory_options profit_options) ], +); sub action_edit { my ($self, %params) = @_; - - $self->{posting_options} = [ { title => $::locale->text("never"), value => 0 }, - { title => $::locale->text("every time"), value => 1 }, - { title => $::locale->text("on the same day"), value => 2 }, ]; - $self->{payment_options} = [ { title => $::locale->text("never"), value => 0 }, - { title => $::locale->text("every time"), value => 1 }, - { title => $::locale->text("on the same day"), value => 2 }, ]; - $self->{accounting_options} = [ { title => $::locale->text("Accrual"), value => "accrual" }, - { title => $::locale->text("cash"), value => "cash" }, ]; - $self->{inventory_options} = [ { title => $::locale->text("perpetual"), value => "perpetual" }, - { title => $::locale->text("periodic"), value => "periodic" }, ]; - $self->{profit_options} = [ { title => $::locale->text("balance"), value => "balance" }, - { title => $::locale->text("income"), value => "income" }, ]; - - map { $self->{$_} = SL::DB::Default->get->$_ } qw(is_changeable ir_changeable ar_changeable ap_changeable gl_changeable); - - $self->{payments_changeable} = SL::DB::Default->get->payments_changeable; - - map { $self->{$_} = SL::DB::Default->get->$_ } qw(is_show_mark_as_paid ir_show_mark_as_paid ar_show_mark_as_paid ap_show_mark_as_paid); - - map { $self->{$_} = SL::DB::Default->get->$_ } qw(accounting_method inventory_system profit_determination); - - $self->{show_bestbefore} = SL::DB::Default->get->show_bestbefore; - - map { $self->{$_} = SL::DB::Default->get->$_ } qw(datev_check_on_sales_invoice datev_check_on_purchase_invoice datev_check_on_ar_transaction datev_check_on_ap_transaction datev_check_on_gl_transaction); - # datev check: not implemented yet: - #check_on_cash_and_receipt = 0 - #check_on_dunning = 0 - #check_on_sepa_import = 0 - - map { $self->{$_} = SL::DB::Default->get->$_ } qw(sales_order_show_delete purchase_order_show_delete sales_delivery_order_show_delete purchase_delivery_order_show_delete); - - # All warehouse / transfer default values - map { $self->{$_} = SL::DB::Default->get->$_ } qw(transfer_default transfer_default_use_master_default_bin transfer_default_ignore_onhand - warehouse_id_ignore_onhand bin_id_ignore_onhand warehouse_id bin_id); - - # for the default warehouse and bin we get the list and - # set a empty value with warehouse_id and bin_id = 0 - map { $self->{$_} = SL::DB::Default->get->$_ } qw(warehouse_id bin_id); - $::form->get_lists('warehouses' => { 'key' => 'WAREHOUSES', - 'bins' => 'BINS', }); - $self->{WAREHOUSES} = $::form->{WAREHOUSES}; - # leerer lagerplatz mit id 0 - my $no_default_bin_entry = { 'id' => '0', description => '--', 'BINS' => [ { id => '0', description => ''} ] }; - push @ { $self->{WAREHOUSES} }, $no_default_bin_entry; - - # set defaults to empty - if (my $max = scalar @{ $self->{WAREHOUSES} }) { - $self->{warehouse_id} ||= $self->{WAREHOUSES}->[$max -1]->{id}; - $self->{bin_id} ||= $self->{WAREHOUSES}->[$max -1]->{BINS}->[0]->{id}; - $self->{warehouse_id_ignore_onhand} ||= $self->{WAREHOUSES}->[$max -1]->{id}; - $self->{bin_id_ignore_onhand} ||= $self->{WAREHOUSES}->[$max -1]->{BINS}->[0]->{id}; - } - - $self->{show_weight} = SL::DB::Default->get->show_weight; - - $self->render('client_config/form', title => $::locale->text('Client Configuration')); + $self->edit_form; } - sub action_save { my ($self, %params) = @_; - map { SL::DB::Default->get->update_attributes($_ => $::form->{$_}); } qw(is_changeable ir_changeable ar_changeable ap_changeable gl_changeable); + my $defaults = delete($::form->{defaults}) || {}; - SL::DB::Default->get->update_attributes('payments_changeable' => $::form->{payments_changeable}); + # undef several fields if an empty value has been selected. + foreach (qw(warehouse_id bin_id warehouse_id_ignore_onhand bin_id_ignore_onhand)) { + undef $defaults->{$_} if !$defaults->{$_}; + } - map { SL::DB::Default->get->update_attributes($_ => $::form->{$_}); } qw(is_show_mark_as_paid ir_show_mark_as_paid ar_show_mark_as_paid ap_show_mark_as_paid); + $self->defaults->update_attributes(%{ $defaults }); - map { SL::DB::Default->get->update_attributes($_ => $::form->{$_}); } qw(accounting_method inventory_system profit_determination); + flash_later('info', t8('Client Configuration saved!')); - SL::DB::Default->get->update_attributes('show_bestbefore' => $::form->{show_bestbefore}); + $self->redirect_to(action => 'edit'); +} - map { SL::DB::Default->get->update_attributes($_ => $::form->{$_}); } qw(datev_check_on_sales_invoice datev_check_on_purchase_invoice datev_check_on_ar_transaction datev_check_on_ap_transaction datev_check_on_gl_transaction); +# +# initializers +# - map { SL::DB::Default->get->update_attributes($_ => $::form->{$_}); } qw(sales_order_show_delete purchase_order_show_delete sales_delivery_order_show_delete purchase_delivery_order_show_delete); +sub init_defaults { SL::DB::Default->get } +sub init_all_warehouses { SL::DB::Manager::Warehouse->get_all_sorted } - # undef warehouse_id if the empty value is selected - if ( ($::form->{warehouse_id} == 0) && ($::form->{bin_id} == 0) ) { - undef $::form->{warehouse_id}; - undef $::form->{bin_id}; - } - # undef warehouse_id_ignore_onhand if the empty value is selected - if ( ($::form->{warehouse_id_ignore_onhand} == 0) && ($::form->{bin_id_ignore_onhand} == 0) ) { - undef $::form->{warehouse_id_ignore_onhand}; - undef $::form->{bin_id_ignore_onhand}; - } - - # All warehouse / transfer default values - map { SL::DB::Default->get->update_attributes($_ => $::form->{$_}); } qw(transfer_default transfer_default_use_master_default_bin transfer_default_ignore_onhand - warehouse_id_ignore_onhand bin_id_ignore_onhand warehouse_id bin_id); +sub init_posting_options { + [ { title => t8("never"), value => 0 }, + { title => t8("every time"), value => 1 }, + { title => t8("on the same day"), value => 2 }, ] +} - SL::DB::Default->get->update_attributes('show_weight' => $::form->{show_weight}); +sub init_payment_options { + [ { title => t8("never"), value => 0 }, + { title => t8("every time"), value => 1 }, + { title => t8("on the same day"), value => 2 }, ] +} - flash_later('info', $::locale->text('Client Configuration saved!')); +sub init_accounting_options { + [ { title => t8("Accrual"), value => "accrual" }, + { title => t8("cash"), value => "cash" }, ] +} - $self->redirect_to(action => 'edit'); +sub init_inventory_options { + [ { title => t8("perpetual"), value => "perpetual" }, + { title => t8("periodic"), value => "periodic" }, ] } +sub init_profit_options { + [ { title => t8("balance"), value => "balance" }, + { title => t8("income"), value => "income" }, ] +} -#################### private stuff ########################## +# +# filters +# sub check_auth { $::auth->assert('admin'); } +# +# helpers +# + +sub edit_form { + my ($self) = @_; + $self->render('client_config/form', title => t8('Client Configuration')); +} + 1; diff --git a/templates/webpages/client_config/_datev_check_configuration.html b/templates/webpages/client_config/_datev_check_configuration.html new file mode 100644 index 000000000..13d12aaa2 --- /dev/null +++ b/templates/webpages/client_config/_datev_check_configuration.html @@ -0,0 +1,35 @@ +[%- USE LxERP -%][%- USE L -%] +
+
[% LxERP.t8('DATEV check configuration') %]
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
[% LxERP.t8('It is possible to make a quick DATEV export everytime you post a record to ensure things work nicely with their data requirements. This will result in a slight overhead though you can enable this for each type of record independantly.') %]
[% LxERP.t8('Check on sales invoice') %][% L.yes_no_tag('defaults.datev_check_on_sales_invoice', SELF.defaults.datev_check_on_sales_invoice) %][% LxERP.t8('Perform check when a sales invoice or a payment for a sales invoice is posted?') %]
[% LxERP.t8('Check on purchase invoice') %][% L.yes_no_tag('defaults.datev_check_on_purchase_invoice', SELF.defaults.datev_check_on_purchase_invoice) %][% LxERP.t8('Perform check when a purchase invoice or a payment for a purchase invoice is posted?') %]
[% LxERP.t8('Check on ar transaction') %][% L.yes_no_tag('defaults.datev_check_on_ar_transaction', SELF.defaults.datev_check_on_ar_transaction) %][% LxERP.t8('Perform check when an ar transaction is posted?') %]
[% LxERP.t8('Check on ap transaction') %][% L.yes_no_tag('defaults.datev_check_on_ap_transaction', SELF.defaults.datev_check_on_ap_transaction) %][% LxERP.t8('Perform check when an ap transaction is posted?') %]
[% LxERP.t8('Check on gl transaction') %][% L.yes_no_tag('defaults.datev_check_on_gl_transaction', SELF.defaults.datev_check_on_gl_transaction) %][% LxERP.t8('Perform check when a gl transaction is posted?') %]
+
diff --git a/templates/webpages/client_config/_miscellaneous.html b/templates/webpages/client_config/_miscellaneous.html new file mode 100644 index 000000000..9e257fe0e --- /dev/null +++ b/templates/webpages/client_config/_miscellaneous.html @@ -0,0 +1,17 @@ +[%- USE LxERP -%][%- USE L -%] +
+
[% LxERP.t8('Weight') %]
+ + + + + + + +
[% LxERP.t8('Show weights') %] + [% L.yes_no_tag('defaults.show_weight', SELF.defaults.show_weight) %] + + [% LxERP.t8('Show the weights of articles and the total weight in orders, invoices and delivery notes?') %]
+
+
+ diff --git a/templates/webpages/client_config/_orders_deleteable.html b/templates/webpages/client_config/_orders_deleteable.html new file mode 100644 index 000000000..c15f159e4 --- /dev/null +++ b/templates/webpages/client_config/_orders_deleteable.html @@ -0,0 +1,27 @@ +[%- USE LxERP -%][%- USE L -%] +
+
[% LxERP.t8('Orders / Delivery Orders deleteable') %]
+ + + + + + + + + + + + + + + + + + + + + + +
[% LxERP.t8('Sales Orders deleteable') %][% L.yes_no_tag('defaults.sales_order_show_delete', SELF.defaults.sales_order_show_delete) %][% LxERP.t8('Show delete button in sales orders?') %]
[% LxERP.t8('Purchase Orders deleteable') %][% L.yes_no_tag('defaults.purchase_order_show_delete', SELF.defaults.purchase_order_show_delete) %][% LxERP.t8('Show delete button in purchase orders?') %]
[% LxERP.t8('Sales Delivery Orders deleteable') %][% L.yes_no_tag('defaults.sales_delivery_order_show_delete', SELF.defaults.sales_delivery_order_show_delete) %][% LxERP.t8('Show delete button in sales delivery orders?') %]
[% LxERP.t8('Purchase Delivery Orders deleteable') %][% L.yes_no_tag('defaults.purchase_delivery_order_show_delete', SELF.defaults.purchase_delivery_order_show_delete) %][% LxERP.t8('Show delete button in purchase delivery orders?') %]
+
diff --git a/templates/webpages/client_config/_posting_configuration.html b/templates/webpages/client_config/_posting_configuration.html new file mode 100644 index 000000000..333ae485e --- /dev/null +++ b/templates/webpages/client_config/_posting_configuration.html @@ -0,0 +1,87 @@ +[%- USE L -%][%- USE LxERP -%] +
+
[% LxERP.t8('Posting Configuration') %]
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
[% LxERP.t8('Sales invoices changeable') %][% L.select_tag('defaults.is_changeable', SELF.posting_options, value_key = 'value', title_key = 'title', default = SELF.defaults.is_changeable) %][% LxERP.t8('Should sales invoices be and when should they be changeable or deleteable after posting?') %]
[% LxERP.t8('Purchase invoices changeable') %][% L.select_tag('defaults.ir_changeable', SELF.posting_options, value_key = 'value', title_key = 'title', default = SELF.defaults.ir_changeable) %][% LxERP.t8('Should purchase invoices be and when should they be deleteable after posting?') %]
[% LxERP.t8('AR transactions changeable') %][% L.select_tag('defaults.ar_changeable', SELF.posting_options, value_key = 'value', title_key = 'title', default = SELF.defaults.ar_changeable) %][% LxERP.t8('Should ar transactions be and when should they be changeable or deleteable after posting?') %]
[% LxERP.t8('AP transactions changeable') %][% L.select_tag('defaults.ap_changeable', SELF.posting_options, value_key = 'value', title_key = 'title', default = SELF.defaults.ap_changeable) %][% LxERP.t8('Should ap transactions be and when should they be changeable or deleteable after posting?') %]
[% LxERP.t8('GL transactions changeable') %][% L.select_tag('defaults.gl_changeable', SELF.posting_options, value_key = 'value', title_key = 'title', default = SELF.defaults.gl_changeable) %][% LxERP.t8('Should gl transactions be and when should they be changeable or deleteable after posting?') %]
[% LxERP.t8('Payments Changeable') %][% L.select_tag('defaults.payments_changeable', SELF.payment_options, value_key = 'value', title_key = 'title', default = SELF.defaults.payments_changeable) %][% LxERP.t8('Should payments be and when should they be changeable after posting?') %]
[% LxERP.t8('Show "mark as paid" in sales invoices') %][% L.yes_no_tag('defaults.is_show_mark_as_paid', SELF.defaults.is_show_mark_as_paid) %][% LxERP.t8('Should the "mark as paid" button showed on sales invoices?') %]
[% LxERP.t8('Show "mark as paid" in purchase invoices') %][% L.yes_no_tag('defaults.ir_show_mark_as_paid', SELF.defaults.ir_show_mark_as_paid) %][% LxERP.t8('Should the "mark as paid" button showed in purchase invoices?') %]
[% LxERP.t8('Show "mark as paid" in ar transactions') %][% L.yes_no_tag('defaults.ar_show_mark_as_paid', SELF.defaults.ar_show_mark_as_paid) %][% LxERP.t8('Should the "mark as paid" button showed in ar transactions?') %]
[% LxERP.t8('Show "mark as paid" in ap transactions') %][% L.yes_no_tag('defaults.ap_show_mark_as_paid', SELF.defaults.ap_show_mark_as_paid) %][% LxERP.t8('Should the "mark as paid" button showed in ap transactions?') %]
[% LxERP.t8('Accounting method') %][% L.select_tag('defaults.accounting_method', SELF.accounting_options, value_key = 'value', title_key = 'title', default = SELF.defaults.accounting_method) %][% LxERP.t8('This option controls the posting and calculation behavior for the accounting method.') %]
[% LxERP.t8('Inventory system') %][% L.select_tag('defaults.inventory_system', SELF.inventory_options, value_key = 'value', title_key = 'title', default = SELF.defaults.inventory_system) %] + [% LxERP.t8('This option controls the inventory system.') %]
+ [% LxERP.t8('ATTENTION! You can not simply change it from periodic to perpetual once you started posting.') %] +
[% LxERP.t8('Profit determination') %][% L.select_tag('defaults.profit_determination', SELF.profit_options, value_key = 'value', title_key = 'title', default = SELF.defaults.profit_determination) %][% LxERP.t8('This option controls the method used for profit determination.') %]
+
diff --git a/templates/webpages/client_config/_warehouse.html b/templates/webpages/client_config/_warehouse.html new file mode 100644 index 000000000..79fc7a275 --- /dev/null +++ b/templates/webpages/client_config/_warehouse.html @@ -0,0 +1,81 @@ +[%- USE HTML -%][%- USE LxERP -%][%- USE L -%] +
+
[% LxERP.t8('Warehouse') %]
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
[% LxERP.t8('Default Transfer') %] + [% L.yes_no_tag('defaults.transfer_default', SELF.defaults.transfer_default) %] + + [% LxERP.t8('Show Transfer via default') %]
+
[% LxERP.t8('Default Transfer with Master Bin') %] + [% L.yes_no_tag('defaults.transfer_default_use_master_default_bin', SELF.defaults.transfer_default_use_master_default_bin) %] + + [% LxERP.t8('Use master default bin for Default Transfer, if no default bin for the part is configured') %]
+
[% LxERP.t8('Default Transfer Out with negative inventory') %] + [% L.yes_no_tag('defaults.transfer_default_ignore_onhand', SELF.defaults.transfer_default_ignore_onhand) %] + + [% LxERP.t8('Default Transfer Out always succeed. The current part onhand is ignored and the inventory can have negative stocks (not recommended).') %]
+
[% LxERP.t8('Default Warehouse') %] + [% L.select_tag('defaults.warehouse_id', SELF.all_warehouses, id='warehouse_id', with_empty=1, default=SELF.defaults.warehouse_id, title_key='description', + onchange="warehouse_selected(this.selectedIndex == 0 ? -1 : warehouses[this.selectedIndex - 1].id, -1)") %] + + [% LxERP.t8('This is the default bin for parts') %]
+ [% LxERP.t8('If configured this bin will be preselected for all new parts. Also this bin will be used as the master default bin, if default transfer out with master bin is activated.') %]
+
[% LxERP.t8('Default Bin') %][% L.select_tag('defaults.bin_id', [], id='bin_id', with_empty=1) %]
[% LxERP.t8('Default Warehouse with ignoring on hand') %] + [% L.select_tag('defaults.warehouse_id_ignore_onhand', SELF.all_warehouses, id='warehouse_id_ignore_onhand', with_empty=1, default=SELF.defaults.warehouse_id_ignore_onhand, title_key='description', + onchange="warehouse_selected(this.selectedIndex == 0 ? -1 : warehouses[this.selectedIndex - 1].id, -1, 'bin_id_ignore_onhand')") %] + + [% LxERP.t8('This is the default bin for ignoring onhand') %]
+ [% LxERP.t8('If the default transfer out always succeed use this bin for negative stock quantity.') %]
+
[% LxERP.t8('Default Bin with ignoring onhand') %][% L.select_tag('defaults.bin_id_ignore_onhand', [], id='bin_id_ignore_onhand', with_empty=1) %]
[% LxERP.t8('Show Bestbefore') %] + [% L.yes_no_tag('defaults.show_bestbefore', SELF.defaults.show_bestbefore) %] + + [% LxERP.t8('Show fields used for the best before date?') %]
+ [% LxERP.t8('ATTENTION! If you enabled this feature you can not simply turn it off again without taking care that best_before fields are emptied in the database.') %]
+ [% LxERP.t8('This can be done with the following query:') %]
+
+ UPDATE inventory SET bestbefore = NULL;
+
+ [% LxERP.t8('Any stock contents containing a best before date will be impossible to stock out otherwise.') %] +
+
diff --git a/templates/webpages/client_config/form.html b/templates/webpages/client_config/form.html index 16df61ece..b137b7d5d 100644 --- a/templates/webpages/client_config/form.html +++ b/templates/webpages/client_config/form.html @@ -4,58 +4,40 @@

[% title | html %]

@@ -63,261 +45,24 @@ [% PROCESS 'common/flash.html' %]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
[% 'Posting Configuration' | $T8 %]
[% 'Sales invoices changeable' | $T8 %][% L.select_tag('is_changeable', SELF.posting_options, value_key => 'value', title_key => 'title', default => SELF.is_changeable) %][% 'Should sales invoices be and when should they be changeable or deleteable after posting?' | $T8 %]
[% 'Purchase invoices changeable' | $T8 %][% L.select_tag('ir_changeable', SELF.posting_options, value_key => 'value', title_key => 'title', default => SELF.ir_changeable) %][% 'Should purchase invoices be and when should they be deleteable after posting?' | $T8 %]
[% 'AR transactions changeable' | $T8 %][% L.select_tag('ar_changeable', SELF.posting_options, value_key => 'value', title_key => 'title', default => SELF.ar_changeable) %][% 'Should ar transactions be and when should they be changeable or deleteable after posting?' | $T8 %]
[% 'AP transactions changeable' | $T8 %][% L.select_tag('ap_changeable', SELF.posting_options, value_key => 'value', title_key => 'title', default => SELF.ap_changeable) %][% 'Should ap transactions be and when should they be changeable or deleteable after posting?' | $T8 %]
[% 'GL transactions changeable' | $T8 %][% L.select_tag('gl_changeable', SELF.posting_options, value_key => 'value', title_key => 'title', default => SELF.gl_changeable) %][% 'Should gl transactions be and when should they be changeable or deleteable after posting?' | $T8 %]
[% 'Payments Changeable' | $T8 %][% L.select_tag('payments_changeable', SELF.payment_options, value_key => 'value', title_key => 'title', default => SELF.payments_changeable) %][% 'Should payments be and when should they be changeable after posting?' | $T8 %]
[% 'Show "mark as paid" in sales invoices' | $T8 %][% L.yes_no_tag('is_show_mark_as_paid', SELF.is_show_mark_as_paid) %][% 'Should the "mark as paid" button showed on sales invoices?' | $T8 %]
[% 'Show "mark as paid" in purchase invoices' | $T8 %][% L.yes_no_tag('ir_show_mark_as_paid', SELF.ir_show_mark_as_paid) %][% 'Should the "mark as paid" button showed in purchase invoices?' | $T8 %]
[% 'Show "mark as paid" in ar transactions' | $T8 %][% L.yes_no_tag('ar_show_mark_as_paid', SELF.ar_show_mark_as_paid) %][% 'Should the "mark as paid" button showed in ar transactions?' | $T8 %]
[% 'Show "mark as paid" in ap transactions' | $T8 %][% L.yes_no_tag('ap_show_mark_as_paid', SELF.ap_show_mark_as_paid) %][% 'Should the "mark as paid" button showed in ap transactions?' | $T8 %]
[% 'Accounting method' | $T8 %][% L.select_tag('accounting_method', SELF.accounting_options, value_key => 'value', title_key => 'title', default => SELF.accounting_method) %][% 'This option controls the posting and calculation behavior for the accounting method.' | $T8 %]
[% 'Inventory system' | $T8 %][% L.select_tag('inventory_system', SELF.inventory_options, value_key => 'value', title_key => 'title', default => SELF.inventory_system) %] - [% 'This option controls the inventory system.' | $T8 %]
- [% 'ATTENTION! You can not simply change it from periodic to perpetual once you started posting.' | $T8 %] -
[% 'Profit determination' | $T8 %][% L.select_tag('profit_determination', SELF.profit_options, value_key => 'value', title_key => 'title', default => SELF.profit_determination) %][% 'This option controls the method used for profit determination.' | $T8 %]
[% 'DATEV check configuration' | $T8 %]
[% 'It is possible to make a quick DATEV export everytime you post a record to ensure things work nicely with their data requirements. This will result in a slight overhead though you can enable this for each type of record independantly.' | $T8 %]
[% 'Check on sales invoice' | $T8 %][% L.yes_no_tag('datev_check_on_sales_invoice', SELF.datev_check_on_sales_invoice) %][% 'Perform check when a sales invoice or a payment for a sales invoice is posted?' | $T8 %]
[% 'Check on purchase invoice' | $T8 %][% L.yes_no_tag('datev_check_on_purchase_invoice', SELF.datev_check_on_purchase_invoice) %][% 'Perform check when a purchase invoice or a payment for a purchase invoice is posted?' | $T8 %]
[% 'Check on ar transaction' | $T8 %][% L.yes_no_tag('datev_check_on_ar_transaction', SELF.datev_check_on_ar_transaction) %][% 'Perform check when an ar transaction is posted?' | $T8 %]
[% 'Check on ap transaction' | $T8 %][% L.yes_no_tag('datev_check_on_ap_transaction', SELF.datev_check_on_ap_transaction) %][% 'Perform check when an ap transaction is posted?' | $T8 %]
[% 'Check on gl transaction' | $T8 %][% L.yes_no_tag('datev_check_on_gl_transaction', SELF.datev_check_on_gl_transaction) %][% 'Perform check when a gl transaction is posted?' | $T8 %]
[% 'Orders / Delivery Orders deleteable' | $T8 %]
[% 'Sales Orders deleteable' | $T8 %][% L.yes_no_tag('sales_order_show_delete', SELF.sales_order_show_delete) %][% 'Show delete button in sales orders?' | $T8 %]
[% 'Purchase Orders deleteable' | $T8 %][% L.yes_no_tag('purchase_order_show_delete', SELF.purchase_order_show_delete) %][% 'Show delete button in purchase orders?' | $T8 %]
[% 'Sales Delivery Orders deleteable' | $T8 %][% L.yes_no_tag('sales_delivery_order_show_delete', SELF.sales_delivery_order_show_delete) %][% 'Show delete button in sales delivery orders?' | $T8 %]
[% 'Purchase Delivery Orders deleteable' | $T8 %][% L.yes_no_tag('purchase_delivery_order_show_delete', SELF.purchase_delivery_order_show_delete) %][% 'Show delete button in purchase delivery orders?' | $T8 %]
[% 'Warehouse' | $T8 %]
[% 'Default Transfer' | $T8 %] - [% L.yes_no_tag('transfer_default', SELF.transfer_default) %] - - [% 'Show Transfer via default' | $T8 %]
-
[% 'Default Transfer with Master Bin' | $T8 %] - [% L.yes_no_tag('transfer_default_use_master_default_bin', SELF.transfer_default_use_master_default_bin) %] - - [% 'Use master default bin for Default Transfer, if no default bin for the part is configured' | $T8 %]
-
[% 'Default Transfer Out with negative inventory' | $T8 %] - [% L.yes_no_tag('transfer_default_ignore_onhand', SELF.transfer_default_ignore_onhand) %] - - [% 'Default Transfer Out always succeed. The current part onhand is ignored and the inventory can have negative stocks (not recommended).' | $T8 %]
-
[% 'Default Warehouse' | $T8 %] - - - [% 'This is the default bin for parts' | $T8 %]
- [% 'If configured this bin will be preselected for all new parts. Also this bin will be used as the master default bin, if default transfer out with master bin is activated.' | $T8 %]
-
[% 'Default Bin' | $T8 %]
[% 'Default Warehouse with ignoring on hand' | $T8 %] - - - [% 'This is the default bin for ignoring onhand' | $T8 %]
- [% 'If the default transfer out always succeed use this bin for negative stock quantity.' | $T8 %]
-
[% 'Default Bin with ignoring onhand' | $T8 %]
[% 'Show Bestbefore' | $T8 %] - [% L.yes_no_tag('show_bestbefore', SELF.show_bestbefore) %] - - [% 'Show fields used for the best before date?' | $T8 %]
- [% 'ATTENTION! If you enabled this feature you can not simply turn it off again without taking care that best_before fields are emptied in the database.' | $T8 %]
- [% 'This can be done with the following query:' | $T8 %]
-
- UPDATE inventory SET bestbefore = NULL;
-
- [% 'Any stock contents containing a best before date will be impossible to stock out otherwise.' | $T8 %] -
[% 'Weight' | $T8 %]
[% 'Show weights' | $T8 %] - [% L.yes_no_tag('show_weight', SELF.show_weight) %] - - [% 'Show the weights of articles and the total weight in orders, invoices and delivery notes?' | $T8 %]
-
- -
- -[%- L.hidden_tag('action', 'ClientConfig/dispatch') %] -[%- L.submit_tag('action_save', LxERP.t8('Save')) %] - -

+
+ + +[% PROCESS 'client_config/_posting_configuration.html' %] +[% PROCESS 'client_config/_datev_check_configuration.html' %] +[% PROCESS 'client_config/_orders_deleteable.html' %] +[% PROCESS 'client_config/_warehouse.html' %] +[% PROCESS 'client_config/_miscellaneous.html' %] + +
+ [%- L.hidden_tag('action', 'ClientConfig/dispatch') %] + [%- L.submit_tag('action_save', LxERP.t8('Save')) %] +
-- 2.20.1