Revision b683eb9d
Von Sven Schöling vor mehr als 9 Jahren hinzugefügt
SL/DB/MetaSetup/Letter.pm | ||
---|---|---|
9 | 9 |
__PACKAGE__->meta->table('letter'); |
10 | 10 |
|
11 | 11 |
__PACKAGE__->meta->columns( |
12 |
id => { type => 'integer', not_null => 1, sequence => 'id' }, |
|
13 |
vc_id => { type => 'integer', not_null => 1 }, |
|
14 |
rcv_name => { type => 'text' }, |
|
15 |
rcv_contact => { type => 'text' }, |
|
16 |
rcv_address => { type => 'text' }, |
|
17 |
rcv_countrycode => { type => 'text' }, |
|
18 |
rcv_zipcode => { type => 'text' }, |
|
19 |
rcv_city => { type => 'text' }, |
|
20 |
letternumber => { type => 'text' }, |
|
21 |
jobnumber => { type => 'text' }, |
|
22 |
text_created_for => { type => 'text' }, |
|
23 |
date => { type => 'text' }, |
|
24 |
subject => { type => 'text' }, |
|
25 |
greeting => { type => 'text' }, |
|
26 | 12 |
body => { type => 'text' }, |
27 | 13 |
close => { type => 'text' }, |
28 | 14 |
company_name => { type => 'text' }, |
15 |
cp_id => { type => 'integer' }, |
|
16 |
date => { type => 'date' }, |
|
29 | 17 |
employee_id => { type => 'integer' }, |
30 | 18 |
employee_position => { type => 'text' }, |
31 |
salesman_id => { type => 'integer' }, |
|
32 |
salesman_position => { type => 'text' }, |
|
19 |
greeting => { type => 'text' }, |
|
20 |
id => { type => 'integer', not_null => 1, sequence => 'id' }, |
|
21 |
intnotes => { type => 'text' }, |
|
33 | 22 |
itime => { type => 'timestamp', default => 'now()' }, |
23 |
jobnumber => { type => 'text' }, |
|
24 |
letternumber => { type => 'text' }, |
|
34 | 25 |
mtime => { type => 'timestamp' }, |
35 |
rcv_country => { type => 'text' }, |
|
36 | 26 |
page_created_for => { type => 'text' }, |
37 |
cp_id => { type => 'integer' }, |
|
27 |
rcv_address => { type => 'text' }, |
|
28 |
rcv_city => { type => 'text' }, |
|
29 |
rcv_contact => { type => 'text' }, |
|
30 |
rcv_country => { type => 'text' }, |
|
31 |
rcv_countrycode => { type => 'text' }, |
|
32 |
rcv_name => { type => 'text' }, |
|
33 |
rcv_zipcode => { type => 'text' }, |
|
34 |
reference => { type => 'text' }, |
|
35 |
salesman_id => { type => 'integer' }, |
|
36 |
salesman_position => { type => 'text' }, |
|
37 |
subject => { type => 'text' }, |
|
38 |
text_created_for => { type => 'text' }, |
|
39 |
vc_id => { type => 'integer', not_null => 1 }, |
|
38 | 40 |
); |
39 | 41 |
|
40 | 42 |
__PACKAGE__->meta->primary_key_columns([ 'id' ]); |
... | ... | |
42 | 44 |
__PACKAGE__->meta->allow_inline_column_values(1); |
43 | 45 |
|
44 | 46 |
__PACKAGE__->meta->foreign_keys( |
47 |
contact => { |
|
48 |
class => 'SL::DB::Contact', |
|
49 |
key_columns => { cp_id => 'cp_id' }, |
|
50 |
}, |
|
51 |
|
|
45 | 52 |
employee => { |
46 | 53 |
class => 'SL::DB::Employee', |
47 | 54 |
key_columns => { employee_id => 'id' }, |
... | ... | |
53 | 60 |
}, |
54 | 61 |
); |
55 | 62 |
|
56 |
# __PACKAGE__->meta->initialize; |
|
57 |
|
|
58 | 63 |
1; |
59 | 64 |
; |
Auch abrufbar als: Unified diff
RDBO Update: Letter