我们从Python开源项目中,提取了以下1个代码示例,用于说明如何使用django.forms.widgets.RadioChoiceInput()。
def patch(): from django.forms import forms, formsets, util, widgets # Add __html__ methods to these classes: classes = [ forms.BaseForm, forms.BoundField, formsets.BaseFormSet, util.ErrorDict, util.ErrorList, widgets.Media, widgets.RadioFieldRenderer, ] try: classes.append(widgets.RadioChoiceInput) except AttributeError: classes.append(widgets.RadioInput) for cls in classes: if not hasattr(cls, '__html__'): cls.__html__ = __html__