X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/f5c454e3855012bdb1928f3e4c4964403d4d8163..d08148b9ed1b0d7a34900076e977de9ecdc2af88:/SL/Controller/Taxzones.pm diff --git a/SL/Controller/Taxzones.pm b/SL/Controller/Taxzones.pm index 5f19ea6d3..1e29e6022 100644 --- a/SL/Controller/Taxzones.pm +++ b/SL/Controller/Taxzones.pm @@ -15,6 +15,7 @@ use SL::Controller::ClientConfig; use Rose::Object::MakeMethods::Generic ( scalar => [ qw(config) ], + 'scalar --get_set_init' => [ qw(defaults) ], ); __PACKAGE__->run_before('check_auth'); @@ -54,7 +55,7 @@ sub show_form { sub action_edit { my ($self) = @_; - $self->show_form(title => t8('Edit custom variable'), + $self->show_form(title => t8('Edit taxzone'), CHARTLIST => SL::DB::TaxzoneChart->get_all_accounts_by_taxzone_id($self->config->id)); } @@ -115,6 +116,7 @@ sub create_or_update { } $self->config->save; + $self->config->obsolete($::form->{"obsolete"}); #Save taxzone_charts for new taxzones: if ($is_new) { @@ -135,4 +137,10 @@ sub create_or_update { $self->redirect_to(action => 'list'); } +# +# initializers +# + +sub init_defaults { SL::DB::Default->get }; + 1;