コード例 #1
0
class ManagePoliciesView(BaseLoggedInPage):
    """
    Manage policies page
    """
    policy_profiles = CheckableManageIQTree(tree_id='protectbox')
    breadcrumb = BreadCrumb()  # some views have breadcrumb, some not
    entities = View.nested(BaseNonInteractiveEntitiesView)
    save = Button('Save')
    reset = Button('Reset')
    cancel = Button('Cancel')

    @property
    def is_displayed(self):
        return False
コード例 #2
0
class AlertProfilesEditAssignmentsView(ControlExplorerView):
    title = Text("#explorer_title_text")
    assign_to = BootstrapSelect("chosen_assign_to")
    tag_category = BootstrapSelect("chosen_cat")
    selections = CheckableManageIQTree("obj_treebox")
    header = Text("//div[@id='alert_profile_assign_div']/h3")
    based_on = Text('//label[normalize-space(.)="Based On"]/../div')

    save_button = Button("Save")
    reset_button = Button("Reset")
    cancel_button = Button("Cancel")

    @property
    def is_displayed(self):
        return (self.in_control_explorer
                and self.title.text == 'Alert Profile "{}"'.format(
                    self.context["object"].description)
                and self.header.text == "Assignments"
                and self.based_on == self.context["object"].TYPE)
コード例 #3
0
 class form(View):  # noqa
     policy_profiles = CheckableManageIQTree(tree_id='protectbox')
     entities = View.nested(BaseNonInteractiveEntitiesView)
     save_button = Button('Save')
     reset_button = Button('Reset')
     cancel_button = Button('Cancel')
コード例 #4
0
 class form(View):  # noqa
     policy_profiles = CheckableManageIQTree(tree_id='protectbox')
     save_button = Button('Save')
     reset_button = Button('Reset')
     cancel_button = Button('Cancel')