Merge branch 'b-3.6.1' of ../kivitendo-erp_20220811
[kivitendo-erp.git] / SL / DB / MetaSetup / DeliveryOrderItem.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::DeliveryOrderItem;
4
5 use strict;
6
7 use parent qw(SL::DB::Object);
8
9 __PACKAGE__->meta->table('delivery_order_items');
10
11 __PACKAGE__->meta->columns(
12   active_discount_source => { type => 'text', default => '', not_null => 1 },
13   active_price_source    => { type => 'text', default => '', not_null => 1 },
14   base_qty               => { type => 'float', precision => 4, scale => 4 },
15   cusordnumber           => { type => 'text' },
16   delivery_order_id      => { type => 'integer', not_null => 1 },
17   description            => { type => 'text' },
18   discount               => { type => 'float', precision => 4, scale => 4 },
19   id                     => { type => 'integer', not_null => 1, sequence => 'delivery_order_items_id' },
20   itime                  => { type => 'timestamp', default => 'now()' },
21   lastcost               => { type => 'numeric', precision => 15, scale => 5 },
22   longdescription        => { type => 'text' },
23   marge_price_factor     => { type => 'numeric', default => 1, precision => 15, scale => 5 },
24   mtime                  => { type => 'timestamp' },
25   ordnumber              => { type => 'text' },
26   parts_id               => { type => 'integer', not_null => 1 },
27   position               => { type => 'integer', not_null => 1 },
28   price_factor           => { type => 'numeric', default => 1, precision => 15, scale => 5 },
29   price_factor_id        => { type => 'integer' },
30   pricegroup_id          => { type => 'integer' },
31   project_id             => { type => 'integer' },
32   qty                    => { type => 'numeric', precision => 25, scale => 5 },
33   reqdate                => { type => 'date' },
34   sellprice              => { type => 'numeric', precision => 15, scale => 5 },
35   serialnumber           => { type => 'text' },
36   transdate              => { type => 'text' },
37   unit                   => { type => 'varchar', length => 20 },
38 );
39
40 __PACKAGE__->meta->primary_key_columns([ 'id' ]);
41
42 __PACKAGE__->meta->allow_inline_column_values(1);
43
44 __PACKAGE__->meta->foreign_keys(
45   delivery_order => {
46     class       => 'SL::DB::DeliveryOrder',
47     key_columns => { delivery_order_id => 'id' },
48   },
49
50   part => {
51     class       => 'SL::DB::Part',
52     key_columns => { parts_id => 'id' },
53   },
54
55   price_factor_obj => {
56     class       => 'SL::DB::PriceFactor',
57     key_columns => { price_factor_id => 'id' },
58   },
59
60   pricegroup => {
61     class       => 'SL::DB::Pricegroup',
62     key_columns => { pricegroup_id => 'id' },
63   },
64
65   project => {
66     class       => 'SL::DB::Project',
67     key_columns => { project_id => 'id' },
68   },
69
70   unit_obj => {
71     class       => 'SL::DB::Unit',
72     key_columns => { unit => 'name' },
73   },
74 );
75
76 1;
77 ;