Add description attribute for advanced search

This commit is contained in:
Frederic Guillot
2015-06-28 21:04:37 -04:00
parent 2e7e703180
commit 7c1222fc59
5 changed files with 80 additions and 16 deletions

View File

@@ -29,7 +29,7 @@ class Lexer
"/^(color:)/" => 'T_COLOR',
"/^(due:)/" => 'T_DUE',
"/^(status:)/" => 'T_STATUS',
"/^(title:)/" => 'T_TITLE',
"/^(description:)/" => 'T_DESCRIPTION',
"/^(\s+)/" => 'T_WHITESPACE',
'/^([<=>]{0,2}[0-9]{4}-[0-9]{2}-[0-9]{2})/' => 'T_DATE',
'/^(yesterday|tomorrow|today)/' => 'T_DATE',
@@ -117,6 +117,7 @@ class Lexer
case 'T_STATUS':
case 'T_DUE':
case 'T_DESCRIPTION':
$next = next($tokens);
if ($next !== false && ($next['token'] === 'T_DATE' || $next['token'] === 'T_STRING')) {