def Render (self): # Build buttons if self.buttons: self.js_props['buttons'] = self._render_buttons_property() # Render render = Container.Render (self) dialog_props = py2js_dic (self.js_props) div_props = props_to_str (self.props) props = {'id': self.id, 'title': self.title, 'content': render.html, 'dialog_props': dialog_props, 'div_props': div_props, 'cancel_str': _("Cancel"), 'close_str': _("Close")} html = DIALOG_HTML %(props) js = DIALOG_JS %(props) render.html = html render.js += js render.headers += HEADERS return render
def Render (self): id = self.id props = props_to_str (self.props) on_id = self.widget_on.id off_id = self.widget_off.id value = "01"[int(self.active)] # Render embedded images render_on = self.widget_on.Render() render_off = self.widget_off.Render() on_html = render_on.html off_html = render_off.html # Render render = Widget.Render (self) render.html += HTML %(locals()) render.js += JS %(locals()) # Merge the image renders, just in case render_on.html = '' render_off.html = '' render += render_on render += render_off return render
def Render (self): render = Container.Render (self) render.html = HTML %({'id': self.id, 'content': render.html, 'props': props_to_str(self.props)}) return render
def Render(self): id = self.id props = props_to_str(self.props) on_id = self.widget_on.id off_id = self.widget_off.id value = "01"[int(self.active)] # Render embedded widgets render_on = self.widget_on.Render() render_off = self.widget_off.Render() on_html = render_on.html off_html = render_off.html # Render render = Widget.Render(self) render.html += HTML % (locals()) render.js += JS % (locals()) # Merge the image renders, just in case render_on.html = '' render_off.html = '' render += render_on render += render_off return render
def Render (self): # Render the text field html = '<input type="hidden" id="%s" %s/>' %(self.id, props_to_str(self.props)) render = Widget.Render(self) render.html += html return render
def Render (self): render = Widget.Render (self) props = props_to_str (self.props) render.html += HTML %({'id': self.id, 'content': self.content, 'props': props}) return render
def Render(self): # Render the text field html = '<input type="hidden" id="%s" %s/>' % (self.id, props_to_str(self.props)) render = Widget.Render(self) render.html += html return render
def Render (self): render = self.build_func (**self.params) props = {'id': self.id, 'props': props_to_str(self.props), 'content': render.html} render.html = HTML %(props) return render
def Render (self): render = Container.Render (self) props = {'id': self.id, 'tag': self.tag, 'props': props_to_str(self.props), 'content': render.html} render.html = ENTRY_HTML %(props) return render
def Render (self): render = Container.Render (self) props = {'id': self.id, 'href': self.href, 'props': props_to_str(self.props), 'content': render.html} render.html = formater (LINK_HTML, props) return render
def Render (self): render = Widget.Render(self) props = {'id_widget': self.id, 'proxy_url': self._url_local, 'extra_props': util.props_to_str(self.props)} render.html += HTML %(props) render.js += JAVASCRIPT %(props) return render
def Render(self): render = self.build_func(**self.params) props = { 'id': self.id, 'props': props_to_str(self.props), 'content': render.html } render.html = HTML % (props) return render
def Render (self): props = {'id': self.id, 'url': self.url, 'props': props_to_str(self.props), 'content': ''} render = Widget.Render (self) render.html += HTML %(props) render.js += JS_URL_LOAD %(props) render.js += JS_URL_INIT %(props) return render
def Render(self): render = Widget.Render(self) props = props_to_str(self.props) render.html += HTML % ({ 'id': self.id, 'content': self.content, 'props': props }) return render
def Render(self): id = self.id caption = self.caption props = props_to_str(self.props) html = '<button id="%(id)s" %(props)s>%(caption)s</button>' % (locals()) render = Widget.Render(self) render.html += html return render
def Render (self): render = Widget.Render (self) props = {'id': self.id, 'props': props_to_str (self.props)} render.html += HTML %(props) render.js += PERCENT_INIT_JS %(props) render.headers += HEADERS return render
def Render (self): id = self.id caption = self.caption props = props_to_str (self.props) html = '<a id="%(id)s" %(props)s><span>%(caption)s</span></a>' %(locals()) render = Widget.Render (self) render.html += html return render
def render_str (o): if len(o) == 2: name, label = o props = {} elif len(o) == 3: name, label, props = o props_str = props_to_str(props) if selected and str(selected) == str(name): return '<option value="%s" selected="true" %s>%s</option>' % (name, props_str, label) else: return '<option value="%s" %s>%s</option>' % (name, props_str, label)
def Render(self): render = Container.Render(self) props = { 'id': self.id, 'tag': self.tag, 'props': props_to_str(self.props), 'content': render.html } render.html = ENTRY_HTML % (props) return render
def Render(self): id = self.id caption = self.caption props = props_to_str(self.props) html = '<a id="%(id)s" %(props)s><span>%(caption)s</span></a>' % ( locals()) render = Widget.Render(self) render.html += html return render
def Render (self): render = Widget.Render (self) props = {'id': self.id, 'value': self.value, 'props': props_to_str (self.props)} render.html += HTML %(props) render.js += PERCENT_INIT_JS %(props) render.headers += HEADERS return render
def Render(self): render = Widget.Render(self) props = { 'id_widget': self.id, 'proxy_url': self._url_local, 'extra_props': util.props_to_str(self.props) } render.html += HTML % (props) render.js += JAVASCRIPT % (props) return render
def Render(self): id = self.id caption = self.caption props = props_to_str(self.props) html = '<button id="%(id)s" %(props)s>%(caption)s</button>' % ( locals()) render = Widget.Render(self) render.html += html return render
def Render(self): render = Container.Render(self) if self.href: href = 'href="%s"' % (self.href) else: href = "" props = {"id": self.id, "href": href, "props": props_to_str(self.props), "content": render.html} render.html = formatter(LINK_HTML, props) return render
def render_list(o): if len(o) == 2: name, options = o props = {} elif len(o) == 3: name, options, props = o props_str = props_to_str(props) txt = '<optgroup label="%s" %s>' % (name, props_str) for o in options: txt += render_str(o) txt += '</optgroup>' return txt
def Render(self): props = { 'id': self.id, 'url': self.url, 'props': props_to_str(self.props), 'content': '' } render = Widget.Render(self) render.html += HTML % (props) render.js += JS_URL_LOAD % (props) render.js += JS_URL_INIT % (props) return render
def render_list (o): if len(o) == 2: name, options = o props = {} elif len(o) == 3: name, options, props = o props_str = props_to_str(props) txt = '<optgroup label="%s" %s>' %(name, props_str) for o in options: txt += render_str (o) txt += '</optgroup>' return txt
def render_str(o): if len(o) == 2: name, label = o props = {} elif len(o) == 3: name, label, props = o props_str = props_to_str(props) if selected and str(selected) == str(name): return '<option value="%s" selected="true" %s>%s</option>' % ( name, props_str, label) else: return '<option value="%s" %s>%s</option>' % (name, props_str, label)
def Render (self): render = Container.Render (self) if self.href: href = 'href="%s"' %(self.href) else: href = '' props = {'id': self.id, 'href': href, 'props': props_to_str(self.props), 'content': render.html} render.html = formatter (LINK_HTML, props) return render
def Render(self): render = Container.Render(self) if self.href: href = 'href="%s"' % (self.href) else: href = '' props = { 'id': self.id, 'href': href, 'props': props_to_str(self.props), 'content': render.html } render.html = formatter(LINK_HTML, props) return render
def Render(self): render = Container.Render(self) render.html = HTML % ({"id": self.id, "content": render.html, "props": props_to_str(self.props)}) return render