rdbo models: customer und vendor nach de8868c und 4c4939d0.
[kivitendo-erp.git] / SL / DB / MetaSetup / Customer.pm
1 # This file has been auto-generated. Do not modify it; it will be overwritten
2 # by rose_auto_create_model.pl automatically.
3 package SL::DB::Customer;
4
5 use strict;
6
7 use base qw(SL::DB::Object);
8
9 __PACKAGE__->meta->setup(
10   table   => 'customer',
11
12   columns => [
13     id             => { type => 'integer', not_null => 1, sequence => 'id' },
14     name           => { type => 'text', not_null => 1 },
15     department_1   => { type => 'varchar', length => 75 },
16     department_2   => { type => 'varchar', length => 75 },
17     street         => { type => 'varchar', length => 75 },
18     zipcode        => { type => 'varchar', length => 10 },
19     city           => { type => 'varchar', length => 75 },
20     country        => { type => 'varchar', length => 75 },
21     contact        => { type => 'text' },
22     phone          => { type => 'varchar', length => 30 },
23     fax            => { type => 'varchar', length => 30 },
24     homepage       => { type => 'text' },
25     email          => { type => 'text' },
26     notes          => { type => 'text' },
27     discount       => { type => 'float', precision => 4 },
28     taxincluded    => { type => 'boolean' },
29     creditlimit    => { type => 'numeric', default => '0', precision => 5, scale => 15 },
30     terms          => { type => 'integer', default => '0' },
31     customernumber => { type => 'text' },
32     cc             => { type => 'text' },
33     bcc            => { type => 'text' },
34     business_id    => { type => 'integer' },
35     taxnumber      => { type => 'text' },
36     account_number => { type => 'text' },
37     bank_code      => { type => 'text' },
38     bank           => { type => 'text' },
39     language       => { type => 'varchar', length => 5 },
40     datevexport    => { type => 'integer' },
41     itime          => { type => 'timestamp', default => 'now()' },
42     mtime          => { type => 'timestamp' },
43     obsolete       => { type => 'boolean', default => 'false' },
44     username       => { type => 'varchar', length => 50 },
45     user_password  => { type => 'text' },
46     salesman_id    => { type => 'integer' },
47     c_vendor_id    => { type => 'text' },
48     klass          => { type => 'integer', default => '0' },
49     language_id    => { type => 'integer' },
50     payment_id     => { type => 'integer' },
51     taxzone_id     => { type => 'integer', default => '0', not_null => 1 },
52     greeting       => { type => 'text' },
53     ustid          => { type => 'text' },
54     direct_debit   => { type => 'boolean', default => 'false' },
55     iban           => { type => 'varchar', length => 100 },
56     bic            => { type => 'varchar', length => 100 },
57     curr           => { type => 'character', length => 3 },
58   ],
59
60   primary_key_columns => [ 'id' ],
61
62   foreign_keys => [
63     business => {
64       class       => 'SL::DB::Business',
65       key_columns => { business_id => 'id' },
66     },
67
68     language_obj => {
69       class       => 'SL::DB::Language',
70       key_columns => { language_id => 'id' },
71     },
72
73     payment => {
74       class       => 'SL::DB::PaymentTerm',
75       key_columns => { payment_id => 'id' },
76     },
77   ],
78 );
79
80 1;
81 ;