Ejemplo n.º 1
0
 def buttons_line(self):
     buttons = self.layout.get('buttons', self.form.get_buttons())
     button_offset = self.layout.get('button_offset', self.label_width)
     buf = Div(_class='form-group')
     if button_offset:
         with buf:
             with buf.div(_class="col-sm-offset-%d col-sm-%d" % (button_offset, 12-button_offset)):
                 buf << buttons
     else:
         with buf:
             buf << buttons
     return str(buf)