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

(-)a/installer/data/mysql/atomicupdate/bug_35724-add_upload_port_and_download_port_columns.pl (+30 lines)
Line 0 Link Here
1
use Modern::Perl;
2
3
return {
4
    bug_number  => "35724",
5
    description => "Add new fields to EDI accounts for librarians to configure non-standard EDI SFTP port numbers",
6
    up          => sub {
7
        my ($args) = @_;
8
        my ( $dbh, $out ) = @$args{qw(dbh out)};
9
10
        if ( !column_exists( 'vendor_edi_accounts', 'upload_port' ) ) {
11
            $dbh->do(
12
                q{
13
              ALTER TABLE vendor_edi_accounts ADD COLUMN `upload_port` varchar(40) DEFAULT '22' AFTER `password`
14
          }
15
            );
16
17
            say $out "Added column 'vendor_edi_accounts.upload_port'";
18
        }
19
20
        if ( !column_exists( 'vendor_edi_accounts', 'download_port' ) ) {
21
            $dbh->do(
22
                q{
23
              ALTER TABLE vendor_edi_accounts ADD COLUMN `download_port` varchar(40) DEFAULT '22' AFTER `password`
24
          }
25
            );
26
27
            say $out "Added column 'vendor_edi_accounts.download_port'";
28
        }
29
    },
30
};
(-)a/installer/data/mysql/kohastructure.sql (-1 / +2 lines)
Lines 6427-6432 CREATE TABLE `vendor_edi_accounts` ( Link Here
6427
  `host` varchar(40) DEFAULT NULL,
6427
  `host` varchar(40) DEFAULT NULL,
6428
  `username` varchar(40) DEFAULT NULL,
6428
  `username` varchar(40) DEFAULT NULL,
6429
  `password` mediumtext DEFAULT NULL,
6429
  `password` mediumtext DEFAULT NULL,
6430
  `upload_port` varchar(40) DEFAULT NULL,
6431
  `download_port` varchar(40) DEFAULT NULL,
6430
  `last_activity` date DEFAULT NULL,
6432
  `last_activity` date DEFAULT NULL,
6431
  `vendor_id` int(11) DEFAULT NULL,
6433
  `vendor_id` int(11) DEFAULT NULL,
6432
  `download_directory` mediumtext DEFAULT NULL,
6434
  `download_directory` mediumtext DEFAULT NULL,
6433
- 

Return to bug 35724