From: G. Richardson Date: Sun, 7 Aug 2016 21:14:03 +0000 (+0200) Subject: Part: columns assembly und (inventory|expense|income)_accno_id entfernt X-Git-Tag: release-3.5.4~1893 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=e225f710e3d55b9423c0f39a733546fd35ff80d6;p=kivitendo-erp.git Part: columns assembly und (inventory|expense|income)_accno_id entfernt --- diff --git a/SL/DB/MetaSetup/Part.pm b/SL/DB/MetaSetup/Part.pm index 7e9eedcfa..65cd85da2 100644 --- a/SL/DB/MetaSetup/Part.pm +++ b/SL/DB/MetaSetup/Part.pm @@ -15,14 +15,11 @@ __PACKAGE__->meta->columns( description => { type => 'text' }, drawing => { type => 'text' }, ean => { type => 'text' }, - expense_accno_id => { type => 'integer' }, formel => { type => 'text' }, gv => { type => 'numeric', precision => 15, scale => 5 }, has_sernumber => { type => 'boolean', default => 'false' }, id => { type => 'integer', not_null => 1, sequence => 'id' }, image => { type => 'text' }, - income_accno_id => { type => 'integer' }, - inventory_accno_id => { type => 'integer' }, itime => { type => 'timestamp', default => 'now()' }, lastcost => { type => 'numeric', precision => 15, scale => 5 }, listprice => { type => 'numeric', precision => 15, scale => 5 }, @@ -66,21 +63,6 @@ __PACKAGE__->meta->foreign_keys( key_columns => { buchungsgruppen_id => 'id' }, }, - expense_account => { - class => 'SL::DB::Chart', - key_columns => { expense_accno_id => 'id' }, - }, - - income_account => { - class => 'SL::DB::Chart', - key_columns => { income_accno_id => 'id' }, - }, - - inventory_account => { - class => 'SL::DB::Chart', - key_columns => { inventory_accno_id => 'id' }, - }, - partsgroup => { class => 'SL::DB::PartsGroup', key_columns => { partsgroup_id => 'id' }, diff --git a/doc/UPGRADE b/doc/UPGRADE index 2b7b3b7d7..b92165ded 100644 --- a/doc/UPGRADE +++ b/doc/UPGRADE @@ -28,6 +28,11 @@ Upgrade auf v3.4.x Unstable neue Spalte part_type vom ENUM-Typ, der auf die Werte 'part', 'service', 'assembly' und 'assortment' beschränkt ist. +* In der Tabelle parts wurde die Spalten inventory_accno_id, expense_accno_id + und income_accno_id entfernt. Deren Funktionalität wurde schon lange durch + Buchungsgruppen ersetzt und für die Erkennung des Artikeltyps gibt es nun die + Spalte part_type + Upgrade auf v3.4.1 ================== diff --git a/sql/Pg-upgrade2/parts_remove_unneeded_fields.sql b/sql/Pg-upgrade2/parts_remove_unneeded_fields.sql new file mode 100644 index 000000000..fa3a67225 --- /dev/null +++ b/sql/Pg-upgrade2/parts_remove_unneeded_fields.sql @@ -0,0 +1,10 @@ +-- @tag: part_remove_unneeded_fields +-- @description: Removing colums assembly, inventory_accno_id, expense_accno_id, income_accno_id +-- @depends: part_type_enum + +ALTER TABLE parts DROP COLUMN assembly; +ALTER TABLE parts DROP COLUMN inventory_accno_id; +ALTER TABLE parts DROP COLUMN expense_accno_id; +ALTER TABLE parts DROP COLUMN income_accno_id; +-- keep for now: +-- ALTER TABLE parts DROP COLUMN makemodel;