Bugzilla – Attachment 15920 Details for
Bug 8956
Split serials enumeration data into separate fields
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 8956 - Split serials enumeration data into separate fields - Part 7 - Add backend processing of field labels.
Bug-8956---Split-serials-enumeration-data-into-sep.patch (text/plain), 8.62 KB, created by
Kyle M Hall (khall)
on 2013-03-06 18:45:52 UTC
(
hide
)
Description:
Bug 8956 - Split serials enumeration data into separate fields - Part 7 - Add backend processing of field labels.
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2013-03-06 18:45:52 UTC
Size:
8.62 KB
patch
obsolete
>From 7e68e0b8fec78ecb0ba6e942388eb6ea478f9385 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Wed, 24 Oct 2012 12:02:37 -0400 >Subject: [PATCH] Bug 8956 - Split serials enumeration data into separate fields - Part 7 - Add backend processing of field labels. > >--- > C4/Serials.pm | 29 ++++++++++++++++++++--------- > serials/subscription-add.pl | 14 ++++++++++++-- > 2 files changed, 32 insertions(+), 11 deletions(-) > >diff --git a/C4/Serials.pm b/C4/Serials.pm >index 1394a86..c0eed92 100644 >--- a/C4/Serials.pm >+++ b/C4/Serials.pm >@@ -960,6 +960,13 @@ sub GetNextSeq { > $newlastvalue3 = $val->{setto3} if ( $newlastvalue3 > $val->{whenmorethan3} ); # reset counter if needed. > $calculated =~ s/\{Z\}/$newlastvalue3/g; > >+ my $x_label = $val->{'serialseq_x_label'}; >+ my $y_label = $val->{'serialseq_y_label'}; >+ my $z_label = $val->{'serialseq_z_label'}; >+ $calculated =~ s/\{XL\}/$x_label/g; >+ $calculated =~ s/\{YL\}/$y_label/g; >+ $calculated =~ s/\{ZL\}/$z_label/g; >+ > return ( $calculated, $newlastvalue1, $newlastvalue2, $newlastvalue3, $newinnerloop1, $newinnerloop2, $newinnerloop3 ); > } > >@@ -1263,7 +1270,8 @@ sub ModSubscription { > $whenmorethan1, $setto1, $lastvalue1, $innerloop1, $add2, $every2, $whenmorethan2, $setto2, > $lastvalue2, $innerloop2, $add3, $every3, $whenmorethan3, $setto3, $lastvalue3, $innerloop3, > $numberingmethod, $status, $biblionumber, $callnumber, $notes, $letter, $hemisphere, $manualhistory, >- $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate, $subscriptionid >+ $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate, $subscriptionid, >+ $x_label, $y_label, $z_label > ) = @_; > > # warn $irregularity; >@@ -1275,9 +1283,9 @@ sub ModSubscription { > add2=?,every2=?,whenmorethan2=?,setto2=?,lastvalue2=?,innerloop2=?, > add3=?,every3=?,whenmorethan3=?,setto3=?,lastvalue3=?,innerloop3=?, > numberingmethod=?, status=?, biblionumber=?, callnumber=?, notes=?, >- letter=?, hemisphere=?,manualhistory=?,internalnotes=?,serialsadditems=?, >- staffdisplaycount = ?,opacdisplaycount = ?, graceperiod = ?, location = ? >- ,enddate=? >+ letter=?, hemisphere=?,manualhistory=?,internalnotes=?,serialsadditems=?, >+ staffdisplaycount = ?,opacdisplaycount = ?, graceperiod = ?, location = ?, >+ enddate=?, serialseq_x_label=?, serialseq_y_label=?, serialseq_z_label=? > WHERE subscriptionid = ?"; > > #warn "query :".$query; >@@ -1294,7 +1302,8 @@ sub ModSubscription { > $numberingmethod, $status, $biblionumber, $callnumber, > $notes, $letter, $hemisphere, ( $manualhistory ? $manualhistory : 0 ), > $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount, >- $graceperiod, $location, $enddate, $subscriptionid >+ $graceperiod, $location, $enddate, $subscriptionid, >+ $x_label, $y_label, $z_label > ); > my $rows = $sth->rows; > >@@ -1325,7 +1334,8 @@ sub NewSubscription { > $lastvalue1, $innerloop1, $add2, $every2, $whenmorethan2, $setto2, $lastvalue2, $innerloop2, > $add3, $every3, $whenmorethan3, $setto3, $lastvalue3, $innerloop3, $numberingmethod, $status, > $notes, $letter, $firstacquidate, $irregularity, $numberpattern, $callnumber, $hemisphere, $manualhistory, >- $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate >+ $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate, $x_label, >+ $y_label, $z_label > ) = @_; > my $dbh = C4::Context->dbh; > >@@ -1339,8 +1349,8 @@ sub NewSubscription { > add3,every3,whenmorethan3,setto3,lastvalue3,innerloop3, > numberingmethod, status, notes, letter,firstacquidate,irregularity, > numberpattern, callnumber, hemisphere,manualhistory,internalnotes,serialsadditems, >- staffdisplaycount,opacdisplaycount,graceperiod,location,enddate) >- VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) >+ staffdisplaycount,opacdisplaycount,graceperiod,location,enddate,serialseq_x_label,serialseq_y_label,serialseq_z_label) >+ VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) > |; > my $sth = $dbh->prepare($query); > $sth->execute( >@@ -1349,7 +1359,8 @@ sub NewSubscription { > $lastvalue1, $innerloop1, $add2, $every2, $whenmorethan2, $setto2, $lastvalue2, $innerloop2, > $add3, $every3, $whenmorethan3, $setto3, $lastvalue3, $innerloop3, $numberingmethod, "$status", > $notes, $letter, $firstacquidate, $irregularity, $numberpattern, $callnumber, $hemisphere, $manualhistory, >- $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate >+ $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate, $x_label, >+ $y_label, $z_label > ); > > my $subscriptionid = $dbh->{'mysql_insertid'}; >diff --git a/serials/subscription-add.pl b/serials/subscription-add.pl >index 82a7fd6..2b64ab3 100755 >--- a/serials/subscription-add.pl >+++ b/serials/subscription-add.pl >@@ -251,6 +251,9 @@ sub redirect_add_subscription { > my $missinglist = $query->param('missinglist'); > my $opacnote = $query->param('opacnote'); > my $librariannote = $query->param('librariannote'); >+ my $x_label = $query->param('x_label'); >+ my $y_label = $query->param('y_label'); >+ my $z_label = $query->param('z_label'); > my $subscriptionid = NewSubscription( > $auser, $branchcode, $aqbooksellerid, $cost, > $aqbudgetid, $biblionumber, $startdate, $periodicity, >@@ -263,7 +266,8 @@ sub redirect_add_subscription { > $notes, $letter, $firstacquidate, join( ",", @irregularity ), > $numberpattern, $callnumber, $hemisphere, ( $manualhistory ? $manualhistory : 0 ), > $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount, >- $graceperiod, $location, $enddate >+ $graceperiod, $location, $enddate, $x_label, >+ $y_label, $z_label > ); > ModSubscriptionHistory( $subscriptionid, $histstartdate, $histenddate, $recievedlist, $missinglist, $opacnote, $librariannote ); > >@@ -333,6 +337,11 @@ sub redirect_mod_subscription { > my $location = $query->param('location'); > my $nextexpected = GetNextExpected($subscriptionid); > >+ # field labels >+ my $x_label = $query->param('x_label'); >+ my $y_label = $query->param('y_label'); >+ my $z_label = $query->param('z_label'); >+ > # If it's a mod, we need to check the current 'expected' issue, and mod it in the serials table if necessary. > if ( $nextacquidate ne $nextexpected->{planneddate}->output('iso') ) { > ModNextExpected( $subscriptionid, C4::Dates->new( $nextacquidate, 'iso' ) ); >@@ -349,7 +358,8 @@ sub redirect_mod_subscription { > $lastvalue2, $innerloop2, $add3, $every3, $whenmorethan3, $setto3, > $lastvalue3, $innerloop3, $numberingmethod, $status, $biblionumber, $callnumber, > $notes, $letter, $hemisphere, $manualhistory, $internalnotes, $serialsadditems, >- $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate, $subscriptionid >+ $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate, $subscriptionid, >+ $x_label, $y_label, $z_label > ); > ModSubscriptionHistory( $subscriptionid, $histstartdate, $histenddate, $recievedlist, $missinglist, $opacnote, $librariannote ); > print $query->redirect("/cgi-bin/koha/serials/subscription-detail.pl?subscriptionid=$subscriptionid"); >-- >1.7.2.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 8956
:
13041
|
13042
|
13043
|
13044
|
13045
|
13046
|
13047
|
15914
|
15915
|
15916
|
15917
|
15918
|
15919
|
15920
|
16346
|
16347
|
16348
|
16349
|
16350
|
16351
|
16352
|
16353
|
18554
|
18555
|
18556
|
18557
|
18558
|
18559
|
18560
|
18561
|
18568
|
18569
|
18570
|
18571
|
18572
|
18573
|
18574
|
18575
|
18576
|
18577
|
18578
|
18579
|
18580
|
18581
|
18582
|
18583
|
18679