fix keycloak user & update isDelete
All checks were successful
Build & Deploy on Dev / build (push) Successful in 1m1s
All checks were successful
Build & Deploy on Dev / build (push) Successful in 1m1s
This commit is contained in:
parent
212360a764
commit
fb4196cfa2
9 changed files with 445 additions and 354 deletions
|
|
@ -7796,10 +7796,11 @@ export class OrganizationController extends Controller {
|
|||
profile.leaveType = "RETIRE";
|
||||
profile.isActive = false;
|
||||
|
||||
if (profile.keycloak != null && profile.keycloak != "") {
|
||||
if (profile.keycloak != null && profile.keycloak != "" && profile.isDelete === false) {
|
||||
const delUserKeycloak = await deleteUser(profile.keycloak, token);
|
||||
if (delUserKeycloak) {
|
||||
profile.keycloak = "";
|
||||
// profile.keycloak = "";
|
||||
profile.isDelete = true;
|
||||
profile.roleKeycloaks = [];
|
||||
checkOfficer += 1;
|
||||
} else {
|
||||
|
|
@ -7824,10 +7825,11 @@ export class OrganizationController extends Controller {
|
|||
profileEmp.lastUpdatedAt = new Date();
|
||||
profileEmp.isActive = false;
|
||||
|
||||
if (profileEmp.keycloak != null && profileEmp.keycloak != "") {
|
||||
if (profileEmp.keycloak != null && profileEmp.keycloak != "" && profileEmp.isDelete === false) {
|
||||
const delUserKeycloak = await deleteUser(profileEmp.keycloak, token);
|
||||
if (delUserKeycloak) {
|
||||
profileEmp.keycloak = "";
|
||||
// profileEmp.keycloak = "";
|
||||
profileEmp.isDelete = true;
|
||||
profileEmp.roleKeycloaks = [];
|
||||
checkEmployee += 1;
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue