Related List not triggering the business rule as expected.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-27-2025 12:48 AM
When I create or delete a record in the table Group Members(sys_user_grmember), i have a business rule that creates entries in Tenant User(u_tenant_user) table. It works fine.
The business rule is After: Insert, Delete
(function executeRule(current, previous /*null when async*/ ) {
var tenantUtils = new testTenantUtil();
if (current.operation() == 'insert'||current.operation() == 'update') {
tenantUtils.createTenantUsers(current.user, current.group);
} else {
tenantUtils.removeTenantUsers(current.user, current.group);
}
})(current, previous);
It works fine this way.
But,
When I click on Edit/New button through related list, it does not create the records in Tenant User table. That means not triggering the business rule, which is given above.
Thank You.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-27-2025 12:54 AM
Since a couple of versions, there is a delay on adding users to groups (or removing them). They are queued. I don't know why they did this, but it could be related to your issue.
Try by setting de BR to async. Maybe that will do the trick.
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-27-2025 01:13 AM
Thank you for the reply.
But, it is not working. 😞