|
|
|
@ -130,26 +130,40 @@ namespace Shentun.Peis.ThirdBookings |
|
|
|
if (string.IsNullOrWhiteSpace(input.BookingDate)) |
|
|
|
throw new UserFriendlyException("日期不能为空"); |
|
|
|
|
|
|
|
var thirdBookingEnt = new ThirdBooking(GuidGenerator.Create()) |
|
|
|
if (!string.IsNullOrWhiteSpace(input.MaritalStatus) |
|
|
|
&& input.MaritalStatus != "0" |
|
|
|
&& input.MaritalStatus != "1") |
|
|
|
{ |
|
|
|
throw new UserFriendlyException("婚姻状况格式不正确"); |
|
|
|
} |
|
|
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(input.EmpStatus) |
|
|
|
&& input.EmpStatus != "0" |
|
|
|
&& input.EmpStatus != "1") |
|
|
|
{ |
|
|
|
Age = input.Age, |
|
|
|
BookingDate = Convert.ToDateTime(input.BookingDate), |
|
|
|
ChildCompanyName = input.ChildCompanyName, |
|
|
|
CustomerOrgGroupId = input.CustomerOrgGroupId, |
|
|
|
DepartmentName = input.DepartmentName, |
|
|
|
EmpStatus = input.EmpStatus, |
|
|
|
ICode = "", |
|
|
|
IdNo = input.IdNo, |
|
|
|
IdType = "0", |
|
|
|
MaritalStatus = input.MaritalStatus, |
|
|
|
MedicalStatus = '0', |
|
|
|
PatientName = input.PatientName, |
|
|
|
Phone = input.Phone, |
|
|
|
PositionName = input.PositionName, |
|
|
|
SexName = input.SexName, |
|
|
|
SourceChannel = "1", |
|
|
|
ThirdMedicalCenterId = input.ThirdMedicalCenterId |
|
|
|
}; |
|
|
|
throw new UserFriendlyException("是否在职格式不正确"); |
|
|
|
} |
|
|
|
|
|
|
|
var thirdBookingEnt = new ThirdBooking(GuidGenerator.Create()) |
|
|
|
{ |
|
|
|
Age = input.Age, |
|
|
|
BookingDate = Convert.ToDateTime(input.BookingDate), |
|
|
|
ChildCompanyName = input.ChildCompanyName, |
|
|
|
CustomerOrgGroupId = input.CustomerOrgGroupId, |
|
|
|
DepartmentName = input.DepartmentName, |
|
|
|
EmpStatus = input.EmpStatus, |
|
|
|
ICode = "", |
|
|
|
IdNo = input.IdNo, |
|
|
|
IdType = "0", |
|
|
|
MaritalStatus = input.MaritalStatus, |
|
|
|
MedicalStatus = '0', |
|
|
|
PatientName = input.PatientName, |
|
|
|
Phone = input.Phone, |
|
|
|
PositionName = input.PositionName, |
|
|
|
SexName = input.SexName, |
|
|
|
SourceChannel = "1", |
|
|
|
ThirdMedicalCenterId = input.ThirdMedicalCenterId |
|
|
|
}; |
|
|
|
|
|
|
|
await _thirdBookingRepository.InsertAsync(thirdBookingEnt); |
|
|
|
|
|
|
|
|