comparison roundup/cgi/KeywordsExpr.py @ 5132:0142b4fb5a2d

issue2550648 - partial fix for problem in this issue. Ezio Melotti reported that the expression editor allowed the user to generate an expression using retired values. To align the expression editor with the simple dropdown search item, retired values are now removed from the expression editor. Do we really want this though? Supposed a keyword is retired and I want to search for an issue with that retired keyword? Do we have a best policy document that says to remove retired keywords from all places it could possibly be used? It could be argued that the simple search dropdown is wrong and should allow selecting retired values.
author John Rouillard <rouilj@ieee.org>
date Fri, 08 Jul 2016 19:31:02 -0400
parents e46b15b0bc25
children 17b213eab274
comparison
equal deleted inserted replaced
5131:513803cade0a 5132:0142b4fb5a2d
243 243
244 def list_nodes(request): 244 def list_nodes(request):
245 prop = request.form.getfirst("property") 245 prop = request.form.getfirst("property")
246 cls = request.client.db.getclass(prop) 246 cls = request.client.db.getclass(prop)
247 items = [] 247 items = []
248 for nodeid in cls.getnodeids(): 248 for nodeid in cls.getnodeids(retired=0):
249 l = cls.getnode(nodeid).items() 249 l = cls.getnode(nodeid).items()
250 l = dict([x for x in l if len(x) == 2]) 250 l = dict([x for x in l if len(x) == 2])
251 try: 251 try:
252 items.append((l['id'], l['name'])) 252 items.append((l['id'], l['name']))
253 except KeyError: 253 except KeyError:

Roundup Issue Tracker: http://roundup-tracker.org/