Bugzilla – Attachment 119451 Details for
Bug 28134
Replace use of input type number in onboarding templates
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28134: Replace use of input type number in onboarding templates
Bug-28134-Replace-use-of-input-type-number-in-onbo.patch (text/plain), 6.97 KB, created by
Owen Leonard
on 2021-04-12 11:35:35 UTC
(
hide
)
Description:
Bug 28134: Replace use of input type number in onboarding templates
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2021-04-12 11:35:35 UTC
Size:
6.97 KB
patch
obsolete
>From aba5acacc2d6b7cbba1babaf89d6927307c4b846 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Mon, 12 Apr 2021 10:49:45 +0000 >Subject: [PATCH] Bug 28134: Replace use of input type number in onboarding > templates > >This patch changes the instances of input of type="number" to input >type="text" with attributes inputmode="numeric" and pattern="[0-9]*" > >To test, apply the patch and run through the process of installing Koha. >When you reach onboarding step 2, "Create a patron category," check the >enrollment period -> "In months" field. The field should not accept any >input except numbers. > >Continue onboarding until step 5, "Create a new circulation rule." On >this page, check that these fields accept only numbers: > > - Current checkouts allowed > - Loan period > - Renewals allowed > - Renewals period > - Holds allowed (total) > - Holds allowed (daily) > - Holds per record (count) >--- > .../prog/en/modules/onboarding/onboardingstep2.tt | 4 ++-- > .../prog/en/modules/onboarding/onboardingstep5.tt | 14 +++++++------- > 2 files changed, 9 insertions(+), 9 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep2.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep2.tt >index b01da625cd..fc19563a7c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep2.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep2.tt >@@ -99,9 +99,9 @@ > <li> > <label for="enrolmentperiod">In months: </label> > [% IF category.enrolmentperiod %] >- <input type="number" class="enrolmentperiod" name="enrolmentperiod" id="enrolmentperiod" min="0" size="3" value="[% category.enrolmentperiod | html %]" /> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" class="enrolmentperiod" name="enrolmentperiod" id="enrolmentperiod" size="3" value="[% category.enrolmentperiod | html %]" /> > [% ELSE %] >- <input type="number" class="enrolmentperiod" name="enrolmentperiod" id="enrolmentperiod" min="0" size="3" value="" /> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" class="enrolmentperiod" name="enrolmentperiod" id="enrolmentperiod" size="3" value="" /> > [% END %] > </li> > <li> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt >index e70870f500..57320ae9eb 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt >@@ -69,13 +69,13 @@ > </li> > <li> > <label for="maxissueqty" class="required">Current checkouts allowed: </label> >- <input type="number" min="0" name="maxissueqty" id="maxissueqty" size="10" value="50" class="required" required="required" /> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" name="maxissueqty" id="maxissueqty" size="10" value="50" class="required" required="required" /> > <span class="required">Required</span> > </li> > > <li> > <label for="issuelength" class="required">Loan period: </label> >- <input type="number" min="0" name="issuelength" id="issuelength" size="10" value="14" class="required" required="required" /> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" name="issuelength" id="issuelength" size="10" value="14" class="required" required="required" /> > <span class="required">Required</span> > </li> > <li> >@@ -100,29 +100,29 @@ > </li> > <li> > <label for="renewalsallowed" class="required">Renewals allowed: </label> >- <input type="number" min="0" name="renewalsallowed" id="renewalsallowed" size="10" max="10" value="10" class="required" required="required" /> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" name="renewalsallowed" id="renewalsallowed" size="10" value="10" class="required" required="required" /> > <span class="required">Required</span> > </li> > > <li> > <label for="renewalperiod" class="required">Renewals period: </label> >- <input type="number" min="0" name="renewalperiod" id="renewalperiod" size="10" value="14" class="required" required="required" /> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" name="renewalperiod" id="renewalperiod" size="10" value="14" class="required" required="required" /> > <span class="required">Required</span> > </li> > > <li> > <label for="reservesallowed">Holds allowed (total): </label> >- <input type="number" name="reservesallowed" id="reservesallowed" size="10" value="10" min="0"> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" name="reservesallowed" id="reservesallowed" size="10" value="10" /> > </li> > > <li> > <label for="holds_per_day">Holds allowed (daily): </label> >- <input type="number" name="holds_per_day" id="holds_per_day" size="10" value="10" min="0"> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" name="holds_per_day" id="holds_per_day" size="10" value="10" /> > </li> > > <li> > <label for="holds_per_record">Holds per record (count): </label> >- <input type="number" name="holds_per_record" id="holds_per_record" size="10" value="1" min="0"> >+ <input type="text" inputmode="numeric" pattern="[0-9]*" name="holds_per_record" id="holds_per_record" size="10" value="1" /> > </li> > > <li> >-- >2.11.0
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 28134
:
119449
|
119451
|
120435