web/views/formrenderers.py
changeset 3398 d84b0176452c
parent 3396 fb261afd49cd
child 3451 6b46d73823f5
equal deleted inserted replaced
3397:a35c6ae5bef2 3398:d84b0176452c
    14 
    14 
    15 from cubicweb.common import tags
    15 from cubicweb.common import tags
    16 from cubicweb.appobject import AppObject
    16 from cubicweb.appobject import AppObject
    17 from cubicweb.selectors import entity_implements, yes
    17 from cubicweb.selectors import entity_implements, yes
    18 from cubicweb.web import eid_param, formwidgets as fwdgs
    18 from cubicweb.web import eid_param, formwidgets as fwdgs
    19 from cubicweb.web.widgets import checkbox
       
    20 
    19 
    21 def checkbox(name, value, attrs='', checked=None):
    20 def checkbox(name, value, attrs='', checked=None):
    22     if checked is None:
    21     if checked is None:
    23         checked = value
    22         checked = value
    24     checked = checked and 'checked="checked"' or ''
    23     checked = checked and 'checked="checked"' or ''