| | |
| | | ws.Cells["M28"].Value = Identity2["Score"].ToString(); |
| | | ws.Cells["M29"].Value = Identity3["Score"].ToString(); |
| | | ws.Cells["N27"].Value = Patient1X["Score"].ToString(); |
| | | ws.Cells["N28"].Value = Patient1Y["Score"].ToString(); |
| | | ws.Cells["N29"].Value = Patient1Z["Score"].ToString(); |
| | | ws.Cells["O27"].Value = Patient2X["Score"].ToString(); |
| | | ws.Cells["N28"].Value = Patient2X["Score"].ToString(); |
| | | ws.Cells["N29"].Value = Patient3X["Score"].ToString(); |
| | | ws.Cells["O27"].Value = Patient1X["Score"].ToString(); |
| | | ws.Cells["O28"].Value = Patient2Y["Score"].ToString(); |
| | | ws.Cells["O29"].Value = Patient2Z["Score"].ToString(); |
| | | ws.Cells["P27"].Value = Patient3X["Score"].ToString(); |
| | | ws.Cells["P28"].Value = Patient3Y["Score"].ToString(); |
| | | ws.Cells["O29"].Value = Patient3Y["Score"].ToString(); |
| | | ws.Cells["P27"].Value = Patient1Z["Score"].ToString(); |
| | | ws.Cells["P28"].Value = Patient2Z["Score"].ToString(); |
| | | ws.Cells["P29"].Value = Patient3Z["Score"].ToString(); |
| | | ws.Cells["Q27"].Value = ZhiKang1["Score"].ToString(); |
| | | ws.Cells["Q28"].Value = ZhiKang2["Score"].ToString(); |
| | |
| | | ws.Cells["X10"].Value = RH1["RealValue"].ToString(); |
| | | ws.Cells["X14"].Value = RH2["RealValue"].ToString(); |
| | | ws.Cells["X18"].Value = RH3["RealValue"].ToString(); |
| | | |
| | | ws.Cells["Y10"].Value = ZhiKang1["RealValue"].ToString(); |
| | | ws.Cells["Y14"].Value = ZhiKang2["RealValue"].ToString(); |
| | | ws.Cells["Y18"].Value = ZhiKang3["RealValue"].ToString(); |
| | | |
| | | ws.Cells["Y11"].Value = ZhiKang1["StandValue"].ToString(); |
| | | ws.Cells["Y15"].Value = ZhiKang2["StandValue"].ToString(); |
| | | ws.Cells["Y19"].Value = ZhiKang3["StandValue"].ToString(); |
| | | |
| | | |
| | | double Page3_1 = 0; |
| | | double Page3_2 = 0; |
| | |
| | | LogHelper.Debug("准备保存对象:" + qcDistributionRegister.AnswerJSON); |
| | | if (qcDistributionRegister.Id == 0) |
| | | { |
| | | var existing = _qcDistributionRegisters.Table.FirstOrDefault( |
| | | p => p.QCDistributionId == qcDistributionRegister.QCDistributionId |
| | | && p.LabId == qcDistributionRegister.LabId |
| | | && p.ProjectId == qcDistributionRegister.ProjectId); |
| | | if (existing != null) |
| | | { |
| | | MergeRegisterInfo(existing, qcDistributionRegister); |
| | | _qcDistributionRegisters.Update(existing); |
| | | qcDistributionRegister.Id = existing.Id; |
| | | LogHelper.Error(string.Format( |
| | | "SaveQcDistributionRegister 命中已有行 Id={0}(入参 Id=0),已重定向 UPDATE:QCDist={1}, Lab={2}, Project={3}。上层必定漏做查重或前端提交了脏 Id,必须排查根因。", |
| | | existing.Id, |
| | | qcDistributionRegister.QCDistributionId, |
| | | qcDistributionRegister.LabId, |
| | | qcDistributionRegister.ProjectId)); |
| | | return; |
| | | } |
| | | _qcDistributionRegisters.Insert(qcDistributionRegister); |
| | | } |
| | | else |
| | |
| | | _qcDistributionRegisters.Update(qcDistributionRegister); |
| | | } |
| | | } |
| | | |
| | | private static void MergeRegisterInfo(QCDistributionRegisterInfo target, QCDistributionRegisterInfo source) |
| | | { |
| | | if (!string.IsNullOrEmpty(source.LetterNo)) target.LetterNo = source.LetterNo; |
| | | if (!string.IsNullOrEmpty(source.ChargeRemark)) target.ChargeRemark = source.ChargeRemark; |
| | | if (!string.IsNullOrEmpty(source.SampleNo)) target.SampleNo = source.SampleNo; |
| | | if (!string.IsNullOrEmpty(source.EMSNo)) target.EMSNo = source.EMSNo; |
| | | if (!string.IsNullOrEmpty(source.PacketContent)) target.PacketContent = source.PacketContent; |
| | | if (!string.IsNullOrEmpty(source.Remark)) target.Remark = source.Remark; |
| | | if (!string.IsNullOrEmpty(source.ModifyUser)) target.ModifyUser = source.ModifyUser; |
| | | if (!string.IsNullOrEmpty(source.AnswerJSON)) target.AnswerJSON = source.AnswerJSON; |
| | | if (!string.IsNullOrEmpty(source.SubmitUserNo)) target.SubmitUserNo = source.SubmitUserNo; |
| | | if (!string.IsNullOrEmpty(source.Score_Detail)) target.Score_Detail = source.Score_Detail; |
| | | if (source.ChargeTime.HasValue) target.ChargeTime = source.ChargeTime; |
| | | if (source.SendEMSTime.HasValue) target.SendEMSTime = source.SendEMSTime; |
| | | if (source.SubmitTime.HasValue) target.SubmitTime = source.SubmitTime; |
| | | if (source.FirstTimeSubmitTime.HasValue) target.FirstTimeSubmitTime = source.FirstTimeSubmitTime; |
| | | if (source.LastPageModifyTime.HasValue) target.LastPageModifyTime = source.LastPageModifyTime; |
| | | if (source.ModifyTime != default(DateTime)) target.ModifyTime = source.ModifyTime; |
| | | if (source.IsCharged) target.IsCharged = true; |
| | | if (source.IsSendEMS) target.IsSendEMS = true; |
| | | if (source.IsSubmit) target.IsSubmit = true; |
| | | if (source.IsModified) target.IsModified = true; |
| | | if (source.IsEnding) target.IsEnding = true; |
| | | } |
| | | public QCDistributionRegisterInfo GetNextOneQCDistRegInfo(QCDistributionRegisterInfo prevRegInfo) |
| | | { |
| | | var results = this.GetQcDistributionRegisters() |