Bug 5087: Ability to define whether CSV profile shows in OPAC
[koha.git] / Koha / Schema / Result / ExportFormat.pm
blob1816f0d2eaefdcb2378b396589127c0e9f74cc28
1 use utf8;
2 package Koha::Schema::Result::ExportFormat;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
7 =head1 NAME
9 Koha::Schema::Result::ExportFormat - Used for CSV export
11 =cut
13 use strict;
14 use warnings;
16 use base 'DBIx::Class::Core';
18 =head1 TABLE: C<export_format>
20 =cut
22 __PACKAGE__->table("export_format");
24 =head1 ACCESSORS
26 =head2 export_format_id
28 data_type: 'integer'
29 is_auto_increment: 1
30 is_nullable: 0
32 =head2 profile
34 data_type: 'varchar'
35 is_nullable: 0
36 size: 255
38 =head2 description
40 data_type: 'longtext'
41 is_nullable: 0
43 =head2 content
45 data_type: 'longtext'
46 is_nullable: 0
48 =head2 csv_separator
50 data_type: 'varchar'
51 default_value: ','
52 is_nullable: 0
53 size: 2
55 =head2 field_separator
57 data_type: 'varchar'
58 is_nullable: 1
59 size: 2
61 =head2 subfield_separator
63 data_type: 'varchar'
64 is_nullable: 1
65 size: 2
67 =head2 encoding
69 data_type: 'varchar'
70 default_value: 'utf8'
71 is_nullable: 0
72 size: 255
74 =head2 type
76 data_type: 'varchar'
77 default_value: 'marc'
78 is_nullable: 1
79 size: 255
81 =head2 used_for
83 data_type: 'varchar'
84 default_value: 'export_records'
85 is_nullable: 1
86 size: 255
88 =head2 opac_option
90 data_type: 'tinyint'
91 default_value: 0
92 is_nullable: 0
94 =cut
96 __PACKAGE__->add_columns(
97 "export_format_id",
98 { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
99 "profile",
100 { data_type => "varchar", is_nullable => 0, size => 255 },
101 "description",
102 { data_type => "longtext", is_nullable => 0 },
103 "content",
104 { data_type => "longtext", is_nullable => 0 },
105 "csv_separator",
106 { data_type => "varchar", default_value => ",", is_nullable => 0, size => 2 },
107 "field_separator",
108 { data_type => "varchar", is_nullable => 1, size => 2 },
109 "subfield_separator",
110 { data_type => "varchar", is_nullable => 1, size => 2 },
111 "encoding",
113 data_type => "varchar",
114 default_value => "utf8",
115 is_nullable => 0,
116 size => 255,
118 "type",
120 data_type => "varchar",
121 default_value => "marc",
122 is_nullable => 1,
123 size => 255,
125 "used_for",
127 data_type => "varchar",
128 default_value => "export_records",
129 is_nullable => 1,
130 size => 255,
132 "opac_option",
133 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
136 =head1 PRIMARY KEY
138 =over 4
140 =item * L</export_format_id>
142 =back
144 =cut
146 __PACKAGE__->set_primary_key("export_format_id");
149 # Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-04-20 20:08:25
150 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:J2VDj9yI8uanFR9EGv2sXw
152 sub koha_object_class {
153 'Koha::CsvProfile';
155 sub koha_objects_class {
156 'Koha::CsvProfiles';
159 __PACKAGE__->add_columns(
160 '+opac_option' => { is_boolean => 1 },