Bug 11139 - opac-topissues does not work with CCODE
Summary: opac-topissues does not work with CCODE
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: OPAC (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Fridolin SOMERS
QA Contact: Testopia
URL:
Whiteboard:
Keywords:
: 12136 (view as bug list)
Depends on: 14788
Blocks:
  Show dependency treegraph
 
Reported: 2013-10-25 09:43 UTC by Fridolin SOMERS
Modified: 2016-06-21 21:40 UTC (History)
7 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Bot Control: ---
When did the bot last check this: 2013-11-07 00:00:00
Who signed the patch off:
Text to go in the release notes:


Attachments
Bug 11139 - opac-topissues does not work with CCODE (1.99 KB, patch)
2013-10-25 09:55 UTC, Fridolin SOMERS
Details | Diff | Splinter Review
no option to limit on ccode (30.68 KB, image/png)
2014-01-09 18:33 UTC, Nicole C. Engard
Details
Bug 11139 - opac-topissues does not work with CCODE (2.05 KB, patch)
2014-03-07 19:09 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 11139: Add support for multiple values in AdvancedSearchTypes (16.18 KB, patch)
2015-10-01 13:33 UTC, Julian Maurice
Details | Diff | Splinter Review
Bug 11139: Add support for multiple values in AdvancedSearchTypes (16.36 KB, patch)
2015-10-15 06:53 UTC, Marc Véron
Details | Diff | Splinter Review
[PASSED QA] Bug 11139: Add support for multiple values in AdvancedSearchTypes (16.42 KB, patch)
2015-10-22 06:13 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Fridolin SOMERS 2013-10-25 09:43:30 UTC
When OPAC most populars uses collection code, it does not work.
There are never results.
Comment 1 Fridolin SOMERS 2013-10-25 09:55:58 UTC Comment hidden (obsolete)
Comment 2 I'm just a bot 2013-11-07 08:17:19 UTC
testing 1 commit(s) (applied to 5fa6168 'Bug 11204: make pendingreserves use d')

 [1;32mOK[0m	opac/opac-topissues.pl
Comment 3 Owen Leonard 2013-11-14 15:59:13 UTC
I can't reproduce this problem in master. I get results when either item type or collection code.
Comment 4 Fridolin SOMERS 2013-11-14 16:07:29 UTC
(In reply to Owen Leonard from comment #3)
> I can't reproduce this problem in master. I get results when either item
> type or collection code.
Is your authorised values catégory for collection codes : ccode or CCODE ?
Comment 5 Owen Leonard 2013-11-14 16:43:46 UTC
(In reply to Fridolyn SOMERS from comment #4)
> Is your authorised values catégory for collection codes : ccode or CCODE ?

CCODE.
Comment 6 Nicole C. Engard 2014-01-09 18:33:33 UTC
Created attachment 24103 [details]
no option to limit on ccode

I don't even see an option for collection code in the opac top issue.
Comment 7 Owen Leonard 2014-01-09 18:42:37 UTC
> I don't even see an option for collection code in the opac top issue.

You have to have the AdvancedSearchTypes preference set to 'ccode'
Comment 8 Kyle M Hall 2014-03-07 19:09:03 UTC Comment hidden (obsolete)
Comment 9 Katrin Fischer 2014-03-31 16:20:55 UTC
I think this patch is incomplete - AdvancedSearchTypes is no longer a switch, but can have multiple values:

loc - NOT OK, the itemtype pull down still shows, but it's empty
ccode - OK, collections show
itemtypes - OK, itemtypes show
ccode|itemtpyes - NOT OK, pull down empty
itemtypes|loc - NOT OK, pull down empty
Comment 10 Fridolin SOMERS 2015-07-31 15:04:02 UTC
One of your client still have this problem with 3.18.08
Comment 11 Julian Maurice 2015-10-01 13:33:38 UTC
Bug 14788 fixes the ccode problem, but not the "multiple values" problem.

So here is a patch that try to fix it (depends on 14788):
Comment 12 Julian Maurice 2015-10-01 13:33:52 UTC Comment hidden (obsolete)
Comment 13 Fridolin SOMERS 2015-10-02 07:13:13 UTC
Nice job Julian
Comment 14 Marc Véron 2015-10-02 09:51:37 UTC
Hi Julian and Fridolin,

It might be a good idea to have a separate syspref for the behavior of the most popular list instead of the double use of 'AdvancedSearchTypes'

It would make things much more clearer.

What do you think?

Marc
Comment 15 Fridolin SOMERS 2015-10-14 12:38:28 UTC
(In reply to Marc Véron from comment #14)
> Hi Julian and Fridolin,
> 
> It might be a good idea to have a separate syspref for the behavior of the
> most popular list instead of the double use of 'AdvancedSearchTypes'
> 
> It would make things much more clearer.
> 
> What do you think?
> 
> Marc
I agree
Comment 16 Marc Véron 2015-10-15 06:53:12 UTC Comment hidden (obsolete)
Comment 17 Marc Véron 2015-10-15 06:54:41 UTC
*** Bug 12136 has been marked as a duplicate of this bug. ***
Comment 18 Katrin Fischer 2015-10-22 06:13:02 UTC
Created attachment 43732 [details] [review]
[PASSED QA] Bug 11139: Add support for multiple values in AdvancedSearchTypes

AdvancedSearchTypes syspref can be multivalued, opac-topissues.pl
have to support that.

AdvancedSearchTypes can have one or more of the following values:
'itemtypes', 'ccode', 'loc'.  But this patch adds support only for
itemtypes and ccode.  AdvancedSearchTypes can still contain 'loc' but it
will change nothing to the behaviour of opac-topissues.pl.

This patch also removes duplicate code in template (the "Refine your
search" form was written in two different places)
This introduces a small behaviour change: when there is no results,
instead of having the form in the center of the page, it remains in the
left sidebar and we have a "No results" message in the main area.

Depends on bug 14788

Tested on top of 14788. Works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 19 Tomás Cohen Arazi 2015-10-22 15:02:35 UTC
Patch pushed to master.

Thanks Maurice!