Hi Tammy,
Yes, sorry for not including the implementation steps. It does matter where you put the code. Follow the steps below to implement this.
1. Open WSP then find the detail_in form (there may be more than one depending on how you have your roles configured)
2. Switch to the source tab
3. Find the following line
<PDM_MACRO name=dtlDropdown hdr="Status" attr=status factory=crs_in>
4. Replace it with this code
//Conditionally set status to read-only if the ticket was closed more than 30 days ago
var zNow = Number(Math.round(new Date().getTime() / 1000));
var zClose_Date = Number("$args.close_date_INT_DATE");
console.log("Close Date: " + zClose_Date + "\nNow: " + zNow + "\nClose Date plus 30 days <= Now: " + ((zClose_Date + 2592000) <= zNow));
if((zClose_Date + 2592000) <= zNow && "$args.status" == "CL" && "$cst.access_type.sym" != "Administration"){
<PDM_MACRO name=dtlReadonly hdr="Status" attr=status>
}
else{
<PDM_MACRO name=dtlDropdown hdr="Status" attr=status factory=crs_in>
}
5. Save and Publish