fix upgrading of documents with non-page locatorType
This commit is contained in:
parent
ecd6309fbc
commit
09ff9ec083
1 changed files with 4 additions and 1 deletions
|
@ -1260,7 +1260,10 @@ Zotero.Integration.Session.prototype.unserializeCitation = function(arg, index)
|
||||||
// for upgrade from Zotero 2.0 or earlier
|
// for upgrade from Zotero 2.0 or earlier
|
||||||
for each(var citationItem in citation.citationItems) {
|
for each(var citationItem in citation.citationItems) {
|
||||||
if(citationItem.locatorType) {
|
if(citationItem.locatorType) {
|
||||||
citationItem.label = citationItem.locatorType;
|
const locatorTypeTerms = ["page", "book", "chapter", "column", "figure", "folio",
|
||||||
|
"issue", "line", "note", "opus", "paragraph", "part", "section", "sub verbo",
|
||||||
|
"volume", "verse"];
|
||||||
|
citationItem.label = locatorTypeTerms[citationItem.locatorType];
|
||||||
delete citationItem.locatorType;
|
delete citationItem.locatorType;
|
||||||
} else if(citationItem.suppressAuthor) {
|
} else if(citationItem.suppressAuthor) {
|
||||||
citationItem["suppress-author"] = citationItem["suppressAuthor"];
|
citationItem["suppress-author"] = citationItem["suppressAuthor"];
|
||||||
|
|
Loading…
Reference in a new issue