Bugzilla – Attachment 115552 Details for
Bug 26436
Quick add patron will not copy over details from cities and towns pull down into patron details
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 26436: fix city/town pulldown
Bug-26436-fix-citytown-pulldown.patch (text/plain), 2.14 KB, created by
PTFS Europe Sandboxes
on 2021-01-21 14:42:41 UTC
(
hide
)
Description:
Bug 26436: fix city/town pulldown
Filename:
MIME Type:
Creator:
PTFS Europe Sandboxes
Created:
2021-01-21 14:42:41 UTC
Size:
2.14 KB
patch
obsolete
>From c4751f04ecaf6143ae4be8fe2f4867ed1a3d3fa7 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Thu, 21 Jan 2021 04:05:51 +0000 >Subject: [PATCH] Bug 26436: fix city/town pulldown > >This patch uses a different selector to target the inputs. > >1. add some cities to /cgi-bin/koha/admin/cities.pl with city, state, zipcode, and country defined >2. On PatronQuickAddFields select all, this way we can test all the alternate city selects >3. Go to quick add patron, and select a city from the dropdown, the city/state/zip/country doesn't populate (Alternate address city doesnt work either) >4. Apply patch >5. Do 1 - 3 again, it should work >6. Try the regular patron form, make sure all city/town dropdowns still work > >Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> >--- > koha-tmpl/intranet-tmpl/prog/js/members.js | 9 ++++----- > 1 file changed, 4 insertions(+), 5 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/members.js b/koha-tmpl/intranet-tmpl/prog/js/members.js >index f38870cc48..cd3c08bf9c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/members.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/members.js >@@ -203,16 +203,15 @@ $(document).ready(function(){ > e.preventDefault(); > $(this).parents('fieldset').first().remove(); > }); >- > $(document.body).on('change','.select_city',function(){ > var selected_city = $(this).val(); > var addressfield = $(this).data("addressfield"); > var myRegEx=new RegExp(/(.*)\|(.*)\|(.*)\|(.*)/); > var matches = selected_city.match( myRegEx ); >- $("#" + addressfield + "zipcode").val( matches[1] ); >- $("#" + addressfield + "city").val( matches[2] ); >- $("#" + addressfield + "state").val( matches[3] ); >- $("#" + addressfield + "country").val( matches[4] ); >+ $('input[name="' + addressfield + "zipcode").val( matches[1] ); >+ $('input[name="' + addressfield + "city").val( matches[2] ); >+ $('input[name="' + addressfield + "state").val( matches[3] ); >+ $('input[name="' + addressfield + "country").val( matches[4] ); > }); > > dateformat = $("#dateofbirth").siblings(".hint").first().html(); >-- >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 26436
:
115500
|
115552
|
116852