Changeset 6551 for main/waeup.sirp/trunk
- Timestamp:
- 23 Jul 2011, 15:14:15 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/accesscodes/catalog.py
r6549 r6551 40 40 return 41 41 hitlist = [] 42 try: 43 if searchtype == 'history': 44 results = Query().searchResults( 45 Text(('accesscodes_catalog', searchtype), query)) 46 elif searchtype == 'batch_serial': 47 results = Query().searchResults( 48 Eq(('accesscodes_catalog', searchtype), int(query))) 49 else: 50 results = Query().searchResults( 51 Eq(('accesscodes_catalog', searchtype), query)) 52 for result in results: 53 hitlist.append(AccessCodeQueryResultItem(result, view=view)) 54 except ParseError: 55 view.flash('Search string not allowed.') 56 return 42 if searchtype == 'history': 43 results = Query().searchResults( 44 Text(('accesscodes_catalog', searchtype), query)) 45 elif searchtype == 'batch_serial': 46 results = Query().searchResults( 47 Eq(('accesscodes_catalog', searchtype), int(query))) 48 else: 49 results = Query().searchResults( 50 Eq(('accesscodes_catalog', searchtype), query)) 51 for result in results: 52 hitlist.append(AccessCodeQueryResultItem(result, view=view)) 57 53 return hitlist 58 59
Note: See TracChangeset for help on using the changeset viewer.