Details
-
Type:
Bug
-
Status: In Review
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 5.13.4
-
Fix Version/s: 5.13.5
-
Component/s: Staff Interface
-
Labels:None
Description
Context
When canceling a pending service change on Tools > Service Queue > Changes tab, checking the "Void Invoice" checkbox and clicking Cancel does not actually void the invoice. The service change is canceled, but the invoice remains unchanged.
Root cause: The JavaScript initialization for the confirmation modal on line 178 of the view is missing submit: true. Without it, blestaModalConfirm navigates via GET (window.location
= href) instead of submitting the parent <form>. Since the void_invoice checkbox is a form field, its value is lost on a GET navigation. The controller reads $this->post['void_invoice'] which is always null on a GET request, so $void_invoice is always false.
Every other form-based blestaModalConfirm call in the codebase (37+ instances) correctly passes submit: true.
Fix
File: public_html/app/views/admin/default/admin_tools_provisioning.pdt — line 178
Change the blestaModalConfirm initialization to conditionally pass submit: true when on the "changes" tab (where Cancel/Retry links live inside <form> elements). On other tabs,
"Dequeue" links are plain <a> tags with no parent form, so they must keep the current GET-based behavior.
// Before (line 178):
$('#admin_tools_provisioning a.manage[rel]').blestaModalConfirm({base_url: '...', close: '...'});
// After:
<?php if (($category ?? null) == 'changes') { ?> $('#admin_tools_provisioning a.manage[rel]').blestaModalConfirm({base_url: '...', close: '...', submit: true}); <?php } else { ?> $('#admin_tools_provisioning a.manage[rel]').blestaModalConfirm({base_url: '...', close: '...'}); <?php } ?>
This ensures:
- Changes tab: Form is submitted via POST, including the void_invoice checkbox value
- Other tabs: Dequeue link continues to work via GET navigation (no parent form)
No changes needed to the controller or model — they already handle void_invoice correctly when it arrives via POST.
Files to modify
1. public_html/app/views/admin/default/admin_tools_provisioning.pdt — line 178 only
Verification
1. Navigate to Tools > Service Queue > Changes tab
2. Find a pending service change with an associated invoice
3. Check the "Void Invoice" checkbox, click "Cancel", confirm in the modal
4. Verify the service change status becomes "canceled" AND the invoice status becomes "void"
5. Also verify the other tabs still work — click "Dequeue" on a renewal/provision tab and confirm it still dequeues correctly
Activity
| Field | Original Value | New Value |
|---|---|---|
| Remaining Estimate | 0 minutes [ 0 ] | |
| Time Spent | 56 minutes [ 3360 ] | |
| Worklog Id | 18128 [ 18128 ] |
| Assignee | Abdy Franco [ abdy ] |
| Status | Open [ 1 ] | In Review [ 5 ] |
| Resolution | Fixed [ 1 ] |