X-Git-Url: http://wagnertech.de/git?p=kivitendo-erp.git;a=blobdiff_plain;f=SL%2FDB%2FMetaSetup%2FLetterDraft.pm;fp=SL%2FDB%2FMetaSetup%2FLetterDraft.pm;h=d395cfbdc00a34abde10a36d656329d9725ad1e7;hp=1ef3fb891f449fba2c96593cf997d925d724055a;hb=53593baa211863fbf66540cf1bcc36c8fb37257f;hpb=deb4d2dbb676d7d6f69dfe7815d6e0cb09bd4a44 diff --git a/SL/DB/MetaSetup/LetterDraft.pm b/SL/DB/MetaSetup/LetterDraft.pm index 1ef3fb891..d395cfbdc 100644 --- a/SL/DB/MetaSetup/LetterDraft.pm +++ b/SL/DB/MetaSetup/LetterDraft.pm @@ -9,34 +9,21 @@ use parent qw(SL::DB::Object); __PACKAGE__->meta->table('letter_draft'); __PACKAGE__->meta->columns( - body => { type => 'text' }, - close => { type => 'text' }, - company_name => { type => 'text' }, - cp_id => { type => 'integer' }, - date => { type => 'date' }, - employee_id => { type => 'integer' }, - employee_position => { type => 'text' }, - greeting => { type => 'text' }, - id => { type => 'integer', not_null => 1, sequence => 'id' }, - intnotes => { type => 'text' }, - itime => { type => 'timestamp', default => 'now()' }, - jobnumber => { type => 'text' }, - letternumber => { type => 'text' }, - mtime => { type => 'timestamp' }, - page_created_for => { type => 'text' }, - rcv_address => { type => 'text' }, - rcv_city => { type => 'text' }, - rcv_contact => { type => 'text' }, - rcv_country => { type => 'text' }, - rcv_countrycode => { type => 'text' }, - rcv_name => { type => 'text' }, - rcv_zipcode => { type => 'text' }, - reference => { type => 'text' }, - salesman_id => { type => 'integer' }, - salesman_position => { type => 'text' }, - subject => { type => 'text' }, - text_created_for => { type => 'text' }, - vc_id => { type => 'integer', not_null => 1 }, + body => { type => 'text' }, + cp_id => { type => 'integer' }, + customer_id => { type => 'integer' }, + date => { type => 'date' }, + employee_id => { type => 'integer' }, + greeting => { type => 'text' }, + id => { type => 'integer', not_null => 1, sequence => 'id' }, + intnotes => { type => 'text' }, + itime => { type => 'timestamp', default => 'now()' }, + letternumber => { type => 'text' }, + mtime => { type => 'timestamp' }, + reference => { type => 'text' }, + salesman_id => { type => 'integer' }, + subject => { type => 'text' }, + vendor_id => { type => 'integer' }, ); __PACKAGE__->meta->primary_key_columns([ 'id' ]); @@ -49,6 +36,11 @@ __PACKAGE__->meta->foreign_keys( key_columns => { cp_id => 'cp_id' }, }, + customer => { + class => 'SL::DB::Customer', + key_columns => { customer_id => 'id' }, + }, + employee => { class => 'SL::DB::Employee', key_columns => { employee_id => 'id' }, @@ -58,6 +50,11 @@ __PACKAGE__->meta->foreign_keys( class => 'SL::DB::Employee', key_columns => { salesman_id => 'id' }, }, + + vendor => { + class => 'SL::DB::Vendor', + key_columns => { vendor_id => 'id' }, + }, ); 1;