Merge branch 'develop'
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m2s
Build & Deploy Discipline Service / build (push) Successful in 1m4s
Build & Deploy Placement Service / build (push) Successful in 1m6s
Build & Deploy Insignia Service / build (push) Successful in 1m6s
Build & Deploy Retirement Service / build (push) Successful in 1m12s

This commit is contained in:
harid 2025-12-12 09:41:07 +07:00
commit 07dd715e16
27 changed files with 2267 additions and 494 deletions

View file

@ -627,6 +627,18 @@ namespace BMA.EHR.Insignia.Service.Controllers
? profileAdmin?.RootDnaId
: "";
}
else if (role == "BROTHER")
{
nodeId = profileAdmin?.Node == 4
? profileAdmin?.Child3DnaId
: profileAdmin?.Node == 3
? profileAdmin?.Child2DnaId
: profileAdmin?.Node == 2
? profileAdmin?.Child1DnaId
: profileAdmin?.Node == 1 || profileAdmin?.Node == 0
? profileAdmin?.RootDnaId
: "";
}
else if (role == "ROOT" || role == "PARENT")
{
nodeId = profileAdmin?.RootDnaId;
@ -702,6 +714,11 @@ namespace BMA.EHR.Insignia.Service.Controllers
rawData = rawData
.Where(x => node == 4 ? x.Child4DnaId == Guid.Parse(nodeId!) : (node == 3 ? x.Child3DnaId == Guid.Parse(nodeId!) : (node == 2 ? x.Child2DnaId == Guid.Parse(nodeId!) : (node == 1 ? x.Child1DnaId == Guid.Parse(nodeId!) : (node == 0 ? x.RootDnaId == Guid.Parse(nodeId!) : (node == null ? true : true)))))).ToList();
}
else if (role == "BROTHER")
{
rawData = rawData
.Where(x => node == 4 ? x.Child3DnaId == Guid.Parse(nodeId!) : (node == 3 ? x.Child2DnaId == Guid.Parse(nodeId!) : (node == 2 ? x.Child1DnaId == Guid.Parse(nodeId!) : (node == 1 || node == 0 ? x.RootDnaId == Guid.Parse(nodeId!) : true)))).ToList();
}
else if (role == "ROOT")
{
rawData = rawData
@ -914,6 +931,18 @@ namespace BMA.EHR.Insignia.Service.Controllers
? profileAdmin?.RootDnaId
: "";
}
else if (role == "BROTHER")
{
nodeId = profileAdmin?.Node == 4
? profileAdmin?.Child3DnaId
: profileAdmin?.Node == 3
? profileAdmin?.Child2DnaId
: profileAdmin?.Node == 2
? profileAdmin?.Child1DnaId
: profileAdmin?.Node == 1 || profileAdmin?.Node == 0
? profileAdmin?.RootDnaId
: "";
}
else if (role == "ROOT" || role == "PARENT")
{
nodeId = profileAdmin?.RootDnaId;
@ -987,6 +1016,11 @@ namespace BMA.EHR.Insignia.Service.Controllers
rawData = rawData
.Where(x => node == 4 ? x.Child4DnaId == Guid.Parse(nodeId!) : (node == 3 ? x.Child3DnaId == Guid.Parse(nodeId!) : (node == 2 ? x.Child2DnaId == Guid.Parse(nodeId!) : (node == 1 ? x.Child1DnaId == Guid.Parse(nodeId!) : (node == 0 ? x.RootDnaId == Guid.Parse(nodeId!) : (node == null ? true : true)))))).ToList();
}
else if (role == "BROTHER")
{
rawData = rawData
.Where(x => node == 4 ? x.Child3DnaId == Guid.Parse(nodeId!) : (node == 3 ? x.Child2DnaId == Guid.Parse(nodeId!) : (node == 2 ? x.Child1DnaId == Guid.Parse(nodeId!) : (node == 1 || node == 0 ? x.RootDnaId == Guid.Parse(nodeId!) : true)))).ToList();
}
else if (role == "ROOT")
{
rawData = rawData