def allocate(self, quantity):
        if self.num_allocated is None:
            self.num_allocated = 0
        self.num_allocated += quantity
        self.save()
Record a stock allocation.
dataset/ETHPy150Open django-oscar/django-oscar/src/oscar/apps/partner/abstract_models.py/AbstractStockRecord.allocate