def render(self, **kwargs): filter_by = self.jq_options.get('filter_by') if self.raw_value: label = getattr(self.raw_value, filter_by, u'Not selected') else: label = u'' html = h.radio_button(self.name, value=self.value, **kwargs) html += h.label(label) return ''.join(html)
def render(self, **kwargs): fanstatic_resources.fa_pyramid_js.need() filter_by = self.jq_options.get('filter_by') if self.raw_value: label = getattr(self.raw_value, filter_by, u'Not selected') else: label = u'' html = h.radio_button(self.name, value=self.value, **kwargs) html += h.label(label) return ''.join(html)
def render(self, **kwargs): fanstatic_resources.autocomplete.need() filter_by = self.jq_options.get('filter_by') if self.raw_value: label = getattr(self.raw_value, filter_by, u'Not selected') else: label = u'' radio = h.radio_button(self.name, value=self.value, **kwargs) radio += h.literal(' ') radio += h.content_tag('span', label) children = h.content_tag("span", radio, class_="add-on") html = h.content_tag("div", children, class_="input-prepend") return ''.join(html)