helpers: bool2icon will expose title of values as tooltip.

This commit is contained in:
Marcin Kuzminski 2019-10-22 19:56:49 +02:00
parent ba9f6d58e3
commit 0073ec35de

View file

@ -977,10 +977,10 @@ def bool2icon(value, show_at_false=True):
"""
if value: # does bool conversion
return HTML.tag('i', class_="icon-true")
return HTML.tag('i', class_="icon-true", title='True')
else: # not true as bool
if show_at_false:
return HTML.tag('i', class_="icon-false")
return HTML.tag('i', class_="icon-false", title='False')
return HTML.tag('i')
#==============================================================================