Clicking on subjects does not work as expected when XSLT is on and marcflavour = NORMARC. Looks like missing implementations of TraceCompleteSubfields and TraceSubjectSubdivisions are the culprits...
Created attachment 7676 [details] [review] Bug 7537 - Implement TraceCompleteSubfields and TraceSubjectSubdivisions for NORMARC XSLT As the title says, this patch implements TraceCompleteSubfields and TraceSubjectSubdivisions for NORMARC XSLT, both for the OPAC and the Intranet. This affects how clickable subject-links are constructed. To test: Find a record with a complex subject, like "Art -- United States". MARC21 and NORMARC are very similar in how they handle subjects, so testing on a MARC21 database should be OK. Make sure you have these syspref settings: - marcflavour = NORMARC - XSLTDetailsDisplay = using XSLT stylesheets - OPACXSLTDetailsDisplay = using XSLT stylesheets Now try the different combinations of TraceCompleteSubfields and TraceSubjectSubdivisions and check the format of the clickable links, both in the OPAC and staff client. Here's what you should be seeing: 1. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Don't include -> q=su:{Art} 2. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Don't include -> q=su,complete-subfield:{Art} 3. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Include -> q=(su:{Art}) and (su:{United%20States.}) 4. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Include -> q=(su,complete-subfield:{Art}) and (su,complete-subfield:{United States.})
Oops... Looks like my patch works with MARC21-indexing, but not with NORMARC... New patch coming after I figure out why!
Created attachment 8119 [details] [review] Bug 7537 - Implement TraceCompleteSubfields, TraceSubjectSubdivisions and TracingQuotes for NORMARC XSLT IMPORTANT! This patch relies on the patch for Bug 7092, and should be applied on top of that patch! It will not work without it. As the title says, this patch implements TraceCompleteSubfields, TraceSubjectSubdivisions and TracingQuotes for NORMARC XSLT, both for the OPAC and the Intranet. This affects how clickable subject-links are constructed. To make this work the indexing of MARC fields in the 600 range is changed to include "Subject:p" in several new places. To test: Find a record with a "complex" subject, like "Internet -- Law and legislation". MARC21 and NORMARC are very similar in how they handle subjects, so testing on a MARC21 database should be OK. (Changes in indexing reflect changes already made to the MARC21 indexing.) Make sure you have these syspref settings: - marcflavour = NORMARC - XSLTDetailsDisplay = using XSLT stylesheets - OPACXSLTDetailsDisplay = using XSLT stylesheets (Ideally, testing should be done on a real NORMARC setup, but since the changes to indexing only reflect how it's already done in MARC21, I think testing on a MARC21 installation with marcflavour = NORMARC should be OK.) Now try the different combinations of TraceCompleteSubfields, TraceSubjectSubdivisions and TracingQuotes, and check the format of the clickable links, both in the OPAC and staff client. Here's what you should be seeing: 1. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Don't include TracingQuotes = quotes opac-search.pl?q=su:"Internet" TracingQuotes = curlybrace opac-search.pl?q=su:{Internet} 2. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Don't include TracingQuotes = quotes opac-search.pl?q=su,complete-subfield:"Internet" TracingQuotes = curlybrace opac-search.pl?q=su,complete-subfield:{Internet} 3. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Include TracingQuotes = quotes opac-search.pl?q=(su:"Internet") and (su:"Law and legislation.") TracingQuotes = curlybrace opac-search.pl?q=(su:{Internet}) and (su:{Law and legislation.}) 4. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Include TracingQuotes = quotes opac-search.pl?q=(su,complete-subfield:"Internet") and (su,complete-subfield:"Law and legislation.") TracingQuotes = curlybrace opac-search.pl?q=(su,complete-subfield:{Internet}) and (su,complete-subfield:{Law and legislation.})
The problem with my first patch was that I needed a fix for Bug 7092 - "Complete-subfield searches TraceCompleteSubfields syspref not working correctly" first (specifically, the TracingQuotes syspref). Hence, this patch must be applied on top of the one for that bug.
Created attachment 8141 [details] [review] Bug 7537 - Implement TraceCompleteSubfields, TraceSubjectSubdivisions and TracingQuotes for NORMARC XSLT IMPORTANT! This patch relies on the patch for Bug 7092, and should be applied on top of that patch! It will not work without it. As the title says, this patch implements TraceCompleteSubfields, TraceSubjectSubdivisions and TracingQuotes for NORMARC XSLT, both for the OPAC and the Intranet. This affects how clickable subject-links are constructed. To make this work the indexing of MARC fields in the 600 range is changed to include "Subject:p" in several new places. To test: Find a record with a "complex" subject, like "Internet -- Law and legislation". MARC21 and NORMARC are very similar in how they handle subjects, so testing on a MARC21 database should be OK. (Changes in indexing reflect changes already made to the MARC21 indexing.) Make sure you have these syspref settings: - marcflavour = NORMARC - XSLTDetailsDisplay = using XSLT stylesheets - OPACXSLTDetailsDisplay = using XSLT stylesheets (Ideally, testing should be done on a real NORMARC setup, but since the changes to indexing only reflect how it's already done in MARC21, I think testing on a MARC21 installation with marcflavour = NORMARC should be OK.) Now try the different combinations of TraceCompleteSubfields, TraceSubjectSubdivisions and TracingQuotes, and check the format of the clickable links, both in the OPAC and staff client. Here's what you should be seeing: 1. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Don't include TracingQuotes = quotes opac-search.pl?q=su:"Internet" TracingQuotes = curlybrace opac-search.pl?q=su:{Internet} 2. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Don't include TracingQuotes = quotes opac-search.pl?q=su,complete-subfield:"Internet" TracingQuotes = curlybrace opac-search.pl?q=su,complete-subfield:{Internet} 3. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Include TracingQuotes = quotes opac-search.pl?q=(su:"Internet") and (su:"Law and legislation.") TracingQuotes = curlybrace opac-search.pl?q=(su:{Internet}) and (su:{Law and legislation.}) 4. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Include TracingQuotes = quotes opac-search.pl?q=(su,complete-subfield:"Internet") and (su,complete-subfield:"Law and legislation.") TracingQuotes = curlybrace opac-search.pl?q=(su,complete-subfield:{Internet}) and (su,complete-subfield:{Law and legislation.}) Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
I'll do a new patch to reflect the changes to Bug 7092 (renaming of the TracingQuotes syspref).
Comment on attachment 8141 [details] [review] Bug 7537 - Implement TraceCompleteSubfields, TraceSubjectSubdivisions and TracingQuotes for NORMARC XSLT Needs an update after the changes to Bug 7092 (syspref TracingQuotes renamed to UseICU). I'll do a new patch for this after 7092 gets through QA.
Created attachment 8587 [details] [review] Bug 7537 - Implement TraceCompleteSubfields, TraceSubjectSubdivisions and UseICU for NORMARC XSLT IMPORTANT! This patch relies on the patch for Bug 7092, which is now pushed to master. As the title says, this patch implements TraceCompleteSubfields, TraceSubjectSubdivisions and UseICU for NORMARC XSLT, both for the OPAC and the Intranet. This affects how clickable subject-links are constructed. To make this work the indexing of MARC fields in the 600 range is changed to include "Subject:p" in several new places. To test: Find a record with a "complex" subject, like "Internet -- Law and legislation". MARC21 and NORMARC are very similar in how they handle subjects, so testing on a MARC21 database should be OK. (Changes in indexing reflect changes already made to the MARC21 indexing.) Make sure you have these syspref settings: - marcflavour = NORMARC - XSLTDetailsDisplay = using XSLT stylesheets - OPACXSLTDetailsDisplay = using XSLT stylesheets (Ideally, testing should be done on a real NORMARC setup, but since the changes to indexing only reflect how it's already done in MARC21, I think testing on a MARC21 installation with marcflavour = NORMARC should be OK.) Now try the different combinations of TraceCompleteSubfields, TraceSubjectSubdivisions and UseICU, and check the format of the clickable links, both in the OPAC and staff client. Here's what you should be seeing: 1. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Don't include UseICU = Not using opac-search.pl?q=su:"Internet" UseICU = Using opac-search.pl?q=su:{Internet} 2. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Don't include UseICU = Not using opac-search.pl?q=su,complete-subfield:"Internet" UseICU = Using opac-search.pl?q=su,complete-subfield:{Internet} 3. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Include UseICU = Not using opac-search.pl?q=(su:"Internet") AND (su:"Law and legislation.") UseICU = Using opac-search.pl?q=(su:{Internet}) AND (su:{Law and legislation.}) 4. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Include UseICU = Not using opac-search.pl?q=(su,complete-subfield:"Internet") AND (su,complete-subfield:"Law and legislation.") UseICU = Using opac-search.pl?q=(su,complete-subfield:{Internet}) AND (su,complete-subfield:{Law and legislation.}) UPDATE 2012-03-23 - Change the syspref TracingQuotes to UseICU, see bug 7092 - Change boolean operator from "and" to "AND", see bug 7695
Updated patch: - Change the syspref TracingQuotes to UseICU, see bug 7092 - Change boolean operator from "and" to "AND", see bug 7695
Created attachment 8654 [details] [review] [SIGNED-OFF] Bug 7537 - Implement TraceCompleteSubfields, TraceSubjectSubdivisions and UseICU for NORMARC XSLT IMPORTANT! This patch relies on the patch for Bug 7092, which is now pushed to master. As the title says, this patch implements TraceCompleteSubfields, TraceSubjectSubdivisions and UseICU for NORMARC XSLT, both for the OPAC and the Intranet. This affects how clickable subject-links are constructed. To make this work the indexing of MARC fields in the 600 range is changed to include "Subject:p" in several new places. To test: Find a record with a "complex" subject, like "Internet -- Law and legislation". MARC21 and NORMARC are very similar in how they handle subjects, so testing on a MARC21 database should be OK. (Changes in indexing reflect changes already made to the MARC21 indexing.) Make sure you have these syspref settings: - marcflavour = NORMARC - XSLTDetailsDisplay = using XSLT stylesheets - OPACXSLTDetailsDisplay = using XSLT stylesheets (Ideally, testing should be done on a real NORMARC setup, but since the changes to indexing only reflect how it's already done in MARC21, I think testing on a MARC21 installation with marcflavour = NORMARC should be OK.) Now try the different combinations of TraceCompleteSubfields, TraceSubjectSubdivisions and UseICU, and check the format of the clickable links, both in the OPAC and staff client. Here's what you should be seeing: 1. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Don't include UseICU = Not using opac-search.pl?q=su:"Internet" UseICU = Using opac-search.pl?q=su:{Internet} 2. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Don't include UseICU = Not using opac-search.pl?q=su,complete-subfield:"Internet" UseICU = Using opac-search.pl?q=su,complete-subfield:{Internet} 3. TraceCompleteSubfields = Don't force TraceSubjectSubdivisions = Include UseICU = Not using opac-search.pl?q=(su:"Internet") AND (su:"Law and legislation.") UseICU = Using opac-search.pl?q=(su:{Internet}) AND (su:{Law and legislation.}) 4. TraceCompleteSubfields = Force TraceSubjectSubdivisions = Include UseICU = Not using opac-search.pl?q=(su,complete-subfield:"Internet") AND (su,complete-subfield:"Law and legislation.") UseICU = Using opac-search.pl?q=(su,complete-subfield:{Internet}) AND (su,complete-subfield:{Law and legislation.}) UPDATE 2012-03-23 - Change the syspref TracingQuotes to UseICU, see bug 7092 - Change boolean operator from "and" to "AND", see bug 7695 Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Note: UseControlnumber must be turned off. 1) Works. 2) Works. 3) Works. 4) Works.
Changes NORMARC XSLT and record.abs only. Record.abs changes are to add new subject:p indexes, and XSLT changes are safe and clean (correctly uses the standard 'delimeter', even though it's a typo). Marking as Passed QA.
patch pushed, but not tested myself, trusting Magnus to fix quickly any problem ;-)
Works in 3.8.