Updated obsolete references to itemKeywords table to use itemTags (this was breaking item delete and search)
This commit is contained in:
parent
3a3b6ab70d
commit
e45520b871
1 changed files with 3 additions and 3 deletions
|
@ -1025,7 +1025,7 @@ Scholar.Item.prototype.erase = function(){
|
||||||
|
|
||||||
sql = 'DELETE FROM itemCreators WHERE itemID=' + this.getID() + ";\n";
|
sql = 'DELETE FROM itemCreators WHERE itemID=' + this.getID() + ";\n";
|
||||||
sql += 'DELETE FROM itemNotes WHERE itemID=' + this.getID() + ";\n";
|
sql += 'DELETE FROM itemNotes WHERE itemID=' + this.getID() + ";\n";
|
||||||
sql += 'DELETE FROM itemKeywords WHERE itemID=' + this.getID() + ";\n";
|
sql += 'DELETE FROM itemTags WHERE itemID=' + this.getID() + ";\n";
|
||||||
sql += 'DELETE FROM itemData WHERE itemID=' + this.getID() + ";\n";
|
sql += 'DELETE FROM itemData WHERE itemID=' + this.getID() + ";\n";
|
||||||
sql += 'DELETE FROM items WHERE itemID=' + this.getID() + ";\n";
|
sql += 'DELETE FROM items WHERE itemID=' + this.getID() + ";\n";
|
||||||
|
|
||||||
|
@ -1351,8 +1351,8 @@ Scholar.Items = new function(){
|
||||||
+ "SELECT itemID FROM itemCreators WHERE creatorID IN "
|
+ "SELECT itemID FROM itemCreators WHERE creatorID IN "
|
||||||
+ "(SELECT creatorID FROM creators WHERE firstName LIKE ?1 "
|
+ "(SELECT creatorID FROM creators WHERE firstName LIKE ?1 "
|
||||||
+ "OR lastName LIKE ?1) UNION "
|
+ "OR lastName LIKE ?1) UNION "
|
||||||
+ "SELECT itemID FROM itemKeywords WHERE keywordID IN "
|
+ "SELECT itemID FROM itemTags WHERE tagID IN "
|
||||||
+ "(SELECT keywordID FROM keywords WHERE keyword LIKE ?1) UNION "
|
+ "(SELECT tagID FROM tags WHERE tag LIKE ?1) UNION "
|
||||||
+ "SELECT itemID FROM itemNotes WHERE note LIKE ?1";
|
+ "SELECT itemID FROM itemNotes WHERE note LIKE ?1";
|
||||||
|
|
||||||
var sqlParams = [{'string':'%' + text + '%'}];
|
var sqlParams = [{'string':'%' + text + '%'}];
|
||||||
|
|
Loading…
Reference in a new issue