Fix for web links not being added to current collection

This commit is contained in:
Dan Stillman 2007-03-26 14:56:02 +00:00
parent 13d5d59b01
commit fe23c04b36

View File

@ -1567,18 +1567,14 @@ var ZoteroPane = new function()
progressWin.show(); progressWin.show();
progressWin.startCloseTimer(); progressWin.startCloseTimer();
Zotero.debug('here');
if (this.itemsView && this.itemsView._itemGroup.isCollection()) { if (this.itemsView && this.itemsView._itemGroup.isCollection()) {
Zotero.debug('here2');
var parentCollectionID = this.itemsView._itemGroup.ref.getID(); var parentCollectionID = this.itemsView._itemGroup.ref.getID();
Zotero.debug(parentCollectionID);
} }
} }
var f = function() { var f = function() {
Zotero.debug(parentCollectionID);
if (link) { if (link) {
Zotero.Attachments.linkFromDocument(window.content.document, itemID, false, parentCollectionID); Zotero.Attachments.linkFromDocument(window.content.document, itemID, parentCollectionID);
} }
else { else {
Zotero.Attachments.importFromDocument(window.content.document, itemID, false, parentCollectionID); Zotero.Attachments.importFromDocument(window.content.document, itemID, false, parentCollectionID);