Hello,
I am trying to disable all accounts that are tied to an identity. I know that identity.setAttribute("IIQDisabled, true) can set it to disable, but somehow I can only disable the identity itself instead of all the applications it belongs to. Does anyone know how to fix this issue?
SailPointContext context = SailPointFactory.getCurrentContext();
List<String> applications = context.getObjects(Application.class);
ArrayList<String> information = new ArrayList<String>();
ArrayList<String> info = new ArrayList<String>();
List<String> identities = context.getObjects(Identity.class);
String c = "Wilson";
for (Identity ident : identities) {
if(ident.getAttribute("displayName").contains(c)){
ident.setAttribute("IIQDisabled", true);
return ident;
//information.add(ident);
}
}