From: Michael Wagner Date: Wed, 23 Mar 2022 19:01:12 +0000 (+0100) Subject: Merge branch 'test' into master_3.5.8 X-Git-Tag: kivitendo-mebil_0.1-0~9^2~1 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=8e083c4270414505dcf58f4732be2ea6c65c5120;hp=0ab3571374dbc1121012f2f058c8cf13993eaa2f;p=kivitendo-erp.git Merge branch 'test' into master_3.5.8 --- diff --git a/SL/Controller/Mebil.pm b/SL/Controller/Mebil.pm index db4a84b11..03a891770 100644 --- a/SL/Controller/Mebil.pm +++ b/SL/Controller/Mebil.pm @@ -51,6 +51,10 @@ sub action_showmap { $::lxdebug->enter_sub; my ($self) = @_; + # call model + $self->{data} = DB::MebilMapping::getMappings($::form->get_standard_dbh); + + $::form->{title} = $::locale->text('Mebil Map'); my $sql = "SELECT fromacc,typ,toacc from mebil_mapping order by ordering"; diff --git a/SL/DB/Helper/Mappings.pm b/SL/DB/Helper/Mappings.pm index 94f7e4744..5fc68552f 100644 --- a/SL/DB/Helper/Mappings.pm +++ b/SL/DB/Helper/Mappings.pm @@ -156,6 +156,7 @@ my %kivitendo_package_names = ( letter => 'letter', letter_draft => 'letter_draft', makemodel => 'make_model', + mebil_mapping => 'mebil_mapping', notes => 'note', orderitems => 'order_item', oe => 'order', diff --git a/SL/DB/Manager/MebilMapping.pm b/SL/DB/Manager/MebilMapping.pm new file mode 100644 index 000000000..6ccaa0821 --- /dev/null +++ b/SL/DB/Manager/MebilMapping.pm @@ -0,0 +1,14 @@ +# This file has been auto-generated only because it didn't exist. +# Feel free to modify it at will; it will not be overwritten automatically. + +package SL::DB::Manager::MebilMapping; + +use strict; + +use parent qw(SL::DB::Helper::Manager); + +sub object_class { 'SL::DB::MebilMapping' } + +__PACKAGE__->make_manager_methods; + +1; diff --git a/SL/DB/MebilMapping.pm b/SL/DB/MebilMapping.pm new file mode 100644 index 000000000..785380ff7 --- /dev/null +++ b/SL/DB/MebilMapping.pm @@ -0,0 +1,16 @@ +package SL::DB::MebilMapping; + +use strict; + +use SL::DB::MetaSetup::MebilMapping; +use SL::DB::Manager::MebilMapping; + +__PACKAGE__->meta->initialize; + +sub getMappings { + my $dbh = shift; + + return SL::DB::Manager::MebilMapping::get_mebilmappings(); +} + +1; diff --git a/SL/DB/MetaSetup/MebilMapping.pm b/SL/DB/MetaSetup/MebilMapping.pm new file mode 100644 index 000000000..a68fc4c4e --- /dev/null +++ b/SL/DB/MetaSetup/MebilMapping.pm @@ -0,0 +1,22 @@ +# This file has been auto-generated. Do not modify it; it will be overwritten +# by rose_auto_create_model.pl automatically. +package SL::DB::MebilMapping; + +use strict; + +use parent qw(SL::DB::Object); + +__PACKAGE__->meta->table('mebil_mapping'); + +__PACKAGE__->meta->columns( + fromacc => { type => 'varchar', length => 200, not_null => 1 }, + id => { type => 'serial', not_null => 1 }, + ordering => { type => 'integer', not_null => 1 }, + toacc => { type => 'varchar', length => 200, not_null => 1 }, + typ => { type => 'character', length => 1, not_null => 1 }, +); + +__PACKAGE__->meta->primary_key_columns([ 'id' ]); + +1; +;