Bugzilla – Attachment 190793 Details for
Bug 38207
Add vendor payment methods
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 38207: Add a new payment_method column to aqbooksellers
Bug-38207-Add-a-new-paymentmethod-column-to-aqbook.patch (text/plain), 2.99 KB, created by
Andrew Fuerste-Henry
on 2025-12-31 15:30:31 UTC
(
hide
)
Description:
Bug 38207: Add a new payment_method column to aqbooksellers
Filename:
MIME Type:
Creator:
Andrew Fuerste-Henry
Created:
2025-12-31 15:30:31 UTC
Size:
2.99 KB
patch
obsolete
>From 408a4c142e3d09b52c84f3fde29a218b431d3af6 Mon Sep 17 00:00:00 2001 >From: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com> >Date: Fri, 18 Oct 2024 14:48:34 +0000 >Subject: [PATCH] Bug 38207: Add a new payment_method column to aqbooksellers > >(cherry picked from commit 881f96172a8c1b35d3e74f7f0f6aa44629578021) >Signed-off-by: David Nind <david@davidnind.com> >--- > .../bug_38207-add-vendor-payment-method.pl | 41 +++++++++++++++++++ > installer/data/mysql/kohastructure.sql | 1 + > 2 files changed, 42 insertions(+) > create mode 100644 installer/data/mysql/atomicupdate/bug_38207-add-vendor-payment-method.pl > >diff --git a/installer/data/mysql/atomicupdate/bug_38207-add-vendor-payment-method.pl b/installer/data/mysql/atomicupdate/bug_38207-add-vendor-payment-method.pl >new file mode 100644 >index 00000000000..13adc1bb811 >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_38207-add-vendor-payment-method.pl >@@ -0,0 +1,41 @@ >+use Modern::Perl; >+use Koha::Installer::Output qw(say_warning say_failure say_success say_info); >+ >+return { >+ bug_number => "38207", >+ description => "Add a payment method to the vendor table", >+ up => sub { >+ my ($args) = @_; >+ my ( $dbh, $out ) = @$args{qw(dbh out)}; >+ >+ unless ( column_exists( 'aqbooksellers', 'payment_method' ) ) { >+ $dbh->do( >+ q{ >+ ALTER TABLE aqbooksellers >+ ADD COLUMN `payment_method` varchar(255) NULL DEFAULT NULL >+ COMMENT 'the payment method for the vendor' >+ AFTER external_id >+ } >+ ); >+ >+ say $out "Added new column 'aqbooksellers.payment_method'"; >+ } >+ >+ $dbh->do( >+ q{ >+ INSERT IGNORE INTO authorised_value_categories( category_name, is_system ) VALUES ('VENDOR_PAYMENT_METHOD', 1); >+ } >+ ); >+ say $out "Added VENDOR_PAYMENT_METHOD authorised value category"; >+ >+ $dbh->do( >+ q{ >+ INSERT IGNORE INTO authorised_values (category, authorised_value, lib) >+ VALUES >+ ('VENDOR_PAYMENT_METHOD', 'card', 'Card'), >+ ('VENDOR_PAYMENT_METHOD', 'bacs', 'BACS'); >+ } >+ ); >+ say $out "Added Card and BACS to VENDOR_PAYMENT_METHODS authorised value category"; >+ }, >+}; >diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql >index e65b2af7ca4..63902a803b0 100644 >--- a/installer/data/mysql/kohastructure.sql >+++ b/installer/data/mysql/kohastructure.sql >@@ -504,6 +504,7 @@ CREATE TABLE `aqbooksellers` ( > `fax` varchar(50) DEFAULT NULL COMMENT 'vendor fax number', > `deliverytime` int(11) DEFAULT NULL COMMENT 'vendor delivery time', > `external_id` varchar(255) DEFAULT NULL COMMENT 'external id of the vendor', >+ `payment_method` varchar(255) DEFAULT NULL COMMENT 'the payment method for the vendor', > PRIMARY KEY (`id`), > KEY `listprice` (`listprice`), > KEY `invoiceprice` (`invoiceprice`), >-- >2.39.5
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 38207
:
175140
|
175141
|
175142
|
175143
|
182584
|
182585
|
182586
|
182587
|
183017
|
183018
|
183019
|
183020
|
188405
|
188406
|
188407
|
188408
| 190793 |
190794
|
190795
|
190796
|
190797