From 0a0f5f6c969ba1edfec761992c28711ca6004567 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bernd=20Ble=C3=9Fmann?= Date: Mon, 21 Feb 2022 11:39:23 +0100 Subject: [PATCH] Vorgangsbezeichnung in Dialogbuchungs-Vorlage: DB-Upgrade und Rose --- SL/DB/MetaSetup/RecordTemplate.pm | 45 ++++++++++--------- ...cord_templates_transaction_description.sql | 5 +++ 2 files changed, 28 insertions(+), 22 deletions(-) create mode 100644 sql/Pg-upgrade2/add_record_templates_transaction_description.sql diff --git a/SL/DB/MetaSetup/RecordTemplate.pm b/SL/DB/MetaSetup/RecordTemplate.pm index 83850fffa..374f00c7b 100644 --- a/SL/DB/MetaSetup/RecordTemplate.pm +++ b/SL/DB/MetaSetup/RecordTemplate.pm @@ -9,28 +9,29 @@ use parent qw(SL::DB::Object); __PACKAGE__->meta->table('record_templates'); __PACKAGE__->meta->columns( - ar_ap_chart_id => { type => 'integer' }, - cb_transaction => { type => 'boolean', default => 'false', not_null => 1 }, - currency_id => { type => 'integer', not_null => 1 }, - customer_id => { type => 'integer' }, - department_id => { type => 'integer' }, - description => { type => 'text' }, - direct_debit => { type => 'boolean', default => 'false', not_null => 1 }, - employee_id => { type => 'integer' }, - id => { type => 'serial', not_null => 1 }, - itime => { type => 'timestamp', default => 'now()', not_null => 1 }, - mtime => { type => 'timestamp', default => 'now()', not_null => 1 }, - notes => { type => 'text' }, - ob_transaction => { type => 'boolean', default => 'false', not_null => 1 }, - ordnumber => { type => 'text' }, - payment_id => { type => 'integer' }, - project_id => { type => 'integer' }, - reference => { type => 'text' }, - show_details => { type => 'boolean', default => 'false', not_null => 1 }, - taxincluded => { type => 'boolean', default => 'false', not_null => 1 }, - template_name => { type => 'text', not_null => 1 }, - template_type => { type => 'enum', check_in => [ 'ar_transaction', 'ap_transaction', 'gl_transaction' ], db_type => 'record_template_type', not_null => 1 }, - vendor_id => { type => 'integer' }, + ar_ap_chart_id => { type => 'integer' }, + cb_transaction => { type => 'boolean', default => 'false', not_null => 1 }, + currency_id => { type => 'integer', not_null => 1 }, + customer_id => { type => 'integer' }, + department_id => { type => 'integer' }, + description => { type => 'text' }, + direct_debit => { type => 'boolean', default => 'false', not_null => 1 }, + employee_id => { type => 'integer' }, + id => { type => 'serial', not_null => 1 }, + itime => { type => 'timestamp', default => 'now()', not_null => 1 }, + mtime => { type => 'timestamp', default => 'now()', not_null => 1 }, + notes => { type => 'text' }, + ob_transaction => { type => 'boolean', default => 'false', not_null => 1 }, + ordnumber => { type => 'text' }, + payment_id => { type => 'integer' }, + project_id => { type => 'integer' }, + reference => { type => 'text' }, + show_details => { type => 'boolean', default => 'false', not_null => 1 }, + taxincluded => { type => 'boolean', default => 'false', not_null => 1 }, + template_name => { type => 'text', not_null => 1 }, + template_type => { type => 'enum', check_in => [ 'ar_transaction', 'ap_transaction', 'gl_transaction' ], db_type => 'record_template_type', not_null => 1 }, + transaction_description => { type => 'text' }, + vendor_id => { type => 'integer' }, ); __PACKAGE__->meta->primary_key_columns([ 'id' ]); diff --git a/sql/Pg-upgrade2/add_record_templates_transaction_description.sql b/sql/Pg-upgrade2/add_record_templates_transaction_description.sql new file mode 100644 index 000000000..e54fc98c7 --- /dev/null +++ b/sql/Pg-upgrade2/add_record_templates_transaction_description.sql @@ -0,0 +1,5 @@ +-- @tag: add_record_templates_transaction_description +-- @description: Vorgangsbezeichnung in Dialog-Vorlage ergänzen +-- @depends: release_3_5_8 create_record_template_tables + +ALTER TABLE record_templates ADD COLUMN transaction_description TEXT; -- 2.20.1