projects
/
kivitendo-erp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
DBI::connect-Options für UTF-8-Encoding auch beim Einspielen von Datenbankupgrades...
[kivitendo-erp.git]
/
SL
/
DB
/
Helper
/
Mappings.pm
diff --git
a/SL/DB/Helper/Mappings.pm
b/SL/DB/Helper/Mappings.pm
index
8382f1f
..
cc4d2ab
100644
(file)
--- a/
SL/DB/Helper/Mappings.pm
+++ b/
SL/DB/Helper/Mappings.pm
@@
-3,6
+3,8
@@
package SL::DB::Helper::Mappings;
use utf8;
use strict;
use utf8;
use strict;
+use SL::Util qw(camelify);
+
require Exporter;
our @ISA = qw(Exporter);
our @EXPORT_OK = qw(get_table_for_package get_package_for_table get_package_names);
require Exporter;
our @ISA = qw(Exporter);
our @EXPORT_OK = qw(get_table_for_package get_package_for_table get_package_names);
@@
-50,10
+52,12
@@
my %lxoffice_package_names = (
contacts => 'contact',
csv_import_profiles => 'csv_import_profile',
csv_import_profile_settings => 'csv_import_profile_setting',
contacts => 'contact',
csv_import_profiles => 'csv_import_profile',
csv_import_profile_settings => 'csv_import_profile_setting',
+ csv_import_reports => 'csv_import_report',
+ csv_import_report_rows => 'csv_import_report_row',
+ csv_import_report_status => 'csv_import_report_status',
custom_variable_configs => 'custom_variable_config',
custom_variables => 'custom_variable',
custom_variables_validity => 'custom_variable_validity',
custom_variable_configs => 'custom_variable_config',
custom_variables => 'custom_variable',
custom_variables_validity => 'custom_variable_validity',
- customertax => 'customer_tax',
datev => 'datev',
defaults => 'default',
delivery_orders => 'delivery_order',
datev => 'datev',
defaults => 'default',
delivery_orders => 'delivery_order',
@@
-70,7
+74,6
@@
my %lxoffice_package_names = (
follow_up_links => 'follow_up_link',
follow_ups => 'follow_up',
generic_translations => 'generic_translation',
follow_up_links => 'follow_up_link',
follow_ups => 'follow_up',
generic_translations => 'generic_translation',
- gifi => 'gifi',
gl => 'GLTransaction',
history_erp => 'history',
inventory => 'inventory',
gl => 'GLTransaction',
history_erp => 'history',
inventory => 'inventory',
@@
-82,7
+85,6
@@
my %lxoffice_package_names = (
oe => 'order',
parts => 'part',
partsgroup => 'parts_group',
oe => 'order',
parts => 'part',
partsgroup => 'parts_group',
- partstax => 'parts_tax',
payment_terms => 'payment_term',
periodic_invoices => 'periodic_invoice',
periodic_invoices_configs => 'periodic_invoices_config',
payment_terms => 'payment_term',
periodic_invoices => 'periodic_invoice',
periodic_invoices_configs => 'periodic_invoices_config',
@@
-91,8
+93,6
@@
my %lxoffice_package_names = (
pricegroup => 'pricegroup',
printers => 'Printer',
record_links => 'record_link',
pricegroup => 'pricegroup',
printers => 'Printer',
record_links => 'record_link',
- rma => 'RMA',
- rmaitems => 'RMA_item',
sepa_export => 'sepa_export',
sepa_export_items => 'sepa_export_item',
schema_info => 'schema_info',
sepa_export => 'sepa_export',
sepa_export_items => 'sepa_export_item',
schema_info => 'schema_info',
@@
-106,7
+106,6
@@
my %lxoffice_package_names = (
units => 'unit',
units_language => 'units_language',
vendor => 'vendor',
units => 'unit',
units_language => 'units_language',
vendor => 'vendor',
- vendortax => 'vendor_tax',
);
my (%lxoffice_tables_to_packages, %lxoffice_tables_to_manager_packages, %lxoffice_packages_to_tables);
);
my (%lxoffice_tables_to_packages, %lxoffice_tables_to_manager_packages, %lxoffice_packages_to_tables);
@@
-160,18
+159,6
@@
sub db {
die "Can't resolve '$string' as a database model, sorry. Did you perhaps forgot to load it?";
}
die "Can't resolve '$string' as a database model, sorry. Did you perhaps forgot to load it?";
}
-sub camelify {
- my ($str) = @_;
- $str =~ s/_+(.)/uc($1)/ge;
- ucfirst $str;
-}
-
-sub snakify {
- my ($str) = @_;
- $str =~ s/(?<!^)\u(.)/'_' . lc($1)/ge;
- lcfirst $str;
-}
-
sub plurify {
my ($str) = @_;
$str . 's';
sub plurify {
my ($str) = @_;
$str . 's';