Jump to content
Sign in to follow this  

Set Priority based on Need By Date on Change Orders

Recommended Posts

Hello.  I've never customized Service Desk Manager web forms before and could use some guidance.  My ultimate goal is to ...

1) Detect when the value of the "Need By Date" of a Change Order is updated.

2) Based on the number of days difference between the system date/time and the value of the "Need By Date", set the Priority to a specific value.


Pertaining to a copy of the detail.chg.htpml file, here is what I've done so far ...

1) In the section of the code where all the PDM_MACRO lines are, I added the following code to invoke a function when the value of "Need By Date" changes.

<PDM_MACRO name=dtlDate hdr="Need By Date" attr=need_by evt="onChange=\\\"set_priority_using_need_by_date()\\\"">

2) Next, in the java script section, I added a new function to test if I could invoke it.  Here is my test code.

function set_priority_using_need_by_date()
 showAlertMessage("Function Invoked", true);

I then backed up the current htpml file in the analyst folder, then copied in the one that I modified.  I did a pdm_webcache from a cmd prompt as well.

When I access the modified Change Order page from the GUI, I get an error message.

AHD04622:Undefined arguments EVT supplied to PDM_MACRO DTLDATE

In the std log, it has AHD04622:Undefined arguments EVT supplied to PDM_MACRO DTLDATE at detail_chg.htmpl[503].

I'm a bit lost on this.  Can someone advise me on what I might be doing wrong?  Much appreciated.  Thank You.

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...