add parent

This commit is contained in:
kittapath 2025-10-07 11:13:28 +07:00
parent ddf899ce5d
commit 9e8fe1b30a
22 changed files with 289 additions and 122 deletions

View file

@ -104,6 +104,10 @@ namespace BMA.EHR.Retirement.Service.Controllers
{
nodeId = profileAdmin?.RootDnaId;
}
else if (role == "PARENT")
{
nodeId = profileAdmin?.Child1DnaId;
}
var node = profileAdmin?.Node;
var retirementOthers = await _context.RetirementOthers.AsQueryable()
@ -210,6 +214,11 @@ namespace BMA.EHR.Retirement.Service.Controllers
retirementOthers = retirementOthers
.Where(x => x.rootDnaOldId == nodeId).ToList();
}
else if (role == "PARENT")
{
retirementOthers = retirementOthers
.Where(x => x.child1DnaOldId == nodeId).ToList();
}
else if (role == "NORMAL")
{
retirementOthers = retirementOthers