Projet

Général

Profil

0003-workflows-add-markup-to-give-table-cell-widgets-thei.patch

Frédéric Péters, 06 juin 2016 23:17

Télécharger (1,18 ko)

Voir les différences:

Subject: [PATCH 3/5] workflows: add markup to give table cell widgets their
 classes (#11071)

 wcs/qommon/form.py | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
wcs/qommon/form.py
430 430
        r = TemplateIO(html=True)
431 431
        r += htmltext('<tr>\n')
432 432
        for widget in self.get_widgets():
433
            r += htmltext('<td>')
433
            classnames = '%s widget' % widget.__class__.__name__
434
            if hasattr(self, 'extra_css_class') and widget.extra_css_class:
435
                classnames += ' ' + widget.extra_css_class
436
            r += htmltext('<td><div class="%s"><div class="content">' % classnames)
434 437
            r += widget.render_content()
435
            r += htmltext('</td>')
438
            r += htmltext('</div></div></td>')
436 439
        r += htmltext('</tr>\n')
437 440
        return r.getvalue()
438 441

  
439
-