Prevent items in group libraries from being added to My Publications
And remove existing group items that have been added
This commit is contained in:
parent
3561864542
commit
2eef1702e0
5 changed files with 35 additions and 24 deletions
|
@ -376,6 +376,15 @@ describe("Zotero.Item", function () {
|
|||
assert.ok(e);
|
||||
assert.include(e.message, "Linked-file attachments cannot be added to My Publications");
|
||||
});
|
||||
|
||||
it("should be invalid for group library items", function* () {
|
||||
var group = yield getGroup();
|
||||
var item = yield createDataObject('item', { libraryID: group.libraryID });
|
||||
item.inPublications = true;
|
||||
var e = yield getPromiseError(item.saveTx());
|
||||
assert.ok(e);
|
||||
assert.equal(e.message, "Only items in user libraries can be added to My Publications");
|
||||
});
|
||||
});
|
||||
|
||||
describe("#parentID", function () {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue