Ejemplo n.º 1
0
    def __init__(self, item):
        AttributeForwarder.__init__(self, item)

        self.description = item.sellable.get_description()
        self.quantity = item.quantity
        self.cost = item.cost
        self.last_cost = self._get_last_cost(item)
        self.average_cost = self._get_average_cost(item)
Ejemplo n.º 2
0
    def __init__(self, item):
        AttributeForwarder.__init__(self, item)

        self.description = item.sellable.get_description()
        self.quantity = item.quantity
        self.cost = item.cost
        self.last_cost = self._get_last_cost(item)
        self.average_cost = self._get_average_cost(item)
Ejemplo n.º 3
0
    def __init__(self, target, store):
        AttributeForwarder.__init__(self, target)
        self.store = store
        if not target.birth_location:
            target.birth_location = CityLocation.get_default(store)

        self.city = target.birth_location.city
        self.state = target.birth_location.state
        self.country = target.birth_location.country
Ejemplo n.º 4
0
 def __init__(self, target, store):
     """
     :param target: an address
     :param store: a store
     """
     AttributeForwarder.__init__(self, target)
     self.store = store
     self.city = target.city_location.city
     self.state = target.city_location.state
     self.country = target.city_location.country
Ejemplo n.º 5
0
    def __init__(self, target, store):
        """
        :param model: an Individial
        :param store: a store
        """
        AttributeForwarder.__init__(self, target)
        self.store = store
        if not target.birth_location:
            target.birth_location = CityLocation.get_default(store)

        self.city = target.birth_location.city
        self.state = target.birth_location.state
        self.country = target.birth_location.country
Ejemplo n.º 6
0
    def __init__(self, target, store):
        """
        :param model: an Individial
        :param store: a store
        """
        AttributeForwarder.__init__(self, target)
        self.store = store
        if not target.birth_location:
            target.birth_location = CityLocation.get_default(store)

        self.city = target.birth_location.city
        self.state = target.birth_location.state
        self.country = target.birth_location.country
Ejemplo n.º 7
0
    def __init__(self, target, store, ui_form_name=None):
        """
        :param target: an Individial
        :param store: a store
        """
        # Even though we dont use ui_form_name anywhere in this class, its setup
        # is made in a way we need this argument. see persontemplate
        # attach_model_slave method
        AttributeForwarder.__init__(self, target)
        self.store = store
        if not target.birth_location:
            target.birth_location = CityLocation.get_default(store)

        self.city = target.birth_location.city
        self.state = target.birth_location.state
        self.country = target.birth_location.country
Ejemplo n.º 8
0
    def __init__(self, target, store, ui_form_name=None):
        """
        :param target: an Individial
        :param store: a store
        """
        # Even though we dont use ui_form_name anywhere in this class, its setup
        # is made in a way we need this argument. see persontemplate
        # attach_model_slave method
        AttributeForwarder.__init__(self, target)
        self.store = store
        if not target.birth_location:
            target.birth_location = CityLocation.get_default(store)

        self.city = target.birth_location.city
        self.state = target.birth_location.state
        self.country = target.birth_location.country
Ejemplo n.º 9
0
 def __init__(self, target, store):
     AttributeForwarder.__init__(self, target)
     self.store = store
     self.city = target.city_location.city
     self.state = target.city_location.state
     self.country = target.city_location.country