
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2018 09:52 PM
Hello Experts,
I am facing a weird issue in a customer instance.
When an end user (without HR Profile record) is logging in ServiceNow and trying to access the "hrportal" url, system is creating a HR profile for the same user automatically.
This is not happening in my OOB personal dev.
Any inputs or comments please ?
Regards,
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-04-2019 06:08 AM
Hi,
We had a similar issue. Where HR profiles were being created when a user logged into the Portal. We had to do the following:
Comment out lines of code in the Portal Tables: Header | Footer, We use the 'HRI Header'. (we commented out lines 23-29):
// HR Profile
// var gr = new GlideRecord('sn_hr_core_profile');
// gr.addQuery('user', gs.getUserID());
// gr.query();
// if (!gr.next()) {
// gr.setValue('user', gs.getUserID());
// gr.insert();
// }
Please be aware that we create the HR Profile for all supported users when the sys_user record is created and we have SSO setup.
Hope this helps. Also check to make sure that duplicate HR Profiles are not being created when a HR Case is being submitted as well. We had an issue where the support agent did not having access to the user's HR Profile, So it would create a duplicate HR Profile when a ticket was submitted. We had to modify some ACLs for this to work.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-04-2019 06:08 AM
Hi,
We had a similar issue. Where HR profiles were being created when a user logged into the Portal. We had to do the following:
Comment out lines of code in the Portal Tables: Header | Footer, We use the 'HRI Header'. (we commented out lines 23-29):
// HR Profile
// var gr = new GlideRecord('sn_hr_core_profile');
// gr.addQuery('user', gs.getUserID());
// gr.query();
// if (!gr.next()) {
// gr.setValue('user', gs.getUserID());
// gr.insert();
// }
Please be aware that we create the HR Profile for all supported users when the sys_user record is created and we have SSO setup.
Hope this helps. Also check to make sure that duplicate HR Profiles are not being created when a HR Case is being submitted as well. We had an issue where the support agent did not having access to the user's HR Profile, So it would create a duplicate HR Profile when a ticket was submitted. We had to modify some ACLs for this to work.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-03-2019 01:30 PM
Hi marcloding,
I am facing a similar issue to what you mentioned near the bottom of the accepted solution.
For some reason, HR Profiles are being duplicated on a large scale. Can you please walk me through the root cause for why it was happening on your instance and which ACL you needed to modify to make if stop duplicating the Profiles? I really appreciate your time, thank you!
Wes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-03-2019 04:32 PM
Hi Wes,
I reviewed what we did in 2018.
- We made the HR Profile Row record available to read for everyone. (no Roles associated in the ACL)
- We then created Field level ACLs (using * for for all fields) to be restricted to users that had specific Roles. We created Roles for our specific HR Regions.
- Finally we opened up certain fields to be open to everyone. (No Roles associated in the ACL)
- User field
- Number Field
Having the certain field exist so the user creating the Cases had access to see that the HR profile existed prevented a new HR profile from being created.
I hope this helps, this worked in our setup/environment, please heavily test in a sub-production instance for your environment.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-03-2019 01:30 PM
Hi marcloding,
I am facing a similar issue to what you mentioned near the bottom of the accepted solution.
For some reason, HR Profiles are being duplicated on a large scaled. Can you please walk me through the root cause for why it was happening on your instance and which ACL you needed to modify to make if stop duplicating the Profiles? I really appreciate your time, thank you!
Wes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-15-2020 05:58 AM
This was most helpful, thanks!