2 package Koha::Schema::Result::AccountCreditType;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
9 Koha::Schema::Result::AccountCreditType
16 use base 'DBIx::Class::Core';
18 =head1 TABLE: C<account_credit_types>
22 __PACKAGE__->table("account_credit_types");
38 =head2 can_be_added_manually
44 =head2 credit_number_enabled
50 Is autogeneration of credit number enabled for this credit type
64 boolean flag to denote if this till is archived or not
68 __PACKAGE__->add_columns(
70 { data_type => "varchar", is_nullable => 0, size => 80 },
72 { data_type => "varchar", is_nullable => 1, size => 200 },
73 "can_be_added_manually",
74 { data_type => "tinyint", default_value => 1, is_nullable => 0 },
75 "credit_number_enabled",
76 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
78 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
80 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
93 __PACKAGE__->set_primary_key("code");
97 =head2 account_credit_types_branches
101 Related object: L<Koha::Schema::Result::AccountCreditTypesBranch>
105 __PACKAGE__->has_many(
106 "account_credit_types_branches",
107 "Koha::Schema::Result::AccountCreditTypesBranch",
108 { "foreign.credit_type_code" => "self.code" },
109 { cascade_copy => 0, cascade_delete => 0 },
116 Related object: L<Koha::Schema::Result::Accountline>
120 __PACKAGE__->has_many(
122 "Koha::Schema::Result::Accountline",
123 { "foreign.credit_type_code" => "self.code" },
124 { cascade_copy => 0, cascade_delete => 0 },
128 # Created by DBIx::Class::Schema::Loader v0.07049 @ 2021-01-21 13:39:29
129 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:pqgg1XzDq/zm/epjihLT8Q
131 __PACKAGE__->add_columns(
132 '+is_system' => { is_boolean => 1 },
133 '+credit_number_enabled' => { is_boolean => 1 },
134 '+archived' => { is_boolean => 1 }
137 sub koha_objects_class {
138 'Koha::Account::CreditTypes';
140 sub koha_object_class {
141 'Koha::Account::CreditType';