Bug 18573 - Error when adding a suggestion in the OPAC
Summary: Error when adding a suggestion in the OPAC
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: OPAC (show other bugs)
Version: master
Hardware: All All
: P5 - low major (vote)
Assignee: Jonathan Druart
QA Contact: Testopia
URL:
Keywords:
Depends on: 17847
Blocks:
  Show dependency treegraph
 
Reported: 2017-05-10 15:38 UTC by Owen Leonard
Modified: 2019-06-27 09:24 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 18573: (bug 17847 follow-up) Update av-build-dropbox.inc for OPAC (2.08 KB, patch)
2017-05-10 16:15 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 18573: (bug 17847 follow-up) Update av-build-dropbox.inc for OPAC (2.25 KB, patch)
2017-05-10 20:32 UTC, Marc Véron
Details | Diff | Splinter Review
Bug 18573: (bug 17847 follow-up) Update av-build-dropbox.inc for OPAC (2.31 KB, patch)
2017-05-11 10:15 UTC, Julian Maurice
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2017-05-10 15:38:09 UTC
I have enabled  AnonSuggestions and defined a valid borrowernumber in  AnonymousPatron. When I go to /cgi-bin/koha/opac-suggestions.pl?op=add I get an error:

Template process failed: undef error - The method default is not covered by tests! at /home/vagrant/kohaclone/C4/Templates.pm line 121.
Comment 1 Owen Leonard 2017-05-10 16:03:59 UTC
git bisect points to  Bug 17847
Comment 2 Jonathan Druart 2017-05-10 16:12:31 UTC
On bug 17847, av-build-dropbox.inc has been updated for the intranet, not OPAC
Comment 3 Jonathan Druart 2017-05-10 16:15:27 UTC
Created attachment 63356 [details] [review]
Bug 18573: (bug 17847 follow-up) Update av-build-dropbox.inc for OPAC

On bug 17847, av-build-dropbox.inc has been updated for the intranet,
not OPAC

There is only one call to av-build-dropbox.inc at the OPAC, from
opac-suggestion.tt

Test plan:
Create a new suggestion, anonymous or with a logged in user
=> Without this patch you got
  Template process failed: undef error - The method default is not
  covered by tests! at /home/vagrant/kohaclone/C4/Templates.pm line 121.
=> With this patch applied you should see the item type dropdown list
correctly filled
Comment 4 Marc Véron 2017-05-10 20:32:28 UTC
Created attachment 63369 [details] [review]
Bug 18573: (bug 17847 follow-up) Update av-build-dropbox.inc for OPAC

On bug 17847, av-build-dropbox.inc has been updated for the intranet,
not OPAC

There is only one call to av-build-dropbox.inc at the OPAC, from
opac-suggestion.tt

Test plan:
Create a new suggestion, anonymous or with a logged in user
=> Without this patch you got
  Template process failed: undef error - The method default is not
  covered by tests! at /home/vagrant/kohaclone/C4/Templates.pm line 121.
=> With this patch applied you should see the item type dropdown list
correctly filled

Reproduced without patch, OK with patch
Signed-off-by: Marc Véron <veron@veron.ch>
Comment 5 Julian Maurice 2017-05-11 10:08:05 UTC
QAing this now
Comment 6 Julian Maurice 2017-05-11 10:15:39 UTC
Created attachment 63379 [details] [review]
Bug 18573: (bug 17847 follow-up) Update av-build-dropbox.inc for OPAC

On bug 17847, av-build-dropbox.inc has been updated for the intranet,
not OPAC

There is only one call to av-build-dropbox.inc at the OPAC, from
opac-suggestion.tt

Test plan:
Create a new suggestion, anonymous or with a logged in user
=> Without this patch you got
  Template process failed: undef error - The method default is not
  covered by tests! at /home/vagrant/kohaclone/C4/Templates.pm line 121.
=> With this patch applied you should see the item type dropdown list
correctly filled

Reproduced without patch, OK with patch
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Comment 7 Kyle M Hall 2017-05-12 12:46:45 UTC
Pushed to master for 17.05, thanks Jonathan!
Comment 8 Katrin Fischer 2017-05-14 09:47:29 UTC
Dependency is not part of 16.11.x, so this should not be needed there.