Bugzilla – Attachment 58545 Details for
Bug 6782
Move auto member cardnumber generation to occur when record is "Saved" (avoid collisions)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 6782 [QA Followup] - Remove unused param and limit calls to Koha.Preference
Bug-6782-QA-Followup---Remove-unused-param-and-lim.patch (text/plain), 4.44 KB, created by
Kyle M Hall (khall)
on 2016-12-30 18:43:07 UTC
(
hide
)
Description:
Bug 6782 [QA Followup] - Remove unused param and limit calls to Koha.Preference
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2016-12-30 18:43:07 UTC
Size:
4.44 KB
patch
obsolete
>From 78d3df06a1bbec970933d5d82d5aa6cea6e4da21 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Fri, 30 Dec 2016 18:42:37 +0000 >Subject: [PATCH] Bug 6782 [QA Followup] - Remove unused param and limit calls > to Koha.Preference > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > .../intranet-tmpl/prog/en/modules/members/memberentrygen.tt | 13 +++++++------ > members/memberentry.pl | 6 ------ > 2 files changed, 7 insertions(+), 12 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >index 54fd902..4a046e6 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >@@ -596,35 +596,36 @@ $(document).ready(function() { > [% END %] > [% IF ( step_3 ) %] > >+ [% SET autoMemberNum = Koha.Preference('autoMemberNum') %] > <fieldset class="rows" id="memberentry_library_management"> > <legend id="library_management_lgd">Library management</legend><ol> > [% UNLESS nocardnumber %] > <li> >- [% IF mandatorycardnumber and not Koha.Preference('autoMemberNum') %] >+ [% IF mandatorycardnumber and not autoMemberNum %] > <label for="cardnumber" class="required"> > [% ELSE %] > <label for="cardnumber" class="validated"> > [% END %] >- [% IF Koha.Preference('autoMemberNum') %] >+ [% IF autoMemberNum %] > Card number<br>(<u>leave blank for auto calc during registration</u>): </label> > [% ELSE %] > Card number: </label> > [% END %] > [% IF minlength_cardnumber == maxlength_cardnumber %] > <input type="text" id="cardnumber" name="cardnumber" size="20" value="[% cardnumber | html %]" minlength="[% minlength_cardnumber %]" maxlength="[% maxlength_cardnumber %]" /> >- [% IF mandatorycardnumber and not Koha.Preference('autoMemberNum') %]<span class="required">Required</span>[% END %] >+ [% IF mandatorycardnumber and not autoMemberNum %]<span class="required">Required</span>[% END %] > <div class="hint">Card number must be exactly [% minlength_cardnumber %] characters.</div> > [% ELSIF minlength_cardnumber && maxlength_cardnumber %] > <input type="text" id="cardnumber" name="cardnumber" size="20" value="[% cardnumber | html %]" minlength="[% minlength_cardnumber %]" maxlength="[% maxlength_cardnumber %]" /> >- [% IF mandatorycardnumber and not Koha.Preference('autoMemberNum') %]<span class="required">Required</span>[% END %] >+ [% IF mandatorycardnumber and not autoMemberNum %]<span class="required">Required</span>[% END %] > <div class="hint">Card number must be between [% minlength_cardnumber %] and [% maxlength_cardnumber %] characters.</div> > [% ELSIF maxlength_cardnumber %] > <input type="text" id="cardnumber" name="cardnumber" size="20" value="[% cardnumber | html %]" maxlength="[% maxlength_cardnumber %]" /> >- [% IF mandatorycardnumber and not Koha.Preference('autoMemberNum') %]<span class="required">Required</span>[% END %] >+ [% IF mandatorycardnumber and not autoMemberNum %]<span class="required">Required</span>[% END %] > <div class="hint">Card number can be up to [% maxlength_cardnumber %] characters.</div> > [% ELSE %] > <input type="text" id="cardnumber" name="cardnumber" size="20" value="[% cardnumber | html %]" /> >- [% IF mandatorycardnumber and not Koha.Preference('autoMemberNum') %]<span class="required">Required</span>[% END %] >+ [% IF mandatorycardnumber and not autoMemberNum %]<span class="required">Required</span>[% END %] > <div class="hint">There is no minimum or maximum character length.</div> > [% END %] > </li> >diff --git a/members/memberentry.pl b/members/memberentry.pl >index 9213d59..ef0aa90 100755 >--- a/members/memberentry.pl >+++ b/members/memberentry.pl >@@ -561,12 +561,6 @@ if ( $op eq "duplicate" ) { > $data{'cardnumber'} = ""; > } > >-if (C4::Context->preference("autoMemberNum")) { >- $template->param( autoMemberNum => 1); >-} else { >- $template->param( autoMemberNum => 0); >-} >- > if(!defined($data{'sex'})){ > $template->param( none => 1); > } elsif($data{'sex'} eq 'F'){ >-- >2.1.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 6782
:
9945
|
10625
|
55952
|
55964
|
58173
|
58544
| 58545 |
59002