0
I Need Help for this Script.
if Status = 2 then
let reply := dialog(" Major - Non Conformities", " This Audit was not compliant therefore within 14 days the major non conformities will be reviewed ", ["Confirmed", "No Confirmed"]);
void
else
if Status = 3 then
let reply := dialog(" 🟠 Minor - Non Conformities", " This Audit was not compliant therefore within 7 days the major non conformities will be reviewed ", ["Confirmed", "No Confirmed"]);
if reply = "Confirmed" then
let today := Today;
let newRecord := duplicate(this);
openRecord(newRecord);
newRecord.('Audit Code' := null);
newRecord.(Status := null);
newRecord.(From := null);
newRecord.(Appointment := null);
newRecord.(today := 'Re Schedule Date')
end
end
end
OK what I need, when select the Major non Conformity need place on field ' Re Schedule Date' 14 days more on Today (21 Mar 2024), and if select the Minor non Conformity need to place 7 days more on Today. (14 Mar 2024)
The other thinks the two if only work the Status = 3 the status = 2 don't work ?
Thanks
3 replies
-
if Status = 2 then let reply := dialog(" Major - Non Conformities", "This Audit was not compliant. Therefore, major non-conformities will be reviewed within 14 days.", ["Confirmed", "No Confirmed"]); if reply = "Confirmed" then let today := Today + 14; let newRecord := duplicate(this); openRecord(newRecord); newRecord.('Audit Code' := null); newRecord.(Status := null); newRecord.(From := null); newRecord.(Appointment := null); newRecord.(today := 'Re Schedule Date') end else if Status = 3 then let reply := dialog("🟠 Minor - Non Conformities", "This Audit was not compliant. Therefore, minor non-conformities will be reviewed within 7 days.", ["Confirmed", "No Confirmed"]); if reply = "Confirmed" then let today := Today + 7; let newRecord := duplicate(this); openRecord(newRecord); newRecord.('Audit Code' := null); newRecord.(Status := null); newRecord.(From := null); newRecord.(Appointment := null); newRecord.(today := 'Re Schedule Date') end end end
Resolved the if statement, but no the today to Reschedule Date.
Content aside
- Status Answered
- 9 mths agoLast active
- 3Replies
- 46Views
-
2
Following