Hi all, I have a container number and a function that check the number is valid. The result of the function is store in field cntnumok (boolean). I found that we can change the color with "represent" and found an example in webgroup.
db.articles.conteneur.represent = lambda v, row: SPAN(v, _class='cnt-false' if db.articles.cntnumok==False else None) I understand lambda is an inline function, i want that the if test the value of "cntnumok" for the row How can i have the value of "cntnumok" for the row? I tried this also db.articles.conteneur.represent = lambda v, row: SPAN(v,_class='cnt-false' if row.cntnumok==False else None) Yann -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.