Bugzilla – Attachment 45675 Details for
Bug 11844
Additional fields for order lines
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11844: Copy additional fields values when transfering order
Bug-11844-Copy-additional-fields-values-when-trans.patch (text/plain), 1.25 KB, created by
Kyle M Hall (khall)
on 2015-12-14 17:11:18 UTC
(
hide
)
Description:
Bug 11844: Copy additional fields values when transfering order
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2015-12-14 17:11:18 UTC
Size:
1.25 KB
patch
obsolete
>From 51169f2d36ed27190e266c86090adeafa439b5c5 Mon Sep 17 00:00:00 2001 >From: Julian Maurice <julian.maurice@biblibre.com> >Date: Mon, 24 Aug 2015 15:30:15 +0200 >Subject: [PATCH] Bug 11844: Copy additional fields values when transfering > order > >--- > C4/Acquisition.pm | 9 +++++++++ > 1 file changed, 9 insertions(+) > >diff --git a/C4/Acquisition.pm b/C4/Acquisition.pm >index 4044556..5e2738b 100644 >--- a/C4/Acquisition.pm >+++ b/C4/Acquisition.pm >@@ -31,6 +31,7 @@ use Koha::DateUtils qw( dt_from_string output_pref ); > use Koha::Acquisition::Order; > use Koha::Acquisition::Bookseller; > use Koha::Number::Price; >+use Koha::AdditionalField; > > use C4::Koha qw( subfield_is_koha_internal_p ); > >@@ -1865,6 +1866,14 @@ sub TransferOrder { > $sth = $dbh->prepare($query); > $sth->execute($newordernumber, $ordernumber); > >+ # Copy additional fields values >+ my $additional_fields = Koha::AdditionalField->all({tablename => 'aqorders'}); >+ foreach my $af (@$additional_fields) { >+ $af->fetch_values({record_id => $ordernumber}); >+ $af->{values}->{$newordernumber} = $af->{values}->{$ordernumber}; >+ $af->insert_values; >+ } >+ > $query = q{ > INSERT INTO aqorders_transfers (ordernumber_from, ordernumber_to) > VALUES (?, ?) >-- >1.7.10.4
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 11844
:
25632
|
25638
|
41859
|
41860
|
45674
|
45675
|
45676
|
45758
|
45915
|
45916
|
45917
|
53614
|
53615
|
53616
|
53618
|
53619
|
55529
|
75332
|
75362
|
141116
|
145517
|
145535
|
145536
|
145540
|
146497
|
146500
|
146501
|
146502
|
146503
|
146504
|
146505
|
146506
|
148889
|
148895
|
148897
|
149081
|
149082
|
149083
|
149084
|
149085
|
149086
|
149087
|
149088
|
149089
|
149090
|
149091
|
149682
|
149683
|
149684
|
149685
|
149686
|
149687
|
149688
|
149689
|
149690
|
149691
|
149692
|
150537
|
150538
|
150539
|
150540
|
150541
|
150542
|
150543
|
150544
|
150545
|
150546
|
150547
|
150548
|
151220
|
151221
|
151222
|
151223
|
151224
|
151225
|
151226
|
151227
|
151228
|
151229
|
151230
|
151366