mirror of
https://github.com/pretix/pretix.git
synced 2026-05-03 14:54:04 +00:00
Refactor cancelling positions and orders in the data model (#1088)
- [x] Data model - [x] display in order view in backend - [x] review all usages of OrderPositions.objects - [x] review all usages of order.positions - [x] review all other model usages - [x] review plugins - [x] plugins backwards-compatible API? - [x] decide on way forward for REST API - [x] need to cancel fees - [x] tests - [ ] plugins - [ ] gdpr - [ ] reports - [x] docs
This commit is contained in:
@@ -162,7 +162,7 @@ def test_retry_refunded(env, client):
|
||||
state=BankTransaction.STATE_ERROR,
|
||||
amount=23, date='unknown', order=env[3])
|
||||
client.login(email='dummy@dummy.dummy', password='dummy')
|
||||
env[3].status = Order.STATUS_REFUNDED
|
||||
env[3].status = Order.STATUS_CANCELED
|
||||
env[3].save()
|
||||
r = json.loads(client.post('/control/event/{}/{}/banktransfer/action/'.format(env[0].organizer.slug, env[0].slug), {
|
||||
'action_{}'.format(trans.pk): 'retry',
|
||||
@@ -171,7 +171,7 @@ def test_retry_refunded(env, client):
|
||||
trans.refresh_from_db()
|
||||
assert trans.state == BankTransaction.STATE_ERROR
|
||||
env[3].refresh_from_db()
|
||||
assert env[3].status == Order.STATUS_REFUNDED
|
||||
assert env[3].status == Order.STATUS_CANCELED
|
||||
|
||||
|
||||
@pytest.mark.django_db
|
||||
|
||||
Reference in New Issue
Block a user