feat: the pickup receipt in Recibos/ and "Retirado" on the card (Dropstar's third round, item 14)
All checks were successful
Build and deploy / Validate source (push) Successful in 4s
Build and deploy / Integration suite on a real stack (push) Successful in 3m38s
Build and deploy / Secret scan and release gate (push) Successful in 5s
Build and deploy / Publish images (push) Successful in 59s
All checks were successful
Build and deploy / Validate source (push) Successful in 4s
Build and deploy / Integration suite on a real stack (push) Successful in 3m38s
Build and deploy / Secret scan and release gate (push) Successful in 5s
Build and deploy / Publish images (push) Successful in 59s
A pickup order reaching Finalizado has its receipt due: a PDF for the 80 mm roll with the order number large at the top, the customer and CPF/CNPJ, each product and its metres, the amount and how it was paid, the date issued, and the "Retirado em" and "Assinatura" lines (app/receipt.py). The Kanban's folder saves it in Recibos/, where the counter's print queue sends it to the Bematech. One computer claims each receipt on the server before writing it, so it is never printed twice, and gives it back if it could not save it. Orders sent by carrier have none. "Retirado" on a pickup in Finalizado records when and who handed it over, with an optional photo of the signed receipt (kept 30 days). Anyone but the seller may mark it (new "deliver" capability); the order panel also opens the receipt to print it again. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -28,16 +28,18 @@ def begin_final(oid: UUID, body: UploadStart, user=Depends(can('produce'))):
|
||||
def final_status(uid: UUID, user=Depends(operator)):
|
||||
return upload_status(uid,session_id=operator_identity(user))
|
||||
|
||||
# The parts of an upload its operator started: a final (produce) or the
|
||||
# photo of a signed pickup receipt (deliver, which includes produce).
|
||||
@router.post('/api/operator/uploads/{uid}/parts/{number}')
|
||||
def final_part(uid: UUID, number: int, user=Depends(can('produce'))):
|
||||
def final_part(uid: UUID, number: int, user=Depends(can('deliver'))):
|
||||
return part_url(uid,number,session_id=operator_identity(user))
|
||||
|
||||
@router.post('/api/operator/uploads/{uid}/complete')
|
||||
def final_complete(uid: UUID, user=Depends(can('produce'))):
|
||||
def final_complete(uid: UUID, user=Depends(can('deliver'))):
|
||||
return complete_upload(uid,session_id=operator_identity(user))
|
||||
|
||||
@router.delete('/api/operator/uploads/{uid}')
|
||||
def final_cancel(uid: UUID, user=Depends(can('produce'))):
|
||||
def final_cancel(uid: UUID, user=Depends(can('deliver'))):
|
||||
return cancel_upload(uid,session_id=operator_identity(user))
|
||||
|
||||
@router.get('/api/operator/orders/{oid}/files')
|
||||
|
||||
Reference in New Issue
Block a user