Merge branch 'main' into storefront-nuxt
This commit is contained in:
commit
48e3380cd0
1 changed files with 5 additions and 6 deletions
|
|
@ -125,8 +125,7 @@ def process_order_changes(instance: Order, created: bool, **kwargs: dict[Any, An
|
|||
|
||||
if has_file:
|
||||
order_product.status = "FINISHED"
|
||||
if not order_product.download:
|
||||
DigitalAssetDownload.objects.create(order_product=order_product)
|
||||
DigitalAssetDownload.objects.get_or_create(order_product=order_product)
|
||||
order_product.order.user.payments_balance.amount -= order_product.buy_price # type: ignore [union-attr, operator]
|
||||
order_product.order.user.payments_balance.save() # type: ignore [union-attr]
|
||||
order_product.save()
|
||||
|
|
|
|||
Loading…
Reference in a new issue