Merge branch 'master' of git.mindplus-dev.ir:sahama/wallet

This commit is contained in:
Sayyid Hamid Mahdavi 2026-02-07 16:18:50 +03:30
commit a5639b5426
2 changed files with 2 additions and 2 deletions

View file

@ -364,7 +364,7 @@ class Transaction(BaseModel):
self.rollback_withdraw_to_payer_balance()
self.change_state(
[StateChoices.PENDING, StateChoices.DELAYED, StateChoices.INCOMPLETE],
StateChoices.SUCCESS,
StateChoices.ROLLED_BACK,
error_message=_('TRANSACTION_STATE_NOT_SUITABLE_FOR_ROLLBACK')
)
return self

View file

@ -18,7 +18,7 @@ from rest_framework.viewsets import ViewSet, GenericViewSet
from apps.wallet.models import Transaction
from django.contrib.postgres.aggregates import ArrayAgg
from django.db.models import Sum, Count, F, StringAgg
from django.db.models import Sum, Count, F
from apps.gooyal_oauth2.rest_framework import IsAuthenticatedOrTokenMatchesOASRequirements
from apps.wallet.models import Transaction, Wallet, Account