MARC21/NORMARC have XSL files to transform marcxml biblio records into various metadata formats: mods, mod3, oai-dc, rdfdc, rss2, srw_dc. Those XSL are located in 'intranet-tmpl/prog/en/xslt' directory. For Unimarc, there is just one XSL to transform record into OAI-DC format.
Created attachment 44670 [details] [review] Bug 15162 - Add for Unimarc transformation to new metadata formats This patch add: -UNIMARCslim2SRWDC.xsl -UNIMARCslim2RDFDC.xsl To test: -In UNIMARC envarioment -Apply patch -Apply patch 13642 -Follow test plan for bug 13642 -Check for any data loss
Created attachment 44679 [details] [review] Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC To test with an Unimarc Catalog: - Open this URL /cgi-bin/koha/unapi?id=koha:biblionumber:41201&format=marcxml And play with id & format parameters Test format=rdfdc and format=srw_dc - Or try with bug 13642
Created attachment 44766 [details] [review] [SIGNED-OFF]Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC To test with an Unimarc Catalog: - Open this URL /cgi-bin/koha/unapi?id=koha:biblionumber:41201&format=marcxml And play with id & format parameters Test format=rdfdc and format=srw_dc - Or try with bug 13642 Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com> Works as advertised. Both XML formats generated successfully.
Created attachment 44822 [details] [review] Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC Fix also, marginaly, OAI-DC XSL file which were using 090$a as biblionumber rather than 001. To test with an Unimarc Catalog: - Open this URL /cgi-bin/koha/unapi?id=koha:biblionumber:41201&format=marcxml And play with id & format parameters Test format=rdfdc and format=srw_dc - Or try with bug 13642
Created attachment 44823 [details] [review] Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC Fix also, marginaly, OAI-DC XSL file which were using 090$a as biblionumber rather than 001. To test with an Unimarc Catalog: - Open this URL /cgi-bin/koha/unapi?id=koha:biblionumber:41201&format=marcxml And play with id & format parameters Test format=rdfdc and format=srw_dc - Or try with bug 13642
Created attachment 44824 [details] [review] Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC Fix also, marginaly, OAI-DC XSL file which were using 090$a as biblionumber rather than 001. To test with an Unimarc Catalog: - Open this URL /cgi-bin/koha/unapi?id=koha:biblionumber:41201&format=marcxml And play with id & format parameters Test format=rdfdc and format=srw_dc - Or try with bug 13642
Created attachment 44825 [details] [review] [SIGNED-OFF]Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC Fix also, marginaly, OAI-DC XSL file which were using 090$a as biblionumber rather than 001. To test with an Unimarc Catalog: - Open this URL /cgi-bin/koha/unapi?id=koha:biblionumber:41201&format=marcxml And play with id & format parameters Test format=rdfdc and format=srw_dc - Or try with bug 13642 Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com> Works as advertised. Both XML formats generated successfully. Also fix problem with OPACBaseURL in UNIMARC environment. Tested with Sandbox too.
Comment on attachment 44825 [details] [review] [SIGNED-OFF]Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC Review of attachment 44825 [details] [review]: ----------------------------------------------------------------- ::: koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2RDFDC.xsl @@ +142,5 @@ > + <xsl:text>URN:ISSN:</xsl:text> > + <xsl:value-of select="marc:subfield[@code='a']"/> > + </dc:identifier> > + </xsl:for-each> > + <xsl:for-each select="marc:datafield[@tag=995]"> It seems that unapi does not return the item fields. @@ +147,5 @@ > + <dc:identifier> > + <xsl:text>LOC:</xsl:text> > + <xsl:choose> > + <xsl:when test="marc:subfield[@code='c']='MAIN'">Main library</xsl:when> > + <xsl:when test="marc:subfield[@code='c']='BIB2'">Library 2</xsl:when> Hum? :)
(In reply to Jonathan Druart from comment #8) > Comment on attachment 44825 [details] [review] [review] > [SIGNED-OFF]Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC > > Review of attachment 44825 [details] [review] [review]: > ----------------------------------------------------------------- > > ::: koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2RDFDC.xsl > @@ +142,5 @@ > > + <xsl:text>URN:ISSN:</xsl:text> > > + <xsl:value-of select="marc:subfield[@code='a']"/> > > + </dc:identifier> > > + </xsl:for-each> > > + <xsl:for-each select="marc:datafield[@tag=995]"> > > It seems that unapi does not return the item fields. So it won't hurt. It's a cut-and-paste of the OAI-PMH XSL. > @@ +147,5 @@ > > + <dc:identifier> > > + <xsl:text>LOC:</xsl:text> > > + <xsl:choose> > > + <xsl:when test="marc:subfield[@code='c']='MAIN'">Main library</xsl:when> > > + <xsl:when test="marc:subfield[@code='c']='BIB2'">Library 2</xsl:when> > > Hum? :) It's how it is now for OAI XSL. It's not a regression... It won't display anything except if a Unimarc DB has a branch named MAIN or BIB2.
Created attachment 46582 [details] [review] Bug 15162 Add for Unimarc XSL trans for RDF-DC & SRW-DC Fix also, marginaly, OAI-DC XSL file which were using 090$a as biblionumber rather than 001. To test with an Unimarc Catalog: - Open this URL /cgi-bin/koha/unapi?id=koha:biblionumber:41201&format=marcxml And play with id & format parameters Test format=rdfdc and format=srw_dc - Or try with bug 13642 Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com> Works as advertised. Both XML formats generated successfully. Also fix problem with OPACBaseURL in UNIMARC environment. Tested with Sandbox too. Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Created attachment 46583 [details] [review] Bug 15162: Remove specific test in UNIMARCslim2*.xsl Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(In reply to Frédéric Demians from comment #9) > > @@ +147,5 @@ > > > + <dc:identifier> > > > + <xsl:text>LOC:</xsl:text> > > > + <xsl:choose> > > > + <xsl:when test="marc:subfield[@code='c']='MAIN'">Main library</xsl:when> > > > + <xsl:when test="marc:subfield[@code='c']='BIB2'">Library 2</xsl:when> > > > > Hum? :) > > It's how it is now for OAI XSL. It's not a regression... It won't display > anything except if a Unimarc DB has a branch named MAIN or BIB2. I have removed them.
> I have removed them. Good. Thanks for that, and thanks for the QA.
Pushed to Master - Should be in the May 2016 release. Thanks!