Ordering catalog item for multiple users

RamSagar
Tera Guru

Hi,

We are using two step checkout process and we want to order the catalog item to multiple user at once.

The issue is we are setting the requested for in the Request table in the workflow and same is populating in the RITM which is working fine in ordering single catalog item.

But when we are ordering for multiple users , the requested for is same for all the RITM's which is incorrect.

So we want to populate the requested for based on the variables in the catalog in RITM , when ordering for multiple users.

Thanks,
Ram

6 REPLIES 6

Mihir Mohanta
Kilo Sage

Hi Ramu,



In the workflow you can use a run script activity and there write script like:



var reqRecord = current.request.getRefRecord();


reqRecord.requested_for = current.variables.request_for; // change the variable name of catalog form in place of bold text


reqRecord.update();




Thanks,


Mihir


Thanks Mihir. Proof that I still learn something new every day... I did not know about the getRefRecord() method. I like it!