Fix nested form breaking Mark Paid & Deliver button
This commit is contained in:
parent
8175327ce3
commit
0c79984619
2 changed files with 6 additions and 10 deletions
2
app.py
2
app.py
|
|
@ -1142,6 +1142,8 @@ def admin_request(rid):
|
|||
|
||||
elif action == 'mark_paid_deliver':
|
||||
# Finalize: record Square payment ref, attach approved MP3s, email customer.
|
||||
# Also capture the deliver_wav checkbox from the same form.
|
||||
update_request(rid, deliver_wav=1 if request.form.get('deliver_wav') else 0)
|
||||
if req.get('customer_approved', 'none') == 'none':
|
||||
flash('Customer must approve a version before you can mark paid or deliver.', 'error')
|
||||
return redirect(url_for('admin_request', rid=rid))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue