Add lastName search condition (API only, not in the search UI)

This commit is contained in:
Dan Stillman 2009-04-04 20:52:44 +00:00
parent 24654a8bce
commit f9f6e5340c

View file

@ -1150,6 +1150,7 @@ Zotero.Search.prototype._buildQuery = function(){
break;
case 'creator':
case 'lastName':
condSQL += "creatorID IN (SELECT creatorID FROM creators "
+ "NATURAL JOIN creatorData WHERE ";
openParens++;
@ -1822,6 +1823,19 @@ Zotero.SearchConditions = new function(){
field: "firstName || ' ' || lastName"
},
{
name: 'lastName',
operators: {
is: true,
isNot: true,
contains: true,
doesNotContain: true
},
table: 'itemCreators',
field: 'lastName',
special: true
},
{
name: 'field',
operators: {