l.b.b.b.FileBugViewBase(LaunchpadFormView) : class documentation

Part of lp.bugs.browser.bugtarget View In Hierarchy

Known subclasses: lp.bugs.browser.bugtarget.FilebugShowSimilarBugsView, lp.bugs.browser.tests.test_bugtarget_filebug.FileBugViewMixin.FileBugTestView

Base class for views related to filing a bug.
Method __init__ Undocumented
Method initialize Undocumented
Method redirect_ubuntu_filebug Undocumented
Method field_names Return the list of field names to display.
Method default_information_type Undocumented
Method initial_values Give packagename a default value, if applicable.
Method contextIsProduct Undocumented
Method contextIsProject Undocumented
Method targetIsUbuntu Undocumented
Method getPackageNameFieldCSSClass Return the CSS class for the packagename field.
Method validate Make sure the package name, if provided, exists in the distro.
Method setUpWidgets Customize the onKeyPress event of the package name chooser.
Method setUpFields Set up the form fields. See LaunchpadFormView.
Method contextUsesMalone Does the context use Malone as its official bugtracker?
Method contextAllowsNewBugs Undocumented
Method shouldSelectPackageName Should the radio button to select a package be selected?
Method handleSubmitBugFailure Undocumented
Method submit_bug_action Add a bug to this IBugTarget.
Method this_is_my_bug_action Subscribe to the bug suggested.
Method showFileBugForm Override this method in base classes to show the filebug form.
Method inline_filebug_form_url Return the URL to the inline filebug form.
Method duplicate_search_url Return the URL to the inline duplicate search view.
Method publishTraverse See IBrowserPublisher.
Method browserDefault See IBrowserPublisher.
Method getProductOrDistroFromContext Return the product or distribution relative to the context.
Method showOptionalMarker See LaunchpadFormView.
Method getRelevantBugTask Return the first bugtask from this bug that's relevant in the
Method getAcknowledgementMessage An acknowlegement message displayed to the user.
Method extra_data_processing_job Return the ProcessApportBlobJob for a given BLOB token.
Method extra_data_to_process Return True if there is extra data to process.
Method bug_reporting_guidelines Guidelines for filing bugs in the current context.
Method getMainContext Undocumented
Method is_bug_supervisor Return True if the logged in user is a bug supervisor.

Inherited from LaunchpadFormView:

Method render Return the body of the response.
Method extendFields Allow subclasses to extend the form fields.
Method help_links Dictionary mapping field names to help links.
Method adapters Provide custom adapters for use when setting up the widgets.
Method action_url Set the default action URL for the form.
Method has_available_actions Does the view have any available actions that will render?
Method addError Add a form wide error.
Method getFieldError Get the error associated with a particular field.
Method setFieldError Set the error associated with a particular field.
Static Method validate_none Do not do any validation.
Method validate_widgets Validate the named form widgets.
Method error_count Undocumented
Method ajax_failure_handler Called by the form if validate() finds any errors.
Method validate_cancel Noop validation in case we cancel.
Method focusedElementScript Helper function to construct the script element content.
Method isSingleLineLayout Undocumented
Method isMultiLineLayout Undocumented
Method isCheckBoxLayout Undocumented
Method _processNotifications Add any notification messages to the response headers.
Method _abort Abort the form edit.
Method _validate Check all widgets and perform any custom validation.
def __init__(self, context, request):
Undocumented
def initialize(self):
Undocumented
@cachedproperty
def redirect_ubuntu_filebug(self):
Undocumented
@property
def field_names(self):
Return the list of field names to display.
@property
def default_information_type(self):
Undocumented
@property
def initial_values(self):
Give packagename a default value, if applicable.
def contextIsProduct(self):
Undocumented
def contextIsProject(self):
Undocumented
def targetIsUbuntu(self):
Undocumented
def getPackageNameFieldCSSClass(self):
Return the CSS class for the packagename field.
def validate(self, data):
Make sure the package name, if provided, exists in the distro.
def setUpWidgets(self):
Customize the onKeyPress event of the package name chooser.
def setUpFields(self):
Set up the form fields. See LaunchpadFormView.
def contextUsesMalone(self):
Does the context use Malone as its official bugtracker?
def contextAllowsNewBugs(self):
Undocumented
def shouldSelectPackageName(self):
Should the radio button to select a package be selected?
def handleSubmitBugFailure(self, action, data, errors):
Undocumented
@action('Submit Bug Report', 'submit_bug', handleSubmitBugFailure)
def submit_bug_action(self, action, data):
Add a bug to this IBugTarget.
@action("Yes, this is the bug I'm trying to report", 'this_is_my_bug', handleSubmitBugFailure)
def this_is_my_bug_action(self, action, data):
Subscribe to the bug suggested.
def showFileBugForm(self):
Override this method in base classes to show the filebug form.
@property
def inline_filebug_form_url(self):
Return the URL to the inline filebug form.

If a token was passed to this view, it will be passed through to the inline bug filing form via the returned URL.

@property
def duplicate_search_url(self):
Return the URL to the inline duplicate search view.
def publishTraverse(self, request, name):
See IBrowserPublisher.
def browserDefault(self, request):
See IBrowserPublisher.
def getProductOrDistroFromContext(self):
Return the product or distribution relative to the context.
def showOptionalMarker(self, field_name):
See LaunchpadFormView.
def getRelevantBugTask(self, bug):
Return the first bugtask from this bug that's relevant in the current context.

This is a pragmatic function, not general purpose. It tries to find a bugtask that can be used to pretty-up the page, making it more user-friendly and informative. It's not concerned by total accuracy, and will return the first 'relevant' bugtask it finds even if there are other candidates. Be warned!

def getAcknowledgementMessage(self, context):
An acknowlegement message displayed to the user.
@cachedproperty
def extra_data_processing_job(self):
Return the ProcessApportBlobJob for a given BLOB token.
@property
def extra_data_to_process(self):
Return True if there is extra data to process.
@property
def bug_reporting_guidelines(self):
Guidelines for filing bugs in the current context.

Returns a list of dicts, with each dict containing values for "preamble" and "content".

def getMainContext(self):
Undocumented
@cachedproperty
def is_bug_supervisor(self):
Return True if the logged in user is a bug supervisor.
API Documentation for Launchpad, generated by pydoctor at 2019-07-19 00:00:17.