Highlighted
Absent Member.. Absent Member..
Absent Member..
707 views

can't update file passed in to wizard

Jump to solution

Upon saving an incident ticket, I call a wizard which will update some of the fields on the ticket.  When the wizard returns, though, the fields on the ticket are unchanged.  Is it possible to modify the ticket's values in a wizard?  Here is some relevant info:

 

-I call the wizard from the subroutines tab of the format control.  I pass in $file as the file variable.

-In the wizard, I use $L.file passed in

-In the wizard, I modify the values in $L.file in the Actions -> Javascript tab

-In the wizard, I use print statements to verify I'm modifying $L.file as expected

-In the wizard, I have "return current file to calling application" checked.  I've also tried unchecking it, too.

Tags (1)
0 Likes
1 Solution

Accepted Solutions
Highlighted
Absent Member.. Absent Member..
Absent Member..

Problem solved!!  I found that if you set the “before” attribute to “true” in the format control (on the subroutine tab), the update I do during the wizard will stick.

View solution in original post

0 Likes
6 Replies
Highlighted
Micro Focus Expert
Micro Focus Expert

Hi,

 

Yes, you can. It seems your configuration is fine.

 

Could you share the js code you are using to assign values to the $L.file variable? Additionally, please let me know if you are calling the wizard after/before the save process is called.

 

Regards,

If you feel this was helpful please click the KUDOS! thumb below!
0 Likes
Highlighted
Absent Member.. Absent Member..
Absent Member..

I'm calling the wizard.run process from the incident ticket's format control.  It's on the subroutines tab on the update condition.

 

Here is a snippet of the javascript I'm using.  I have confirmed that the code is executing properly, and that $L.file has the updated value after this code executes.

 

switch(system.vars.$G_endTime){
	case "primaryRest":
		system.vars.$L_file.uh_restore_time = system.vars.$G_primaryRest;
		break;
	case "latestServ":
		system.vars.$L_file.uh_restore_time = system.vars.$G_latestServ;
		break;
}

 

One more thing - I do already have word from HP support that this is not possible.  Here is what they said:

 

"As we talked on the phone some moments ago, it is not an option to call the wizard from the format control record as it will keep running and update the IM ticket before we are done with selecting the value from the wizard.

 

The reason of this, is because the format control is called by the RAD and the intention is that there is no user interaction until the format control is done. If successful, the RAD flow moves onto saving (as it is happening to us). If there is a failed validation, or something such as this, the operation is halted and returned to the display application for the user to fix it."

0 Likes
Highlighted
Micro Focus Expert
Micro Focus Expert

Hi,

 

The information you have received is totally correct. You could try calling it from the display option.

 

Regards,

If you feel this was helpful please click the KUDOS! thumb below!
0 Likes
Highlighted
Absent Member.. Absent Member..
Absent Member..
I am trying that now, I'll update the thread if it ends up working.
0 Likes
Highlighted
Absent Member.. Absent Member..
Absent Member..

Problem solved!!  I found that if you set the “before” attribute to “true” in the format control (on the subroutine tab), the update I do during the wizard will stick.

View solution in original post

0 Likes
Highlighted
Micro Focus Expert
Micro Focus Expert

Hi,

 

Great news!

 

Regards,

If you feel this was helpful please click the KUDOS! thumb below!
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.