Development

This commit is contained in:
Matthew Grotke 2026-05-25 17:26:51 -04:00
parent 6732406a7e
commit d0cfffac52
2 changed files with 11 additions and 11 deletions

View file

@ -9,17 +9,17 @@ bp = Blueprint('action_actions', __name__)
_VIEW = '/view/view_actions' _VIEW = '/view/view_actions'
@bp.route('/action/actions_cardoptions_save', methods=['POST']) @bp.route('/action/actions_cardpending_save', methods=['POST'])
@require_level('administrator') @require_level('administrator')
def actions_cardoptions_save(): def actions_cardpending_save():
session['apply_changes_immediately'] = 'apply_changes_immediately' in request.form session['apply_changes_immediately'] = 'apply_changes_immediately' in request.form
flash('Preference saved.', 'success') flash('Preference saved.', 'success')
return redirect(_VIEW) return redirect(_VIEW)
@bp.route('/action/actions_cardpendingchanges_applynow', methods=['POST']) @bp.route('/action/actions_cardpending_applynow', methods=['POST'])
@require_level('administrator') @require_level('administrator')
def actions_cardpendingchanges_applynow(): def actions_cardpending_applynow():
if not get_dashboard_pending(): if not get_dashboard_pending():
flash('No pending changes to apply.', 'info') flash('No pending changes to apply.', 'info')
return redirect(_VIEW) return redirect(_VIEW)
@ -36,9 +36,9 @@ def actions_cardpendingchanges_applynow():
return redirect(_VIEW) return redirect(_VIEW)
@bp.route('/action/actions_cardpendingchanges_revertselected', methods=['POST']) @bp.route('/action/actions_cardpending_revertselected', methods=['POST'])
@require_level('administrator') @require_level('administrator')
def actions_cardpendingchanges_revertselected(): def actions_cardpending_revertselected():
selected_uuids = request.form.getlist('selected_uuids') selected_uuids = request.form.getlist('selected_uuids')
if not selected_uuids: if not selected_uuids:
flash('No items selected.', 'info') flash('No items selected.', 'info')

View file

@ -608,7 +608,7 @@
"items": [ "items": [
{ {
"type": "form", "type": "form",
"action": "/action/actions_cardpendingchanges_applynow", "action": "/action/actions_cardpending_applynow",
"method": "post", "method": "post",
"items": [ "items": [
{ {
@ -620,13 +620,13 @@
"items": [ "items": [
{ {
"type": "button_primary", "type": "button_primary",
"formaction": "/action/actions_cardpendingchanges_applynow", "formaction": "/action/actions_cardpending_applynow",
"text": "Apply Now", "text": "Apply Now",
"disabled": "%NO_PENDING%" "disabled": "%NO_PENDING%"
}, },
{ {
"type": "button_secondary", "type": "button_secondary",
"formaction": "/action/actions_cardpendingchanges_revertselected", "formaction": "/action/actions_cardpending_revertselected",
"text": "Revert Selected" "text": "Revert Selected"
} }
] ]
@ -638,7 +638,7 @@
}, },
{ {
"type": "form", "type": "form",
"action": "/action/actions_cardoptions_save", "action": "/action/actions_cardpending_save",
"method": "post", "method": "post",
"items": [ "items": [
{ {
@ -654,7 +654,7 @@
"items": [ "items": [
{ {
"type": "button_primary", "type": "button_primary",
"action": "/action/actions_cardoptions_save", "action": "/action/actions_cardpending_save",
"method": "post", "method": "post",
"text": "Save" "text": "Save"
}, },