(Bug 4049) Searching itemtypes returning noise
Fix the problem of searching on partial itemtypes strings
for instance, itemtype="ARTICLE DE PERIODIQUE", itemtype="PERIODIQUE"
searching on itemtype="PERIODIQUE" would also get "ARTICLE DE PERIODIQUE"
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
(cherry picked from commit 700de9664d)
Signed-off-by: Chris Nighswonger <chris.nighswonger@gmail.com>
This commit is contained in:
parent
1d9af3b9ed
commit
e9d0f2696e
|
|
@ -234,7 +234,7 @@ my $advanced_search_types = C4::Context->preference("AdvancedSearchTypes");
|
|||
|
||||
if (!$advanced_search_types or $advanced_search_types eq 'itemtypes') { foreach my $thisitemtype ( sort {$itemtypes->{$a}->{'description'} cmp $itemtypes->{$b}->{'description'} } keys %$itemtypes ) {
|
||||
my %row =( number=>$cnt++,
|
||||
ccl => $itype_or_itemtype,
|
||||
ccl => qq($itype_or_itemtype,phr),
|
||||
code => $thisitemtype,
|
||||
selected => $selected,
|
||||
description => $itemtypes->{$thisitemtype}->{'description'},
|
||||
|
|
|
|||
|
|
@ -247,7 +247,7 @@ melm 999$d biblioitemnumber:n,biblioitemnumber:w,biblioitemnumber:s
|
|||
melm 942$0 totalissues:n,totalissues:s
|
||||
melm 942$2 cn-bib-source
|
||||
melm 942$6 cn-bib-sort:n,cn-bib-sort:s
|
||||
melm 942$c itemtype:w
|
||||
melm 942$c itemtype:w,itemtype:p
|
||||
melm 942$n Suppress:w,Suppress:n
|
||||
|
||||
# need to check bib1
|
||||
|
|
@ -265,7 +265,7 @@ melm 952$4 damaged:n,damaged:w
|
|||
melm 952$5 restricted:n,restricted:w
|
||||
melm 952$6 cn-sort:n,cn-sort:s
|
||||
melm 952$7 notforloan:n,notforloan:w
|
||||
melm 952$8 ccode
|
||||
melm 952$8 ccode:w,ccode:p
|
||||
melm 952$9 itemnumber:n,itemnumber:s
|
||||
melm 952$a homebranch
|
||||
melm 952$b holdingbranch
|
||||
|
|
@ -293,5 +293,5 @@ melm 952$u uri:u
|
|||
melm 952$v replacementprice
|
||||
melm 952$w replacementpricedate
|
||||
#melm 952$x
|
||||
melm 952$y itype:w
|
||||
melm 952$y itype:w,itype:p
|
||||
melm 952$z Note:w,Note:p
|
||||
|
|
|
|||
|
|
@ -39,8 +39,8 @@ melm 011$y ISSN:w,Identifier-standard:w
|
|||
# wrong ISSN
|
||||
melm 011$z ISSN:w,Identifier-standard:w
|
||||
|
||||
melm 200$b itemtype:w,itype:w
|
||||
melm 995$r itemtype:w,itype:w
|
||||
melm 200$b itemtype:w,itemtype:p,itype:w,itype:p
|
||||
melm 995$r itemtype:w,itemtype:p,itype:w,itype:p
|
||||
|
||||
melm 100$a tpubdate:s:range(data,8,1),ta:w:range(data,17,1),ta:w:range(data,18,1),ta:w:range(data,19,1),Modified-code:n:range(data,21,1),ln:s:range(data,22,3),char-encoding:n:range(data,26,2),char-encoding:n:range(data,28,2),char-encoding:n:range(data,30,2),script-Title:n:range(data,34,2)
|
||||
melm 101$a ln
|
||||
|
|
@ -56,7 +56,7 @@ melm 102$a Country-heading
|
|||
#Biography code 1
|
||||
melm 105$a Illustration-code:w:range(data,0,4),Content-type:w:range(data,4,1),Content-type:w:range(data,5,1),Content-type:w:range(data,6,1),Content-type:w:range(data,7,1),Conference-code:w:range(data,8,1),Festschrift-indicator:w:range(data,9,1),Index-indicator:w:range(data,10,1),Literature-Code:w:range(data,11,1),Biography-Code:w:range(data,12,1)
|
||||
|
||||
melm 106$a itype
|
||||
melm 106$a itype:w,itype:p
|
||||
|
||||
#Field 110 Description
|
||||
#Name of Data Element Number of characters Character Positions
|
||||
|
|
@ -80,6 +80,10 @@ melm 680$b LC-call-number:s
|
|||
melm 680 LC-call-number
|
||||
#melm 001 Identifier-standard:w
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
melm 200$b itype:w,itype:p
|
||||
>>>>>>> (Bug 4049) Searching itemtypes returning noise
|
||||
|
||||
#melm 100$9 Cross-Reference !:w
|
||||
|
||||
|
|
|
|||
|
|
@ -159,8 +159,8 @@ my $advanced_search_types = C4::Context->preference("AdvancedSearchTypes");
|
|||
|
||||
if (!$advanced_search_types or $advanced_search_types eq 'itemtypes') {
|
||||
foreach my $thisitemtype ( sort {$itemtypes->{$a}->{'description'} cmp $itemtypes->{$b}->{'description'} } keys %$itemtypes ) {
|
||||
my %row =( number=>$cnt++,
|
||||
ccl => $itype_or_itemtype,
|
||||
my %row =( number=>$cnt++,
|
||||
ccl => "$itype_or_itemtype,phr",
|
||||
code => $thisitemtype,
|
||||
selected => $selected,
|
||||
description => $itemtypes->{$thisitemtype}->{'description'},
|
||||
|
|
|
|||
Loading…
Reference in New Issue