def jsdatetimePreview(request): field = JSDateTimeField( 'JSDateTimeField', title = 'Bootstrap DateTime field', description = 'Bootstrap DateTime field preview description') widget = field.bind(request, 'preview.', datetime.datetime.now(), {}) widget.update() return widget.render_widget()
def _makeOne(self, **kw): from ptah.jsfields import JSDateTimeField return JSDateTimeField('test', **kw)