- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2016 12:17 AM
Hi,
I'm facing a weird issue in a business rule : the gs.log() doesn't write anything in the syslog.
We have defined an application menu "Assigned" to get the incident assigned to the groups that a person belongs to. In the menu, we set a filter condition "assignment group is javascript:GetMyGroups"
The function "getMyGroups" is OOB and defined in the business rule "groups, banners". As we wish to return only specific groups (i.e. the groups for assignment not the technical ones), I wish to change the code (I will make a copy).
So I've began with a gs.log, but it doesn't write anythink in the syslog
function getMyGroups() {
gs.log("IN GET MY GROUPS OOB");
return gs.getUser().getMyGroups();
}
Very strange....
Could you help me ?
Thanks
Jean-Luc
Solved! Go to Solution.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2016 07:23 AM
Thanks Jean-Luc. Didn't you say that this is a scoped app? If so, gs.log is off limits. Change it to gs.info and see if your script produces output. For best visibility to what's going on, turn on business rule debugging.
System Diagnostics> Debug Business Rule (details) and observe the output at the bottom of your form or list after you save your changes.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2016 01:02 AM
gs.log doesn't work in Scoped Applications. You need to use gs.info() or gs.debug() etc instead.
So is your Business Rule in a Scoped App?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2016 07:11 AM
Hi Geoffrey,
This is a scoped application

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2016 01:07 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2016 07:13 AM
Hi Geoffrey,
Thanks for your 2 answers.
I've tried what you have written but it doesn't work either.
The original business rule and your script include are called both. That works. But the problem is that no the gs.log has zero effect.