This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Find use of Role across active/inactive users | |
List < User > lstUsers = [Select Id, IsActive, ProfileId, UserRoleId from user where UserRoleId != null]; | |
map < String, Integer > mapGroupToInActive = new Map < String, Integer > (); | |
map < String, Integer > mapGroupTotal = new Map < String, Integer > (); | |
for (User objUser: lstUsers) { | |
if (!objUser.IsActive) { | |
if (mapGroupToInActive.containsKey(objUser.UserRoleId)) | |
mapGroupToInActive.put(objUser.UserRoleId, mapGroupToInActive.get(objUser.UserRoleId) + 1); | |
else | |
mapGroupToInActive.put(objUser.UserRoleId, 1); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
List < Group > lstGroupReg = [Select Id from Group where Type = 'Regular']; | |
List < User > lstInActiveUser = [Select Id from user where IsActive = false]; | |
Set < id > SetInactiveUser = new Set < id > (); | |
for (User objUser: lstInActiveUser) { | |
SetInactiveUser.add(objUser.id); | |
} | |
List < GroupMember > lstGM = [Select Id, UserOrGroupId, GroupId from GroupMember where GroupId IN: lstGroupReg]; | |
//system.debug(lstGM.size()); | |
map < String, Integer > mapGroupToInActive = new Map < String, Integer > (); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//To Mark/Check Read only field | |
var arrayRead = document.querySelectorAll('input[id$=fls_read_ck]'); | |
for(i=0;i<arrayReadOnly.length;i++){ | |
if(!arrayReadOnly[i].checked){ | |
arrayReadOnly[i].checked = true; | |
} | |
} | |
//To Mark/Check Edit field |