In SL::DB::Manager::Buchungsgruppe die Methoden inventory_accno und
inventory_accno_description entfernt, da hier einfach
inventory_account->accno und inventory_account->description benutzt
werden können.
return @errors;
}
-sub inventory_accno {
- my ($self) = @_;
- require SL::DB::Manager::Chart;
- return SL::DB::Manager::Chart->find_by(id => $self->inventory_accno_id) ? SL::DB::Manager::Chart->find_by(id => $self->inventory_accno_id)->accno() : undef;
-}
-
-sub inventory_accno_description {
- my ($self) = @_;
- require SL::DB::Manager::Chart;
- return SL::DB::Manager::Chart->find_by(id => $self->inventory_accno_id) ? SL::DB::Manager::Chart->find_by(id => $self->inventory_accno_id)->description() : undef;
-}
-
sub income_accno_id {
my ($self, $taxzone) = @_;
my %list = ();
- #inventory_accno der Buchungsgruppe:
- $list{inventory_accno} = SL::DB::Manager::Buchungsgruppe->find_by(id => $buchungsgruppen_id)->inventory_accno;
- $list{inventory_accno_description} = SL::DB::Manager::Buchungsgruppe->find_by(id => $buchungsgruppen_id)->inventory_accno_description;
+ # inventory_accno and description of the Buchungsgruppe:
+ $list{inventory_accno} = SL::DB::Manager::Buchungsgruppe->find_by(id => $buchungsgruppen_id)->inventory_account->accno;
+ $list{inventory_accno_description} = SL::DB::Manager::Buchungsgruppe->find_by(id => $buchungsgruppen_id)->inventory_account->description;
foreach my $taxzonechart (@{ $all_taxzonecharts }) {
$list{ $taxzonechart->taxzone_id }{taxzone_chart_id} = $taxzonechart->id;