View | Details | Raw Unified | Return to bug 20144
Collapse All | Expand All

(-)a/installer/data/mysql/atomicupdate/bug_xxxxx_export_format_default.sql (+3 lines)
Line 0 Link Here
1
ALTER TABLE export_format MODIFY csv_separator VARCHAR(2) NOT NULL DEFAULT ',', MODIFY field_separator VARCHAR(2), MODIFY subfield_separator VARCHAR(2);
2
ALTER TABLE export_format MODIFY encoding VARCHAR(255) DEFAULT 'utf8';
3
(-)a/installer/data/mysql/kohastructure.sql (-4 / +4 lines)
Lines 717-726 CREATE TABLE `export_format` ( Link Here
717
  `profile` varchar(255) NOT NULL,
717
  `profile` varchar(255) NOT NULL,
718
  `description` mediumtext NOT NULL,
718
  `description` mediumtext NOT NULL,
719
  `content` mediumtext NOT NULL,
719
  `content` mediumtext NOT NULL,
720
  `csv_separator` varchar(2) NOT NULL,
720
  `csv_separator` varchar(2) NOT NULL DEFAULT ',',
721
  `field_separator` varchar(2) NOT NULL,
721
  `field_separator` varchar(2),
722
  `subfield_separator` varchar(2) NOT NULL,
722
  `subfield_separator` varchar(2),
723
  `encoding` varchar(255) NOT NULL,
723
  `encoding` varchar(255) NOT NULL DEFAULT 'utf8',
724
  `type` varchar(255) DEFAULT 'marc',
724
  `type` varchar(255) DEFAULT 'marc',
725
  `used_for` varchar(255) DEFAULT 'export_records',
725
  `used_for` varchar(255) DEFAULT 'export_records',
726
  PRIMARY KEY  (`export_format_id`)
726
  PRIMARY KEY  (`export_format_id`)
(-)a/t/db_dependent/Koha/CsvProfiles.t (-3 / +4 lines)
Lines 36-47 my $new_csv_profile_1 = Koha::CsvProfile->new({ Link Here
36
    profile => 'my_csv_profile_name_for_test_1',
36
    profile => 'my_csv_profile_name_for_test_1',
37
    description => 'my_csv_profile_description_for_test_1',
37
    description => 'my_csv_profile_description_for_test_1',
38
    type => 'sql',
38
    type => 'sql',
39
    used_for => 'late_issues'
39
    used_for => 'late_issues',
40
    content => 'a content',
40
})->store;
41
})->store;
41
my $new_csv_profile_2 = Koha::CsvProfile->new({
42
my $new_csv_profile_2 = Koha::CsvProfile->new({
42
    profile => 'my_csv_profile_name_for_test_2',
43
    profile => 'my_csv_profile_name_for_test_2',
43
    description => 'my_csv_profile_description_for_test_2',
44
    description => 'my_csv_profile_description_for_test_2',
44
    type => 'marc'
45
    type => 'marc',
46
    content => 'another content',
45
})->store;
47
})->store;
46
48
47
like( $new_csv_profile_1->export_format_id, qr|^\d+$|, 'Adding a new csv_profile should have set the export_format_id');
49
like( $new_csv_profile_1->export_format_id, qr|^\d+$|, 'Adding a new csv_profile should have set the export_format_id');
48
- 

Return to bug 20144