เพิ่มฟิวลำดับสอบ

This commit is contained in:
Kittapath 2023-07-10 17:13:54 +07:00
parent c6dc582254
commit 925d7fe747
2 changed files with 62 additions and 2 deletions

View file

@ -238,5 +238,19 @@ namespace BMA.EHR.Application.Repositories
throw;
}
}
public async Task<string?> CheckBmaOfficer(string CitizenId)
{
var data = await _context.Profiles.FirstOrDefaultAsync(x => x.CitizenId == CitizenId);
if (data == null)
return null;
if (data.ProfileType.Trim().ToUpper() == "OFFICER")
return "officer";
if (data.EmployeeClass.Trim().ToUpper() == "PERM")
return "employee_perm";
if (data.EmployeeClass.Trim().ToUpper() == "TEMP")
return "employee_temp";
return "employee";
}
}
}