RDBO Support.
[kivitendo-erp.git] / SL / DB / MetaSetup / Invoice.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::Invoice;
4
5 use strict;
6
7 use base qw(SL::DB::Object);
8
9 __PACKAGE__->meta->setup(
10   table   => 'ar',
11
12   columns => [
13     id                      => { type => 'integer', not_null => 1, sequence => 'glid' },
14     invnumber               => { type => 'text', not_null => 1 },
15     transdate               => { type => 'date', default => 'now' },
16     gldate                  => { type => 'date', default => 'now' },
17     customer_id             => { type => 'integer' },
18     taxincluded             => { type => 'boolean' },
19     amount                  => { type => 'numeric', precision => 5, scale => 15 },
20     netamount               => { type => 'numeric', precision => 5, scale => 15 },
21     paid                    => { type => 'numeric', precision => 5, scale => 15 },
22     datepaid                => { type => 'date' },
23     duedate                 => { type => 'date' },
24     deliverydate            => { type => 'date' },
25     invoice                 => { type => 'boolean', default => 'false' },
26     shippingpoint           => { type => 'text' },
27     terms                   => { type => 'integer', default => '0' },
28     notes                   => { type => 'text' },
29     curr                    => { type => 'character', length => 3 },
30     ordnumber               => { type => 'text' },
31     employee_id             => { type => 'integer' },
32     quonumber               => { type => 'text' },
33     cusordnumber            => { type => 'text' },
34     intnotes                => { type => 'text' },
35     department_id           => { type => 'integer', default => '0' },
36     shipvia                 => { type => 'text' },
37     itime                   => { type => 'timestamp', default => 'now()' },
38     mtime                   => { type => 'timestamp' },
39     cp_id                   => { type => 'integer' },
40     language_id             => { type => 'integer' },
41     payment_id              => { type => 'integer' },
42     delivery_customer_id    => { type => 'integer' },
43     delivery_vendor_id      => { type => 'integer' },
44     storno                  => { type => 'boolean', default => 'false' },
45     taxzone_id              => { type => 'integer' },
46     shipto_id               => { type => 'integer' },
47     type                    => { type => 'text' },
48     dunning_config_id       => { type => 'integer' },
49     orddate                 => { type => 'date' },
50     quodate                 => { type => 'date' },
51     globalproject_id        => { type => 'integer' },
52     salesman_id             => { type => 'integer' },
53     transaction_description => { type => 'text' },
54     storno_id               => { type => 'integer' },
55     marge_total             => { type => 'numeric', precision => 5, scale => 15 },
56     marge_percent           => { type => 'numeric', precision => 5, scale => 15 },
57     notes_bottom            => { type => 'text' },
58     donumber                => { type => 'text' },
59   ],
60
61   primary_key_columns => [ 'id' ],
62
63   allow_inline_column_values => 1,
64
65   foreign_keys => [
66     customer => {
67       class       => 'SL::DB::Customer',
68       key_columns => { customer_id => 'id' },
69     },
70
71     globalproject => {
72       class       => 'SL::DB::Project',
73       key_columns => { globalproject_id => 'id' },
74     },
75
76     storno_obj => {
77       class       => 'SL::DB::Invoice',
78       key_columns => { storno_id => 'id' },
79     },
80   ],
81 );
82
83 1;
84 ;