lib/bolognese/datacite_json.rb in bolognese-0.8.5 vs lib/bolognese/datacite_json.rb in bolognese-0.8.7
- old
+ new
@@ -33,10 +33,18 @@
def type
DC_TO_SO_TRANSLATIONS[resource_type_general.to_s.dasherize] || "CreativeWork"
end
+ def citeproc_type
+ DC_TO_CP_TRANSLATIONS[resource_type_general.to_s.dasherize] || "other"
+ end
+
+ def ris_type
+ SO_TO_RIS_TRANSLATIONS[resource_type_general.to_s.dasherize] || "GEN"
+ end
+
def additional_type
metadata.fetch("resource-type", nil)
end
def bibtex_type
@@ -58,10 +66,10 @@
def license
metadata.fetch("license", nil)
end
def keywords
- metadata.fetch("subject", nil)
+ Array.wrap(metadata.fetch("subject", nil)).join(", ").presence
end
def author
metadata.fetch("creator", nil)
end