Bugzilla – Attachment 149479 Details for
Bug 33103
Add vendor aliases
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33103: DB changes
Bug-33103-DB-changes.patch (text/plain), 2.91 KB, created by
Katrin Fischer
on 2023-04-11 21:00:52 UTC
(
hide
)
Description:
Bug 33103: DB changes
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2023-04-11 21:00:52 UTC
Size:
2.91 KB
patch
obsolete
>From 49172331ca098283723a471f2d396d2e9f3094c4 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Wed, 1 Mar 2023 11:06:46 +0100 >Subject: [PATCH] Bug 33103: DB changes > >Signed-off-by: Jonathan Field <jonathan.field@ptfs-europe.com> >--- > .../data/mysql/atomicupdate/bug_33103.pl | 22 +++++++++++++++++++ > installer/data/mysql/kohastructure.sql | 16 ++++++++++++++ > 2 files changed, 38 insertions(+) > create mode 100755 installer/data/mysql/atomicupdate/bug_33103.pl > >diff --git a/installer/data/mysql/atomicupdate/bug_33103.pl b/installer/data/mysql/atomicupdate/bug_33103.pl >new file mode 100755 >index 0000000000..cd06f7835b >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_33103.pl >@@ -0,0 +1,22 @@ >+use Modern::Perl; >+ >+return { >+ bug_number => "33103", >+ description => "Add vendor aliases", >+ up => sub { >+ my ($args) = @_; >+ my ($dbh, $out) = @$args{qw(dbh out)}; >+ unless ( TableExists('aqbookseller_aliases') ) { >+ $dbh->do(q{ >+ CREATE TABLE `aqbookseller_aliases` ( >+ `id` int(11) NOT NULL AUTO_INCREMENT COMMENT 'primary key and unique identifier assigned by Koha', >+ `vendor_id` int(11) NOT NULL COMMENT 'link to the vendor', >+ `alias` varchar(255) NOT NULL COMMENT "the alias", >+ PRIMARY KEY (`id`), >+ CONSTRAINT `aqbookseller_aliases_ibfk_1` FOREIGN KEY (`vendor_id`) REFERENCES `aqbooksellers` (`id`) ON DELETE CASCADE ON UPDATE CASCADE >+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; >+ }); >+ say $out "Added new table 'aqbookseller_aliases'"; >+ } >+ }, >+}; >diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql >index cba889d5e0..4651cf9de5 100644 >--- a/installer/data/mysql/kohastructure.sql >+++ b/installer/data/mysql/kohastructure.sql >@@ -424,6 +424,22 @@ CREATE TABLE `aqbooksellers` ( > ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; > /*!40101 SET character_set_client = @saved_cs_client */; > >+-- >+-- Table structure for table `aqbookseller_aliases` >+-- >+ >+DROP TABLE IF EXISTS `aqbookseller_aliases`; >+/*!40101 SET @saved_cs_client = @@character_set_client */; >+/*!40101 SET character_set_client = utf8 */; >+CREATE TABLE `aqbookseller_aliases` ( >+ `id` int(11) NOT NULL AUTO_INCREMENT COMMENT 'primary key and unique identifier assigned by Koha', >+ `vendor_id` int(11) NOT NULL COMMENT 'link to the vendor', >+ `alias` varchar(255) NOT NULL COMMENT "the alias", >+ PRIMARY KEY (`id`), >+ CONSTRAINT `aqbookseller_aliases_ibfk_1` FOREIGN KEY (`vendor_id`) REFERENCES `aqbooksellers` (`id`) ON DELETE CASCADE ON UPDATE CASCADE >+) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; >+/*!40101 SET character_set_client = @saved_cs_client */; >+ > -- > -- Table structure for table `aqbudgetborrowers` > -- >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 33103
:
147621
|
147622
|
147623
|
147624
|
147625
|
147626
|
147627
|
147628
|
147629
|
147630
|
147645
|
147646
|
147647
|
147648
|
147649
|
147650
|
147651
|
147652
|
147653
|
147654
|
147827
|
148448
|
148449
|
148450
|
148451
|
148452
|
148453
|
148454
|
148455
|
148456
|
148457
|
148458
|
149414
|
149419
| 149479 |
149480
|
149481
|
149482
|
149483
|
149484
|
149485
|
149486
|
149487
|
149488
|
149489
|
149490
|
149491
|
149606
|
149607
|
149608
|
149609
|
149629
|
149630
|
149788