l.a.b.l.BooleanChoiceWidget(WidgetBase, DefinedTagMixin) : class documentation

Part of lp.app.browser.lazrjs View In Hierarchy

A ChoiceEdit for a boolean field.
Method __init__ Create a widget wrapper.
Method value Undocumented
Method config Undocumented
Method json_config Undocumented

Inherited from WidgetBase:

Method resource_uri A local path to the context object.
Method json_resource_uri Undocumented
Method can_write Can the current user write to the attribute.

Inherited from DefinedTagMixin:

Method open_tag Undocumented
Method close_tag Undocumented
def __init__(self, context, exported_field, tag, false_text, true_text, css_class=None, prefix=None, edit_view='+edit', edit_url=None, edit_title='', content_box_id=None, header='Select an item'):
Create a widget wrapper.
ParameterscontextThe object that is being edited.
exported_fieldThe attribute being edited. This should be a field from an interface of the form ISomeInterface['fieldname']
tagThe HTML tag to use.
false_textThe string to show for a false value.
true_textThe string to show for a true value.
css_classThe css class value to use.
prefixOptional text to show before the value.
edit_viewThe view name to use to generate the edit_url if one is not specified.
edit_urlThe URL to use for editing when the user isn't logged in and when JS is off. Defaults to the edit_view on the context.
edit_titleUsed to set the title attribute of the anchor.
content_box_idThe HTML id to use for this widget. Automatically generated if this is not provided.
headerThe large text at the top of the choice popup.
@property
def value(self):
Undocumented
@property
def config(self):
Undocumented
@property
def json_config(self):
Undocumented
API Documentation for Launchpad, generated by pydoctor at 2022-06-16 00:00:12.