Method: IsoDoc::PresentationXMLConvert#pref_ref_code
- Defined in:
- lib/isodoc/presentation_function/docid.rb
#pref_ref_code(bib) ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/isodoc/presentation_function/docid.rb', line 9 def pref_ref_code(bib) bib["suppress_identifier"] == "true" and return nil ret = bib.xpath(ns("./docidentifier[@scope = 'biblio-tag']")) ret.empty? or return ret.map { |x| to_xml(x.children) } ret = pref_ref_code_parse(bib) or return nil ins = bib.at(ns("./docidentifier[last()]")) ret.reverse_each do |r| ins.next = "<docidentifier scope='biblio-tag'>#{docid_l10n(r)}</docidentifier>" end ret end |