Summary: | Self-checkin module should provide for automatic logins (like self-checkout) | ||
---|---|---|---|
Product: | Koha | Reporter: | Oliver Behnke <oliver.behnke> |
Component: | Circulation | Assignee: | Emmi Takkinen <emmi.takkinen> |
Status: | ASSIGNED --- | QA Contact: | Testopia <testopia> |
Severity: | enhancement | ||
Priority: | P5 - low | CC: | alexbuckley, costalc, david, derrynj, emmi.takkinen, gmcharlt, kyle.m.hall, lari.taskula, lucas, mirjam.vantieghem, stina.hallin |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Medium patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Circulation function: | |||
Bug Depends on: | 15492 | ||
Bug Blocks: | |||
Attachments: |
Bug 22322: Self check-in without log in
Bug 22322: Self check-in without log in Bug 22322: Self check-in without log in Bug 22322: Fix QA issues Bug 22322: Fix QA issues Bug 22322: Fix QA issues Bug 22322: Self check-in without log in Bug 22322: Fix QA issues Bug 22322: Self check-in without log in Bug 22322: Fix QA issues |
Description
Oliver Behnke
2019-02-13 09:41:06 UTC
Related: going forward I think it would be useful to have a dedicated "Component" for the self checkin module as well (see the self checkout component). Thanks Created attachment 123299 [details] [review] Bug 22322: Self check-in without log in One should be able to return loans via SCO without login required. This patch adds check in box where patrons can check in their loans with barcode. To test: 1. Set "SelfCheckoutByLogin" as "cardnumber". 2. Find patron with loan or add one. 3. Go to /cgi-bin/koha/sco/sco-main.pl 4. Return loan by passing items barcode => confirm loans is returned succesfully Sponsored-by: Koha-Suomi Oy Hi Emmi, Sadly this no longer applies. Any chance we could get a rebase? Created attachment 139170 [details] [review] Bug 22322: Self check-in without log in One should be able to return loans via SCO without login required. This patch adds check in box where patrons can check in their loans with barcode. To test: 1. Set "SelfCheckoutByLogin" as "cardnumber". 2. Find patron with loan or add one. 3. Go to /cgi-bin/koha/sco/sco-main.pl 4. Return loan by passing items barcode => confirm loans is returned succesfully Sponsored-by: Koha-Suomi Oy Created attachment 140162 [details] [review] Bug 22322: Self check-in without log in One should be able to return loans via SCO without login required. This patch adds check in box where patrons can check in their loans with barcode. To test: 1. Set "SelfCheckoutByLogin" as "cardnumber". 2. Find patron with loan or add one. 3. Go to /cgi-bin/koha/sco/sco-main.pl 4. Return loan by passing items barcode => confirm loans is returned succesfully Sponsored-by: Koha-Suomi Oy Signed-off-by: Lucy Vaux-Harvey <lucy.vaux-harvey@ptfs-europe.com> Hi Emmi, there are several problems highlighted by the QA tools, can you please fix? For fixing the filters there is a handy script: misc/devel/add_missing_filters.pl. FAIL koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead-sco-self.inc FAIL filters missing_filter at line 7 ( <a class="brand" href="/cgi-bin/koha/sco/sco-main.pl"><img src="[% interface %]/[% theme %]/images/koha-logo-navbar.png" alt=""></a>) missing_filter at line 7 ( <a class="brand" href="/cgi-bin/koha/sco/sco-main.pl"><img src="[% interface %]/[% theme %]/images/koha-logo-navbar.png" alt=""></a>) missing_filter at line 31 ( [% opacheader %]) OK koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/help.tt FAIL koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt FAIL filters missing_filter at line 486 ( <b>[% checkinmessage %]</b>) missing_filter at line 589 ( if ( (Date.now() - confirmStart) < [% SelfCheckTimeout %] ) {) missing_filter at line 590 ( window.open("/cgi-bin/koha/sco/printslip.pl?borrowernumber=[% borrowernumber %]&print=qslip");) FAIL opac/sco/sco-main.pl FAIL critic # Variables::ProhibitConditionalDeclarations: Got 1 violation(s). FAIL forbidden patterns forbidden pattern: Script permissions is authnotrequired => 0, it could be correct for an OPAC script if it is was you really want error (bug 24663) (line 79) forbidden pattern: Use of DateTime->now should certainly be replaced with dt_from_string (bug 24840) (line 135) Created attachment 143764 [details] [review] Bug 22322: Fix QA issues This patch fixes following QA issues: - Add missing filters - Use dt_from_string instead of DateTime->now in sco-main.pl Following issue is left unchanged, since it is purposeful: forbidden pattern: Script permissions is authnotrequired => 0, it could be correct for an OPAC script if it is was you really want error Sponsored-by: Koha-Suomi Oy *** Bug 30590 has been marked as a duplicate of this bug. *** Created attachment 150770 [details] [review] Bug 22322: Fix QA issues This patch fixes following QA issues: - Add missing filters - Use dt_from_string instead of DateTime->now in sco-main.pl Following issue is left unchanged, since it is purposeful: forbidden pattern: Script permissions is authnotrequired => 0, it could be correct for an OPAC script if it is was you really want error Sponsored-by: Koha-Suomi Oy Created attachment 150776 [details] [review] Bug 22322: Fix QA issues This patch fixes following QA issues: - Add missing filters - Use dt_from_string instead of DateTime->now in sco-main.pl Following issue is left unchanged, since it is purposeful: forbidden pattern: Script permissions is authnotrequired => 0, it could be correct for an OPAC script if it is was you really want error Sponsored-by: Koha-Suomi Oy Signed-off-by: hinemoea <hinemoea@inlibro.com> Hi Hinemoea. Another one for you to change the status to Signed Off, so that you get the credit on the dashboard. 8-) David I tried to sign off, but the checkin was not always returned successfully when I checked the patron details. Sometimes it worked as it should, but I didn't manage to see why it worked sometimes, and sometimes failed. I tried waiting until the sco-page logged out, and sometimes it worked on the first try but not the next. I tried using both the Submit button and return key. Once it worked when I changed home library for the patron. Setting this as ASSIGNED based on Stinas comment. (In reply to Stina Hallin from comment #12) > I tried to sign off, but the checkin was not always returned successfully > when I checked the patron details. Sometimes it worked as it should, but I > didn't manage to see why it worked sometimes, and sometimes failed. I tried > waiting until the sco-page logged out, and sometimes it worked on the first > try but not the next. I tried using both the Submit button and return key. > Once it worked when I changed home library for the patron. I'm unable to repeat this. I was able to return several loans of several different patrons. Both items and patrons had different homebranch than library I was logged in on sco-page. Patch needs rebase, so I'll do that and set this back "Needs Signoff" to get more feedback. Created attachment 161722 [details] [review] Bug 22322: Self check-in without log in One should be able to return loans via SCO without login required. This patch adds check in box where patrons can check in their loans with barcode. To test: 1. Set "SelfCheckoutByLogin" as "cardnumber". 2. Find patron with loan or add one. 3. Go to /cgi-bin/koha/sco/sco-main.pl 4. Return loan by passing items barcode => confirm loans is returned succesfully Sponsored-by: Koha-Suomi Oy Signed-off-by: Lucy Vaux-Harvey <lucy.vaux-harvey@ptfs-europe.com> Created attachment 161723 [details] [review] Bug 22322: Fix QA issues This patch fixes following QA issues: - Add missing filters - Use dt_from_string instead of DateTime->now in sco-main.pl Following issue is left unchanged, since it is purposeful: forbidden pattern: Script permissions is authnotrequired => 0, it could be correct for an OPAC script if it is was you really want error Sponsored-by: Koha-Suomi Oy Signed-off-by: hinemoea <hinemoea@inlibro.com> The patches no longer apply 8-(... git bz apply 22322 Bug 22322 - Self-checkin module should provide for automatic logins (like self-checkout) 161722 - Bug 22322: Self check-in without log in 161723 - Bug 22322: Fix QA issues Apply? [(y)es, (n)o, (i)nteractive] y Applying: Bug 22322: Self check-in without log in Using index info to reconstruct a base tree... M koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt M opac/sco/sco-main.pl Falling back to patching base and 3-way merge... Auto-merging opac/sco/sco-main.pl CONFLICT (content): Merge conflict in opac/sco/sco-main.pl Auto-merging koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt error: Failed to merge in the changes. Patch failed at 0001 Bug 22322: Self check-in without log in Created attachment 165722 [details] [review] Bug 22322: Self check-in without log in One should be able to return loans via SCO without login required. This patch adds check in box where patrons can check in their loans with barcode. To test: 1. Set "SelfCheckoutByLogin" as "cardnumber". 2. Find patron with loan or add one. 3. Go to /cgi-bin/koha/sco/sco-main.pl 4. Return loan by passing items barcode => confirm loans is returned succesfully Sponsored-by: Koha-Suomi Oy Signed-off-by: Lucy Vaux-Harvey <lucy.vaux-harvey@ptfs-europe.com> Created attachment 165723 [details] [review] Bug 22322: Fix QA issues This patch fixes following QA issues: - Add missing filters - Use dt_from_string instead of DateTime->now in sco-main.pl Following issue is left unchanged, since it is purposeful: forbidden pattern: Script permissions is authnotrequired => 0, it could be correct for an OPAC script if it is was you really want error Sponsored-by: Koha-Suomi Oy Signed-off-by: hinemoea <hinemoea@inlibro.com> Rebased patches. I get an error page if I enter a barcode and press 'Submit': Sorry, the requested page is not available Error 403 In additional, if I log in to the self checkout system and go to check in the item that way, I get this error: Can't call method "homebranch" on an undefined value at /kohadevbox/koha/opac/sco/sco-main.pl line 180 in (eval) at /kohadevbox/koha/opac/sco/sco-main.pl line 180 177: if( !$checkinitem ){ 178: $checkinmessage = "Item not found."; 179: } 180: my $tobranch = $checkinitem->homebranch; 181: 182: my ($return_success,$messages,$issueinformation,$borrower) = AddReturn($uibarcode,$branch,undef,$today) unless !$success; ..... One other comment: - The title "Self checkout system" doesn't make sense, so maybe it should be changed to "Self service" or "Self service system". Looking this again and this needs some rework. It doesn't take into account e.g. changes made in bug 32256 and is full of code that is useless. Setting this back to assigned. Just a few words of encouragement: thanks Emmi (and everyone else) for your continued effort to get this implemented! It's highly appreciated! Cheers :) We have been using a Koha plugin for this. https://github.com/Hypernova-Oy/koha-plugin-self-checkout-checkin It adds a simple screen with two buttons that navigate you either to SCO or SCI. When you select SCO, you get the default Koha SCO functionality. When you select SCI, it automatically authenticates a SCI-machine account (configured in the plugin's settings) in the background (through REST API) so a patron may access SCI without logging in manually. |