Button to move policy exception back to draft when it expires
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
Hello,
I am trying to create a UI Action button that will appear when a policy exception expires and allow the user to move the policy exception record back to the 'New' state. I am unsure of how to do this as there is no expired state for the policy exception record there is only an Expired substate which is driven by the extensions. I do not want the button to be based on extensions. I also tried using a condition on the 'Valid to' field but this did not work because when the valid to date passes a new date must be input before being allowed to press any buttons or save the record. If anyone has done this or something similar before please let me know how I can achieve this.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Hi @MarisaW81535484 ,
- Make the button appear only when the record’s “Valid to” date is already past.
(current.valid_to < gs.now())
- When clicked, the button resets the record’s state back to “New” and clears the expired substate.
current.state = 'new'; // or the actual value for "New"
current.substate = ''; // clear expired substate
current.update();
action.setRedirectURL(current);
- If needed, also clear the “Valid to” field so the system doesn’t block saving
current.valid_to = '';
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
41m ago
We have something similar. We provide user to Request extension when the exception is about to expire in 30 days or has expired. When they request extension, we provide them another record producer UI to enter the new plan and dates. Once they submit, it again goes for the usual approval process. We have a customized a lot, so may not match to the OOB flow.
Please mark this response as correct or helpful if it assisted you with your question.
