feat: Prumo tells the card and the customer what it did (front 6)
All checks were successful
Build and deploy / Validate source (push) Successful in 5s
Build and deploy / Integration suite on a real stack (push) Successful in 4m41s
Build and deploy / Secret scan and release gate (push) Successful in 6s
Build and deploy / Publish images (push) Successful in 1m6s
All checks were successful
Build and deploy / Validate source (push) Successful in 5s
Build and deploy / Integration suite on a real stack (push) Successful in 4m41s
Build and deploy / Secret scan and release gate (push) Successful in 6s
Build and deploy / Publish images (push) Successful in 1m6s
Every order now carries a short report of the decisions that happened: original format, conversion, resolution, background, residue, montage, billed length, contraction, thin-stroke warning, parts and generation time. The card shows it above the file; the payment summary shows the customer's version. The upload keeps the original name so a renamed CDR/PDF is told.
This commit is contained in:
@@ -32,6 +32,7 @@ if os.environ.get('FREIGHT_ADAPTER') == 'jadlog':
|
||||
from .jadlog import JadlogFreight
|
||||
_carriers.append(JadlogFreight())
|
||||
from . import correios as _correios
|
||||
from . import prumo
|
||||
if _correios.configured():
|
||||
_carriers.append(_correios.CorreiosFreight())
|
||||
freight = FreightOptions(_carriers or [FakeFreight()])
|
||||
@@ -132,8 +133,10 @@ def quote_view(c, row, order=None, attempt=None, known=False):
|
||||
from .payment_messages import rejection
|
||||
attempt = {**attempt, 'message': rejection(attempt['status_detail'])}
|
||||
expired = row['approved_at'] and row['approved_at'] < datetime.now(timezone.utc)-timedelta(hours=24)
|
||||
items = (row['approved'] or row['draft']).get('items') or []
|
||||
return {'id': row['id'], 'created_at': row['created_at'],
|
||||
'draft': row['draft'], 'approved': row['approved'],
|
||||
'prumo': prumo.customer_summary(items),
|
||||
'status': 'paid' if order else 'discarded' if row.get('discarded_at') else 'expired' if expired
|
||||
else 'approved' if row['approved'] else 'pending_review',
|
||||
'auto_approved': row.get('reviewed_by') == 'auto',
|
||||
|
||||
Reference in New Issue
Block a user