Hello,
I'm trying to enforce the capture of some data on service requests and use that data to mandate certain tasks or fields. This data can be entered either by users (when the SSP is launched in future) or by technicians who are processing the requests. At the moment, 95% of our requests are generated by e-mail and start life as a default incident request.
Here is a simplified example of the Field & Form Rules (FAFR) on my Service Request Template:
On Form Load
Mandate Fields (x2)
- Group
- Resource Question 1 (Checkbox, 2 options)
On Form Submit
Condition: Resource Question 1 is set to 'A'
Action: Set Task 'ABC'
Condition: Resource Question 1 'is empty'
Action: Run script "stopFormSubmission"
And here is the outcome in my use case:
- Request is generated by an e-mail.
- Technician (hopefully) remembers to 'Convert Incident to Service' and selects the template
- Request page is reloaded. Fields "Group" and "Resource Question 1" are now mandatory but are NOT filled in.
Technician attempts to make an edit. The outcome varies depending on how they edit the request, but generally speaking the technician is NOT prompted to fill out an answer to "Resource Question 1". They are only forced to fill in the Group field. The resource area simply says: "Resource(s) are not shown as no questions have been answered."
(One exception: If the technician uses the "Edit" button near the top of the screen (next to Assign and Actions), to edit the entire request. Then the resource panel opens during the edit and an answer is mandatory.)
Is it possible to force the answer of these resource questions? Would I have more luck with custom fields instead of resource questions? They would be enforced like the Group field, without issue.
I feel the resource questions offer a nicer way to present choices. The custom fields tend to get lost amongst the regular fields under the request properties, in my experience. (There is also no checkbox or radio button option for custom fields, only a drop-down.)
One solution might be scripting, though I have no experience of this as yet. But I did find an example script in the script builder that generates a warning dialogue, so perhaps making a script to say "Please fill in the Resource Questions" if they are empty, before stopping the form submission, is one possibility? I hoped it would be possible using the existing FAFR options though.
if(checkDateGreaterThanToday('UDF_DATE1')){
alert('Date cannot be a future date.Choose an earlier date');
$CS.stopFormSubmission();
/*stop form submission*/
Sometimes when you have been looking at something for so long you cannot see the wood for the trees :-)
Update: This code does work to stop ANY edits if the resource question is empty, but I wonder if there is another way to do it? Else the technician may lose the other field changes they were trying to submit...
- alert('Resource section must be completed before making further edits!');
$CS.stopFormSubmission();
Regards,
Martyn