import ไฟล์สมัครสอบ
This commit is contained in:
parent
b7e814e0cf
commit
c76f29934b
2 changed files with 22 additions and 20 deletions
|
|
@ -269,7 +269,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
/// <summary>
|
||||
/// ข้อมูล ข้อมูลส่วนตัว ผู้สมัคร
|
||||
/// </summary>
|
||||
/// <param name="candidate">รหัสรอบสมัคร</param>
|
||||
/// <param name="candidate">รหัสผู้สมัคร</param>
|
||||
/// <returns></returns>
|
||||
/// <response code="200">เมื่อทำการดึง ข้อมูล ข้อมูลส่วนตัว ผู้สมัคร สำเร็จ</response>
|
||||
/// <response code="401">ไม่ได้ Login เข้าระบบ</response>
|
||||
|
|
@ -295,7 +295,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
/// <summary>
|
||||
/// ข้อมูล ข้อมูลที่อยู่ ผู้สมัคร
|
||||
/// </summary>
|
||||
/// <param name="candidate">รหัสรอบสมัคร</param>
|
||||
/// <param name="candidate">รหัสผู้สมัคร</param>
|
||||
/// <returns></returns>
|
||||
/// <response code="200">เมื่อทำการดึง ข้อมูล ข้อมูลที่อยู่ ผู้สมัคร สำเร็จ</response>
|
||||
/// <response code="401">ไม่ได้ Login เข้าระบบ</response>
|
||||
|
|
@ -321,7 +321,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
/// <summary>
|
||||
/// ข้อมูล ข้อมูลครอบครัว ผู้สมัคร
|
||||
/// </summary>
|
||||
/// <param name="candidate">รหัสรอบสมัคร</param>
|
||||
/// <param name="candidate">รหัสผู้สมัคร</param>
|
||||
/// <returns></returns>
|
||||
/// <response code="200">เมื่อทำการดึง ข้อมูล ข้อมูลครอบครัว ผู้สมัคร สำเร็จ</response>
|
||||
/// <response code="401">ไม่ได้ Login เข้าระบบ</response>
|
||||
|
|
@ -334,7 +334,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
{
|
||||
try
|
||||
{
|
||||
var items = await _candidateService.GetsAsyncFamily(candidate);
|
||||
var items = await _periodExamService.GetsAsyncFamily(candidate);
|
||||
|
||||
return Success(items);
|
||||
}
|
||||
|
|
@ -347,7 +347,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
/// <summary>
|
||||
/// ข้อมูล อาชีพ ผู้สมัคร
|
||||
/// </summary>
|
||||
/// <param name="candidate">รหัสรอบสมัคร</param>
|
||||
/// <param name="candidate">รหัสผู้สมัคร</param>
|
||||
/// <returns></returns>
|
||||
/// <response code="200">เมื่อทำการดึง ข้อมูล อาชีพ ผู้สมัคร สำเร็จ</response>
|
||||
/// <response code="401">ไม่ได้ Login เข้าระบบ</response>
|
||||
|
|
@ -360,7 +360,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
{
|
||||
try
|
||||
{
|
||||
var items = await _candidateService.GetsAsyncOccupation(candidate);
|
||||
var items = await _periodExamService.GetsAsyncOccupation(candidate);
|
||||
|
||||
return Success(items);
|
||||
}
|
||||
|
|
@ -373,7 +373,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
/// <summary>
|
||||
/// ข้อมูล ประวัติการทำงาน/ฝึกงาน ผู้สมัคร
|
||||
/// </summary>
|
||||
/// <param name="candidate">รหัสรอบสมัคร</param>
|
||||
/// <param name="candidate">รหัสผู้สมัคร</param>
|
||||
/// <returns></returns>
|
||||
/// <response code="200">เมื่อทำการดึง ข้อมูล ประวัติการทำงาน/ฝึกงาน ผู้สมัคร สำเร็จ</response>
|
||||
/// <response code="401">ไม่ได้ Login เข้าระบบ</response>
|
||||
|
|
@ -386,7 +386,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
{
|
||||
try
|
||||
{
|
||||
var items = await _candidateService.GetsAsyncCareer(candidate);
|
||||
var items = await _periodExamService.GetsAsyncCareer(candidate);
|
||||
|
||||
return Success(items);
|
||||
}
|
||||
|
|
@ -395,10 +395,11 @@ namespace BMA.EHR.Recurit.Exam.Service.Controllers
|
|||
return Error(ex);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// ข้อมูล ประวัติการศีกษา ผู้สมัคร
|
||||
/// </summary>
|
||||
/// <param name="candidate">รหัสรอบสมัคร</param>
|
||||
/// <param name="candidate">รหัสผู้สมัคร</param>
|
||||
/// <returns></returns>
|
||||
/// <response code="200">เมื่อทำการดึง ข้อมูล ประวัติการศีกษา ผู้สมัคร สำเร็จ</response>
|
||||
/// <response code="401">ไม่ได้ Login เข้าระบบ</response>
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
using BMA.EHR.Recurit.Exam.Service.Core;
|
||||
using BMA.EHR.Recurit.Exam.Service.Data;
|
||||
using BMA.EHR.Recurit.Exam.Service.Models;
|
||||
using BMA.EHR.Recurit.Exam.Service.Response;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace BMA.EHR.Recurit.Exam.Service.Services
|
||||
|
|
@ -170,6 +171,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Services
|
|||
})
|
||||
.FirstOrDefaultAsync();
|
||||
}
|
||||
|
||||
public async Task<CandidateOccupationResponseItem?> GetsAsyncOccupation(string candidateId)
|
||||
{
|
||||
return await _context.Candidates.AsQueryable()
|
||||
|
|
@ -185,13 +187,6 @@ namespace BMA.EHR.Recurit.Exam.Service.Services
|
|||
})
|
||||
.FirstOrDefaultAsync();
|
||||
}
|
||||
public async Task<IEnumerable<Career?>> GetsAsyncCareer(string candidateId)
|
||||
{
|
||||
return await _context.Careers.AsQueryable()
|
||||
.Where(x => x.Id == Guid.Parse(candidateId))
|
||||
.OrderBy(d => d.DurationStart)
|
||||
.ToListAsync();
|
||||
}
|
||||
|
||||
public async Task<CandidateAddressResponseItem?> GetsAsyncAddress(string candidateId)
|
||||
{
|
||||
|
|
@ -219,6 +214,7 @@ namespace BMA.EHR.Recurit.Exam.Service.Services
|
|||
})
|
||||
.FirstOrDefaultAsync();
|
||||
}
|
||||
|
||||
public async Task<CandidateFamilyResponseItem?> GetsAsyncFamily(string candidateId)
|
||||
{
|
||||
return await _context.Candidates.AsQueryable()
|
||||
|
|
@ -247,12 +243,9 @@ namespace BMA.EHR.Recurit.Exam.Service.Services
|
|||
})
|
||||
.FirstOrDefaultAsync();
|
||||
}
|
||||
|
||||
public async Task<IEnumerable<Education?>> GetsAsyncEducation(string candidateId)
|
||||
{
|
||||
|
||||
var candidate = await _context.Candidates.AsQueryable()
|
||||
.FirstOrDefaultAsync(x => x.PeriodExam == exam && x.UserId == UserId);
|
||||
|
||||
return await _context.Educations.AsQueryable()
|
||||
.Include(x => x.EducationLevel)
|
||||
.Where(x => x.Id == Guid.Parse(candidateId))
|
||||
|
|
@ -260,6 +253,14 @@ namespace BMA.EHR.Recurit.Exam.Service.Services
|
|||
.ToListAsync();
|
||||
}
|
||||
|
||||
public async Task<IEnumerable<Career?>> GetsAsyncCareer(string candidateId)
|
||||
{
|
||||
return await _context.Careers.AsQueryable()
|
||||
.Where(x => x.Id == Guid.Parse(candidateId))
|
||||
.OrderBy(d => d.DurationStart)
|
||||
.ToListAsync();
|
||||
}
|
||||
|
||||
|
||||
#endregion
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue