Ejemplo n.º 1
0
class ProductAttributeEditorStep(BaseWizardStep):
    gladefile = 'HolderTemplate'

    def __init__(self, store, wizard, previous):
        BaseWizardStep.__init__(self, store, wizard, previous)

        self.slave = ProductAttributeSlave(self.wizard.store, object())
        self.attach_slave('product_attribute_holder', self.slave, self.place_holder)

    def validate_step(self):
        if len(self.slave.get_selected_attributes()) == 0:
            warning(_("You should select an attribute first"))
            return False
        return True

    def next_step(self):
        self.wizard.attr_list = self.slave.get_selected_attributes()
        return ProductEditorStep(self.wizard.store, self.wizard, previous=self)
Ejemplo n.º 2
0
class ProductAttributeEditorStep(BaseWizardStep):
    gladefile = 'HolderTemplate'

    def __init__(self, store, wizard, previous):
        BaseWizardStep.__init__(self, store, wizard, previous)

        self.slave = ProductAttributeSlave(self.wizard.store, object())
        self.attach_slave('product_attribute_holder', self.slave,
                          self.place_holder)

    def validate_step(self):
        if len(self.slave.get_selected_attributes()) == 0:
            warning(_("You should select an attribute first"))
            return False
        return True

    def next_step(self):
        self.wizard.attr_list = self.slave.get_selected_attributes()
        return ProductEditorStep(self.wizard.store, self.wizard, previous=self)
Ejemplo n.º 3
0
    def __init__(self, store, wizard, previous):
        BaseWizardStep.__init__(self, store, wizard, previous)

        self.slave = ProductAttributeSlave(self.wizard.store, object())
        self.attach_slave('product_attribute_holder', self.slave,
                          self.place_holder)
Ejemplo n.º 4
0
    def __init__(self, store, wizard, previous):
        BaseWizardStep.__init__(self, store, wizard, previous)

        self.slave = ProductAttributeSlave(self.wizard.store, object())
        self.attach_slave('product_attribute_holder', self.slave, self.place_holder)