Bugzilla – Attachment 22463 Details for
Bug 6149
Operator Highlighted in Search Results
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED OFF] Bug 6149: Follow-up - Operator highlighted in search results
0001-Bug-6149-Follow-up-Operator-highlighted-in-search-re.patch (text/plain), 6.24 KB, created by
Martin Renvoize (ashimema)
on 2013-10-28 11:24:54 UTC
(
hide
)
Description:
[SIGNED OFF] Bug 6149: Follow-up - Operator highlighted in search results
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2013-10-28 11:24:54 UTC
Size:
6.24 KB
patch
obsolete
>From 41f11eff8c14ca34f9100691d4507e0a9d633a10 Mon Sep 17 00:00:00 2001 >From: Katrin Fischer <Katrin.Fischer.83@web.de> >Date: Sun, 27 Oct 2013 15:34:49 +0100 >Subject: [SIGNED-OFF] Bug 6149: Follow-up - Operator highlighted > in search results > >- changed sample words to and|or|not in sysprefs.sql and > updatedatabase >- changed systempreference name from OpacHighlightedStopwords > to HighlightedStopwords, as it also works for the staff > results page > >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > installer/data/mysql/sysprefs.sql | 2 +- > installer/data/mysql/updatedatabase.pl | 2 +- > koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref | 2 +- > koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/results.tt | 2 +- > koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt | 2 +- > koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt | 2 +- > 6 files changed, 6 insertions(+), 6 deletions(-) > >diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql >index 055cab2..d0fe2fa 100644 >--- a/installer/data/mysql/sysprefs.sql >+++ b/installer/data/mysql/sysprefs.sql >@@ -225,7 +225,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` > ('opacheader','','70|10','Add HTML to be included as a custom header in the OPAC','Textarea'), > ('OpacHiddenItems','','','This syspref allows to define custom rules for hiding specific items at opac. See docs/opac/OpacHiddenItems.txt for more informations.','Textarea'), > ('OpacHighlightedWords','1','','If Set, then queried words are higlighted in OPAC','YesNo'), >-('OpacHighlightedStopWords','and|And|or|Or',NULL,'List of words to NOT highlight when OpacHitHighlight is enabled','free'), >+('HighlightedStopWords','and|or|not',NULL,'List of words to NOT highlight when OpacHitHighlight is enabled','free'), > ('OpacHoldNotes','0','','Show hold notes on OPAC','YesNo'), > ('OPACItemHolds','1','','Allow OPAC users to place hold on specific items. If OFF, users can only request next available copy.','YesNo'), > ('OpacItemLocation','callnum','callnum|ccode|location','Show the shelving location of items in the opac','Choice'), >diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl >index 97adfc6..f7bb10e 100755 >--- a/installer/data/mysql/updatedatabase.pl >+++ b/installer/data/mysql/updatedatabase.pl >@@ -7332,7 +7332,7 @@ if ( CheckVersion($DBversion) ) { > > $DBversion = "3.13.00.XXX"; > if ( CheckVersion($DBversion) ) { >- $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OpacHighlightedStopWords','and|And|or|Or',NULL,'List of words to NOT highlight when OpacHitHighlight is enabled','free')" >+ $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('HighlightedStopWords','and|or|not',NULL,'List of words to NOT highlight when OpacHighlightedWords is enabled','free')" > ); > print "Upgrade to $DBversion done (Bug 6149: Operator highlighted in search results)\n"; > SetVersion($DBversion); >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref >index e3969fc..019038c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref >@@ -136,7 +136,7 @@ OPAC: > yes: Highlight > no: "Don't highlight" > - words the patron searched for in their search results and detail pages; To prevent certain words from ever being highlighted, enter a list of stopwords here >- - pref: OpacHighlightedStopWords >+ - pref: HighlightedStopWords > class: multi > - (separate columns with |) > - >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/results.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/results.tt >index 5ea34f3..2f43d40 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/results.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/results.tt >@@ -160,7 +160,7 @@ function highlightOn() { > var x; > for (x in q_array) { > q_array[x] = q_array[x].toLowerCase(); >- var myStopwords = "[% Koha.Preference('OpacHighlightedStopWords') %]".toLowerCase().split('|'); >+ var myStopwords = "[% Koha.Preference('HighlightedStopWords') %]".toLowerCase().split('|'); > if ( (q_array[x].length > 0) && ($.inArray(q_array[x], myStopwords) == -1) ) { > toHighlight.highlight(q_array[x]); > } >diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt >index d29aff8..765103b 100644 >--- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt >+++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt >@@ -60,7 +60,7 @@ > for (x in q_array) { > q_array[x] = q_array[x].replace(/\w*:([\w])/, "$1"); > q_array[x] = q_array[x].toLowerCase(); >- var myStopwords = "[% Koha.Preference('OpacHighlightedStopWords') %]".toLowerCase().split('|'); >+ var myStopwords = "[% Koha.Preference('HighlightedStopWords') %]".toLowerCase().split('|'); > if( $.inArray(q_array[x], myStopwords) == -1 ) { > $(".title").highlight(q_array[x]); > $(".author").highlight(q_array[x]); >diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt >index 08f2313..fbe7bbe 100644 >--- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt >+++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt >@@ -101,7 +101,7 @@ function highlightOn() { > for (x in q_array) { > q_array[x] = q_array[x].replace(/\w*:([\w])/, "$1"); > q_array[x] = q_array[x].toLowerCase(); >- var myStopwords = "[% Koha.Preference('OpacHighlightedStopWords') %]".toLowerCase().split('|'); >+ var myStopwords = "[% Koha.Preference('HighlightedStopWords') %]".toLowerCase().split('|'); > if ( (q_array[x].length > 0) && ($.inArray(q_array[x], myStopwords) == -1) ) { > $(".title").highlight(q_array[x]); > $(".author").highlight(q_array[x]); >-- >1.7.10.4 >
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 6149
:
20240
|
20469
|
20540
|
20543
|
20715
|
20802
|
21168
|
21582
|
21831
|
22448
|
22463
|
22466
|
22505
|
22511
|
23005
|
23025
|
23027
|
23064
|
23065
|
23066
|
26051
|
30136
|
30137
|
30138
|
30139
|
30140
|
30141
|
30142
|
30143
|
30144
|
30835
|
30842
|
30843
|
30844
|
30845
|
30846
|
31403