Merge branch 'develop' into dev
This commit is contained in:
commit
a7e6995570
7 changed files with 3251 additions and 51 deletions
|
|
@ -493,6 +493,23 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
LastUpdateUserId = UserId ?? "",
|
LastUpdateUserId = UserId ?? "",
|
||||||
LastUpdateFullName = FullName ?? "System Administrator",
|
LastUpdateFullName = FullName ?? "System Administrator",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
var apiUrl = $"{_configuration["API"]}/org/find/head/officer";
|
||||||
|
using (var client = new HttpClient())
|
||||||
|
{
|
||||||
|
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
|
||||||
|
client.DefaultRequestHeaders.Add("api_key", _configuration["API_KEY"]);
|
||||||
|
var _req = new HttpRequestMessage(HttpMethod.Get, apiUrl);
|
||||||
|
var _res = await client.SendAsync(_req);
|
||||||
|
var _result = await _res.Content.ReadAsStringAsync();
|
||||||
|
if (_res.IsSuccessStatusCode)
|
||||||
|
{
|
||||||
|
var org = JsonConvert.DeserializeObject<dynamic>(_result);
|
||||||
|
periodExam.AuthName = org.result.name == null ? "" : org.result.name;
|
||||||
|
periodExam.AuthPosition = org.result.position == null ? "" : org.result.position;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
await _context.PeriodExams.AddAsync(periodExam);
|
await _context.PeriodExams.AddAsync(periodExam);
|
||||||
await _context.SaveChangesAsync();
|
await _context.SaveChangesAsync();
|
||||||
|
|
||||||
|
|
@ -1281,18 +1298,18 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
r.LastName = workSheet?.Cells[row, 8]?.GetValue<string>() ?? "";
|
r.LastName = workSheet?.Cells[row, 8]?.GetValue<string>() ?? "";
|
||||||
r.Gendor = workSheet?.Cells[row, 98]?.GetValue<string>() ?? "";
|
r.Gendor = workSheet?.Cells[row, 98]?.GetValue<string>() ?? "";
|
||||||
r.National = workSheet?.Cells[row, 9]?.GetValue<string>() ?? "";
|
r.National = workSheet?.Cells[row, 9]?.GetValue<string>() ?? "";
|
||||||
r.Race = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
r.Race = "";//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
||||||
r.Religion = workSheet?.Cells[row, 10]?.GetValue<string>() ?? "";
|
r.Religion = workSheet?.Cells[row, 10]?.GetValue<string>() ?? "";
|
||||||
r.DateOfBirth = !string.IsNullOrWhiteSpace(workSheet?.Cells[row, 11]?.GetValue<string>()) ? _disableService.CheckDateTime(workSheet?.Cells[row, 11]?.GetValue<string>() ?? "", "dd/MM/yyyy") : DateTime.MinValue;
|
r.DateOfBirth = !string.IsNullOrWhiteSpace(workSheet?.Cells[row, 11]?.GetValue<string>()) ? _disableService.CheckDateTime(workSheet?.Cells[row, 11]?.GetValue<string>() ?? "", "dd/MM/yyyy") : DateTime.MinValue;
|
||||||
r.CitizenId = workSheet?.Cells[row, 12]?.GetValue<string>() ?? "";
|
r.CitizenId = workSheet?.Cells[row, 12]?.GetValue<string>() ?? "";
|
||||||
r.typeTest = workSheet?.Cells[row, 13]?.GetValue<string>() ?? "";
|
r.typeTest = workSheet?.Cells[row, 13]?.GetValue<string>() ?? "";
|
||||||
r.Marry = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
r.Marry = "";//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
||||||
r.Isspecial = "N";
|
r.Isspecial = "N";
|
||||||
r.CitizenCardIssuer = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
r.CitizenCardIssuer = "";//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
||||||
r.CitizenCardExpireDate = Convert.ToDateTime(workSheet?.Cells[row, 9999]?.GetValue<string>().ToDateTime(DateTimeFormat.Ymd, "-"));
|
r.CitizenCardExpireDate = DateTime.MinValue;//Convert.ToDateTime(workSheet?.Cells[row, 9999]?.GetValue<string>().ToDateTime(DateTimeFormat.Ymd, "-"));
|
||||||
r.ApplyDate = !string.IsNullOrWhiteSpace(workSheet?.Cells[row, 87]?.GetValue<string>()) ? _disableService.CheckDateTime(workSheet?.Cells[row, 87]?.GetValue<string>() ?? "", "dd/MM/yyyy") : DateTime.MinValue;
|
r.ApplyDate = !string.IsNullOrWhiteSpace(workSheet?.Cells[row, 87]?.GetValue<string>()) ? _disableService.CheckDateTime(workSheet?.Cells[row, 87]?.GetValue<string>() ?? "", "dd/MM/yyyy") : DateTime.MinValue;
|
||||||
r.PositionType = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
r.PositionType = "";//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
||||||
r.PositionLevel = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
r.PositionLevel = "";//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "";
|
||||||
|
|
||||||
r.CreatedAt = DateTime.Now;
|
r.CreatedAt = DateTime.Now;
|
||||||
r.CreatedUserId = UserId ?? "";
|
r.CreatedUserId = UserId ?? "";
|
||||||
|
|
@ -1306,11 +1323,11 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
{
|
{
|
||||||
Degree = workSheet?.Cells[row, 18]?.GetValue<string>() ?? "",
|
Degree = workSheet?.Cells[row, 18]?.GetValue<string>() ?? "",
|
||||||
Major = workSheet?.Cells[row, 19]?.GetValue<string>() == "อื่น ๆ" ? workSheet?.Cells[row, 20]?.GetValue<string>() ?? "" : workSheet?.Cells[row, 19]?.GetValue<string>() ?? "",
|
Major = workSheet?.Cells[row, 19]?.GetValue<string>() == "อื่น ๆ" ? workSheet?.Cells[row, 20]?.GetValue<string>() ?? "" : workSheet?.Cells[row, 19]?.GetValue<string>() ?? "",
|
||||||
MajorGroupId = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
MajorGroupId = "",//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
||||||
MajorGroupName = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
MajorGroupName = "",//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
||||||
University = workSheet?.Cells[row, 21]?.GetValue<string>() == "อื่น ๆ" ? workSheet?.Cells[row, 22]?.GetValue<string>() ?? "" : workSheet?.Cells[row, 21]?.GetValue<string>() ?? "",
|
University = workSheet?.Cells[row, 21]?.GetValue<string>() == "อื่น ๆ" ? workSheet?.Cells[row, 22]?.GetValue<string>() ?? "" : workSheet?.Cells[row, 21]?.GetValue<string>() ?? "",
|
||||||
GPA = (double)workSheet?.Cells[row, 26]?.GetValue<double>(),
|
GPA = (double)workSheet?.Cells[row, 26]?.GetValue<double>(),
|
||||||
Specialist = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
Specialist = "",//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
||||||
HighDegree = workSheet?.Cells[row, 27]?.GetValue<string>() ?? "",
|
HighDegree = workSheet?.Cells[row, 27]?.GetValue<string>() ?? "",
|
||||||
BachelorDate = !string.IsNullOrWhiteSpace(workSheet?.Cells[row, 25]?.GetValue<string>()) ? _disableService.CheckDateTime(workSheet?.Cells[row, 11]?.GetValue<string>() ?? "", "dd/MM/yyyy") : DateTime.MinValue,
|
BachelorDate = !string.IsNullOrWhiteSpace(workSheet?.Cells[row, 25]?.GetValue<string>()) ? _disableService.CheckDateTime(workSheet?.Cells[row, 11]?.GetValue<string>() ?? "", "dd/MM/yyyy") : DateTime.MinValue,
|
||||||
CreatedAt = DateTime.Now,
|
CreatedAt = DateTime.Now,
|
||||||
|
|
@ -1327,8 +1344,8 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
Occupation = workSheet?.Cells[row, 33]?.GetValue<string>() == "อื่น ๆ" ? workSheet?.Cells[row, 34]?.GetValue<string>() ?? "" : workSheet?.Cells[row, 33]?.GetValue<string>() ?? "",
|
Occupation = workSheet?.Cells[row, 33]?.GetValue<string>() == "อื่น ๆ" ? workSheet?.Cells[row, 34]?.GetValue<string>() ?? "" : workSheet?.Cells[row, 33]?.GetValue<string>() ?? "",
|
||||||
Position = workSheet?.Cells[row, 37]?.GetValue<string>() ?? "",
|
Position = workSheet?.Cells[row, 37]?.GetValue<string>() ?? "",
|
||||||
Workplace = $"{(workSheet?.Cells[row, 36]?.GetValue<string>() ?? "")} {(workSheet?.Cells[row, 35]?.GetValue<string>() ?? "")}",
|
Workplace = $"{(workSheet?.Cells[row, 36]?.GetValue<string>() ?? "")} {(workSheet?.Cells[row, 35]?.GetValue<string>() ?? "")}",
|
||||||
Telephone = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
Telephone = "",//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
||||||
WorkAge = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
WorkAge = "",//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
||||||
CreatedAt = DateTime.Now,
|
CreatedAt = DateTime.Now,
|
||||||
CreatedUserId = UserId ?? "",
|
CreatedUserId = UserId ?? "",
|
||||||
CreatedFullName = FullName ?? "System Administrator",
|
CreatedFullName = FullName ?? "System Administrator",
|
||||||
|
|
@ -1349,7 +1366,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
Province = workSheet?.Cells[row, 56]?.GetValue<string>() ?? "",
|
Province = workSheet?.Cells[row, 56]?.GetValue<string>() ?? "",
|
||||||
ZipCode = workSheet?.Cells[row, 57]?.GetValue<string>() ?? "",
|
ZipCode = workSheet?.Cells[row, 57]?.GetValue<string>() ?? "",
|
||||||
Telephone = workSheet?.Cells[row, 58]?.GetValue<string>() ?? "",
|
Telephone = workSheet?.Cells[row, 58]?.GetValue<string>() ?? "",
|
||||||
Mobile = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
Mobile = "",//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
||||||
Address1 = $"{(workSheet?.Cells[row, 61]?.GetValue<string>() ?? "")} {(workSheet?.Cells[row, 62]?.GetValue<string>() ?? "")}",
|
Address1 = $"{(workSheet?.Cells[row, 61]?.GetValue<string>() ?? "")} {(workSheet?.Cells[row, 62]?.GetValue<string>() ?? "")}",
|
||||||
Moo1 = workSheet?.Cells[row, 63]?.GetValue<string>() ?? "",
|
Moo1 = workSheet?.Cells[row, 63]?.GetValue<string>() ?? "",
|
||||||
Soi1 = workSheet?.Cells[row, 64]?.GetValue<string>() ?? "",
|
Soi1 = workSheet?.Cells[row, 64]?.GetValue<string>() ?? "",
|
||||||
|
|
@ -1396,10 +1413,10 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
// certificate
|
// certificate
|
||||||
r.Certificates.Add(new DisableCertificate()
|
r.Certificates.Add(new DisableCertificate()
|
||||||
{
|
{
|
||||||
CertificateNo = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
CertificateNo = "",//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
||||||
Description = workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
Description = "",//workSheet?.Cells[row, 9999]?.GetValue<string>() ?? "",
|
||||||
IssueDate = Convert.ToDateTime(workSheet?.Cells[row, 9999]?.GetValue<string>().ToDateTime(DateTimeFormat.Ymd, "-")),
|
IssueDate = DateTime.MinValue,//Convert.ToDateTime(workSheet?.Cells[row, 9999]?.GetValue<string>().ToDateTime(DateTimeFormat.Ymd, "-")),
|
||||||
ExpiredDate = Convert.ToDateTime(workSheet?.Cells[row, 9999]?.GetValue<string>().ToDateTime(DateTimeFormat.Ymd, "-")),
|
ExpiredDate = DateTime.MinValue,//Convert.ToDateTime(workSheet?.Cells[row, 9999]?.GetValue<string>().ToDateTime(DateTimeFormat.Ymd, "-")),
|
||||||
CreatedAt = DateTime.Now,
|
CreatedAt = DateTime.Now,
|
||||||
CreatedUserId = UserId ?? "",
|
CreatedUserId = UserId ?? "",
|
||||||
CreatedFullName = FullName ?? "System Administrator",
|
CreatedFullName = FullName ?? "System Administrator",
|
||||||
|
|
@ -1594,22 +1611,6 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
// ใช้ dictionary lookup แทน query DB ทีละรอบ
|
// ใช้ dictionary lookup แทน query DB ทีละรอบ
|
||||||
if (!string.IsNullOrEmpty(r.ExamId) && recruitsDict.TryGetValue(r.ExamId, out var recruit))
|
if (!string.IsNullOrEmpty(r.ExamId) && recruitsDict.TryGetValue(r.ExamId, out var recruit))
|
||||||
{
|
{
|
||||||
var apiUrl = $"{_configuration["API"]}/org/find/head/officer";
|
|
||||||
using (var client = new HttpClient())
|
|
||||||
{
|
|
||||||
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
|
|
||||||
client.DefaultRequestHeaders.Add("api_key", _configuration["API_KEY"]);
|
|
||||||
var _req = new HttpRequestMessage(HttpMethod.Get, apiUrl);
|
|
||||||
var _res = await client.SendAsync(_req);
|
|
||||||
var _result = await _res.Content.ReadAsStringAsync();
|
|
||||||
if (_res.IsSuccessStatusCode)
|
|
||||||
{
|
|
||||||
var org = JsonConvert.DeserializeObject<dynamic>(_result);
|
|
||||||
recruit.AuthName = org.result.name == null ? "" : org.result.name;
|
|
||||||
recruit.AuthPosition = org.result.position == null ? "" : org.result.position;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
r.CitizenId = workSheet?.Cells[row, 3]?.GetValue<string>();
|
r.CitizenId = workSheet?.Cells[row, 3]?.GetValue<string>();
|
||||||
|
|
||||||
// ภาคความรู้ความสามารถที่ใช้เฉพาะตำแหน่ง
|
// ภาคความรู้ความสามารถที่ใช้เฉพาะตำแหน่ง
|
||||||
|
|
@ -1760,6 +1761,9 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
// preload score
|
// preload score
|
||||||
var score = rec_import.ScoreImport.Scores
|
var score = rec_import.ScoreImport.Scores
|
||||||
.Where(s => !string.IsNullOrEmpty(s.ExamId))
|
.Where(s => !string.IsNullOrEmpty(s.ExamId))
|
||||||
|
.GroupBy(x => x.ExamId)
|
||||||
|
.Where(g => g.Count() == 1)
|
||||||
|
.Select(g => g.First())
|
||||||
.ToDictionary(s => s.ExamId, s => s);
|
.ToDictionary(s => s.ExamId, s => s);
|
||||||
|
|
||||||
// ถ้าไม่มีผลคะแนนสอบคัดเลือกผู้พิการให้จบการทำงาน
|
// ถ้าไม่มีผลคะแนนสอบคัดเลือกผู้พิการให้จบการทำงาน
|
||||||
|
|
@ -1906,19 +1910,19 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
profileID = dr["profileID"].ToString(),
|
profileID = dr["profileID"].ToString(),
|
||||||
prefix = dr["prefix"].ToString(),
|
prefix = dr["prefix"].ToString(),
|
||||||
fullName = dr["fullName"].ToString(),
|
fullName = dr["fullName"].ToString(),
|
||||||
dateOfBirth = dr["dateofbirth"] == null ? "" : Convert.ToDateTime(dr["dateofbirth"]).ToThaiShortDate(),
|
dateOfBirth = dr["dateofbirth"] == null || Convert.ToDateTime(dr["dateofbirth"]) == DateTime.MinValue ? "" : Convert.ToDateTime(dr["dateofbirth"]).ToThaiShortDate(),
|
||||||
gender = dr["gender"].ToString(),
|
gender = dr["gender"].ToString(),
|
||||||
degree = dr["degree"].ToString(),
|
degree = dr["degree"].ToString(),
|
||||||
major = dr["major"].ToString(),
|
major = dr["major"].ToString(),
|
||||||
majorgroup = dr["majorgroup"].ToString(),
|
majorgroup = dr["majorgroup"].ToString(),
|
||||||
certificateNo = dr["certificateno"].ToString(),
|
certificateNo = dr["certificateno"].ToString(),
|
||||||
certificateIssueDate = dr["certificateIssueDate"] == null ? "" : Convert.ToDateTime(dr["certificateIssueDate"]).ToThaiShortDate(),
|
certificateIssueDate = dr["certificateIssueDate"] == null || Convert.ToDateTime(dr["certificateIssueDate"]) == DateTime.MinValue ? "" : Convert.ToDateTime(dr["certificateIssueDate"]).ToThaiShortDate(),
|
||||||
ExamScore = dr["score"] == null ? 0 : dr["score"].ToString().ToInteger(),
|
ExamScore = dr["score"] == null ? 0 : dr["score"].ToString().ToInteger(),
|
||||||
ExamResult = dr["result"].ToString(),
|
ExamResult = dr["result"].ToString(),
|
||||||
ExamAttribute = dr["examAttribute"].ToString(),
|
ExamAttribute = dr["examAttribute"].ToString(),
|
||||||
Remark = dr["remark"].ToString(),
|
Remark = dr["remark"].ToString(),
|
||||||
IsSpecial = dr["isspecial"].ToString(),
|
IsSpecial = dr["isspecial"].ToString(),
|
||||||
applyDate = dr["applydate"] == null ? "" : Convert.ToDateTime(dr["applydate"]).ToThaiShortDate(),
|
applyDate = dr["applydate"] == null || Convert.ToDateTime(dr["applydate"]) == DateTime.MinValue ? "" : Convert.ToDateTime(dr["applydate"]).ToThaiShortDate(),
|
||||||
university = dr["university"].ToString(),
|
university = dr["university"].ToString(),
|
||||||
position_name = dr["position_name"].ToString(),
|
position_name = dr["position_name"].ToString(),
|
||||||
hddPosition = dr["hddPosition"].ToString(),
|
hddPosition = dr["hddPosition"].ToString(),
|
||||||
|
|
@ -1930,7 +1934,6 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
score_year = Convert.ToInt32(dr["score_year"]).ToThaiYear().ToString(),
|
score_year = Convert.ToInt32(dr["score_year"]).ToThaiYear().ToString(),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (data != null && data.Count > 0)
|
if (data != null && data.Count > 0)
|
||||||
|
|
@ -1950,7 +1953,6 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
|
|
||||||
cmd.CommandText = sb.ToString();
|
cmd.CommandText = sb.ToString();
|
||||||
|
|
||||||
|
|
||||||
_context.Database.OpenConnection();
|
_context.Database.OpenConnection();
|
||||||
MySqlDataAdapter da = new MySqlDataAdapter(cmd as MySqlCommand);
|
MySqlDataAdapter da = new MySqlDataAdapter(cmd as MySqlCommand);
|
||||||
DataTable dt = new DataTable();
|
DataTable dt = new DataTable();
|
||||||
|
|
@ -2027,7 +2029,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
CertificateNo = p.Certificates.Count > 0
|
CertificateNo = p.Certificates.Count > 0
|
||||||
? p.Certificates.First().CertificateNo ?? ""
|
? p.Certificates.First().CertificateNo ?? ""
|
||||||
: "",
|
: "",
|
||||||
CertificateIssueDate = p.Certificates.Count > 0
|
CertificateIssueDate = p.Certificates.Count > 0
|
||||||
? p.Certificates.First().IssueDate != DateTime.MinValue
|
? p.Certificates.First().IssueDate != DateTime.MinValue
|
||||||
? p.Certificates.First().IssueDate.ToThaiShortDate()
|
? p.Certificates.First().IssueDate.ToThaiShortDate()
|
||||||
: ""
|
: ""
|
||||||
|
|
@ -2333,7 +2335,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
Major = p.Educations.First().Major,
|
Major = p.Educations.First().Major,
|
||||||
University = p.Educations.First().University,
|
University = p.Educations.First().University,
|
||||||
PositionName = p.PositionName,
|
PositionName = p.PositionName,
|
||||||
ExamName = $"{p.PeriodExam!.Name} ครั้งที่ {p.PeriodExam.Round}/{(p.PeriodExam.Year > 2500 ? p.PeriodExam.Year : (p.PeriodExam.Year+543))}".ToThaiNumber(),
|
ExamName = $"{p.PeriodExam!.Name} ครั้งที่ {p.PeriodExam.Round}/{(p.PeriodExam.Year > 2500 ? p.PeriodExam.Year : (p.PeriodExam.Year + 543))}".ToThaiNumber(),
|
||||||
|
|
||||||
ExamCount = _disableService.GetExamCount(p.CitizenId).ToString().ToThaiNumber(),
|
ExamCount = _disableService.GetExamCount(p.CitizenId).ToString().ToThaiNumber(),
|
||||||
type = p.typeTest == "bangkok" ? "กทม." : p.typeTest == "ocsc" ? "ก.พ." : "",
|
type = p.typeTest == "bangkok" ? "กทม." : p.typeTest == "ocsc" ? "ก.พ." : "",
|
||||||
|
|
|
||||||
|
|
@ -101,8 +101,8 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
||||||
FullName = $"{p.Prefix}{p.FirstName} {p.LastName}",
|
FullName = $"{p.Prefix}{p.FirstName} {p.LastName}",
|
||||||
ExamResult = sr == null ? "" : sr.ExamStatus,
|
ExamResult = sr == null ? "" : sr.ExamStatus,
|
||||||
EndDate = p.PeriodExam.RegisterEndDate == null ? null : p.PeriodExam.RegisterEndDate.Value.ToThaiFullDate3(),
|
EndDate = p.PeriodExam.RegisterEndDate == null ? null : p.PeriodExam.RegisterEndDate.Value.ToThaiFullDate3(),
|
||||||
AuthName = "นายณัฐพงศ์ ดิษยบุตร",
|
AuthName = p.PeriodExam.AuthName,
|
||||||
AuthPosition = "หัวหน้าสำนักงาน ก.ก."
|
AuthPosition = p.PeriodExam.AuthPosition,
|
||||||
})
|
})
|
||||||
.FirstOrDefaultAsync();
|
.FirstOrDefaultAsync();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1007,12 +1007,6 @@ namespace BMA.EHR.Recurit.Exam.Service.Data.Migrations
|
||||||
b.Property<DateTime>("ApplyDate")
|
b.Property<DateTime>("ApplyDate")
|
||||||
.HasColumnType("datetime(6)");
|
.HasColumnType("datetime(6)");
|
||||||
|
|
||||||
b.Property<string>("AuthName")
|
|
||||||
.HasColumnType("longtext");
|
|
||||||
|
|
||||||
b.Property<string>("AuthPosition")
|
|
||||||
.HasColumnType("longtext");
|
|
||||||
|
|
||||||
b.Property<DateTime>("CitizenCardExpireDate")
|
b.Property<DateTime>("CitizenCardExpireDate")
|
||||||
.HasColumnType("datetime(6)");
|
.HasColumnType("datetime(6)");
|
||||||
|
|
||||||
|
|
@ -2229,6 +2223,12 @@ namespace BMA.EHR.Recurit.Exam.Service.Data.Migrations
|
||||||
.HasColumnOrder(6)
|
.HasColumnOrder(6)
|
||||||
.HasComment("วันเริ่มประกาศ");
|
.HasComment("วันเริ่มประกาศ");
|
||||||
|
|
||||||
|
b.Property<string>("AuthName")
|
||||||
|
.HasColumnType("longtext");
|
||||||
|
|
||||||
|
b.Property<string>("AuthPosition")
|
||||||
|
.HasColumnType("longtext");
|
||||||
|
|
||||||
b.Property<string>("Category")
|
b.Property<string>("Category")
|
||||||
.HasColumnType("longtext")
|
.HasColumnType("longtext")
|
||||||
.HasComment("สำนัก");
|
.HasComment("สำนัก");
|
||||||
|
|
|
||||||
3134
Migrations/20250915085529_update_table_period_add_authname.Designer.cs
generated
Normal file
3134
Migrations/20250915085529_update_table_period_add_authname.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,62 @@
|
||||||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
|
|
||||||
|
#nullable disable
|
||||||
|
|
||||||
|
namespace BMA.EHR.Recurit.Exam.Service.Migrations
|
||||||
|
{
|
||||||
|
/// <inheritdoc />
|
||||||
|
public partial class update_table_period_add_authname : Migration
|
||||||
|
{
|
||||||
|
/// <inheritdoc />
|
||||||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
migrationBuilder.DropColumn(
|
||||||
|
name: "AuthName",
|
||||||
|
table: "Disables");
|
||||||
|
|
||||||
|
migrationBuilder.DropColumn(
|
||||||
|
name: "AuthPosition",
|
||||||
|
table: "Disables");
|
||||||
|
|
||||||
|
migrationBuilder.AddColumn<string>(
|
||||||
|
name: "AuthName",
|
||||||
|
table: "PeriodExams",
|
||||||
|
type: "longtext",
|
||||||
|
nullable: true)
|
||||||
|
.Annotation("MySql:CharSet", "utf8mb4");
|
||||||
|
|
||||||
|
migrationBuilder.AddColumn<string>(
|
||||||
|
name: "AuthPosition",
|
||||||
|
table: "PeriodExams",
|
||||||
|
type: "longtext",
|
||||||
|
nullable: true)
|
||||||
|
.Annotation("MySql:CharSet", "utf8mb4");
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <inheritdoc />
|
||||||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
migrationBuilder.DropColumn(
|
||||||
|
name: "AuthName",
|
||||||
|
table: "PeriodExams");
|
||||||
|
|
||||||
|
migrationBuilder.DropColumn(
|
||||||
|
name: "AuthPosition",
|
||||||
|
table: "PeriodExams");
|
||||||
|
|
||||||
|
migrationBuilder.AddColumn<string>(
|
||||||
|
name: "AuthName",
|
||||||
|
table: "Disables",
|
||||||
|
type: "longtext",
|
||||||
|
nullable: true)
|
||||||
|
.Annotation("MySql:CharSet", "utf8mb4");
|
||||||
|
|
||||||
|
migrationBuilder.AddColumn<string>(
|
||||||
|
name: "AuthPosition",
|
||||||
|
table: "Disables",
|
||||||
|
type: "longtext",
|
||||||
|
nullable: true)
|
||||||
|
.Annotation("MySql:CharSet", "utf8mb4");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -80,8 +80,8 @@ namespace BMA.EHR.Recurit.Exam.Service.Models.Disables
|
||||||
public string? PositionName { get; set; }//
|
public string? PositionName { get; set; }//
|
||||||
public string? PositionType { get; set; }
|
public string? PositionType { get; set; }
|
||||||
public string? PositionLevel { get; set; }
|
public string? PositionLevel { get; set; }
|
||||||
public string? AuthName { get; set; }
|
// public string? AuthName { get; set; }
|
||||||
public string? AuthPosition { get; set; }
|
// public string? AuthPosition { get; set; }
|
||||||
|
|
||||||
[Comment("บัญชีสอบ")]
|
[Comment("บัญชีสอบ")]
|
||||||
public string? HddPosition { get; set; } = string.Empty;
|
public string? HddPosition { get; set; } = string.Empty;
|
||||||
|
|
|
||||||
|
|
@ -100,6 +100,8 @@ namespace BMA.EHR.Recurit.Exam.Service.Models
|
||||||
|
|
||||||
[Comment("Ref No1")]
|
[Comment("Ref No1")]
|
||||||
public string? RefNo1 { get; set; }
|
public string? RefNo1 { get; set; }
|
||||||
|
public string? AuthName { get; set; }
|
||||||
|
public string? AuthPosition { get; set; }
|
||||||
|
|
||||||
[Comment("รายชื่อคนสม้ครในรอบ")]
|
[Comment("รายชื่อคนสม้ครในรอบ")]
|
||||||
public List<Candidate> Candidate { get; set; } = new List<Candidate>();
|
public List<Candidate> Candidate { get; set; } = new List<Candidate>();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue