Duplicate RITMs are created while submitting catalog item using cart- API
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-09-2024 10:33 AM
I am submitting a catalog item using cart API. but, it's generating multilple duplicate records everytime it execute which i am unable to identify the root case of it.
BR : Async
Table : Astone(u_stone)
Condition: Status changesto 'completed'
insert: true
Script:

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-09-2024 11:43 AM - edited ‎09-09-2024 11:45 AM
Not sure if this is the issue with multiple but have you tried running the BR as a before or after rather then async. I don't see anything in the code that would order multiple.
Edit: Also I see in docs that async business rules do not have access to changes to for conditions.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-09-2024 11:55 AM - edited ‎09-09-2024 11:55 AM
For the requested for on the RITM I think you need to add the following after
var cart = new sn_sc.CartJS();
cart.setRequestedFor(current.u_user.toString());
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-10-2024 02:28 AM
@Brian Lancaster , thank you for replying. issue is fixed using below script: