/// <summary> /// 显示信息 /// </summary> /// <param name="obj"></param> private void SetInfo(NineVigor.Domain.HealthRecord.Entity.CasLend obj) { /* * CardNO.Text = obj.CardNO; * txName.Text = obj.EmployeeInfo.Name; * dtContinue.Value = NineVigor.FrameWork.Function.NConvert.ToDateTime(card.GetSysDate()); * dtReturn.Value = NineVigor.FrameWork.Function.NConvert.ToDateTime(card.GetSysDate()); * txReturn.Text = obj.Memo; * */ }
/// <summary> /// /// </summary> /// <param name="obj"></param> /// <returns></returns> private int ValidState(NineVigor.Domain.HealthRecord.Entity.CasLend obj) { /* * if (string.IsNullOrEmpty(caseNo.Text)) * { * MessageBox.Show("请输入借阅卡号"); * return -1; * } * //判断是否已经借出了 * int intCount = 0; * if (string.IsNullOrEmpty(inpationNo)) * { * intCount = idm.GetLendStatusByInpationNo("ZY01" + caseNo.Text); * } * else * { * intCount = idm.GetLendStatusByInpationNo(inpationNo); * } * if (intCount > 0) * { * this.caseNo.SelectAll(); * MessageBox.Show("该病案已经借出."); * return -1; * } * if (string.IsNullOrEmpty(txName.Text)) * { * MessageBox.Show("请输入借阅病案的病人的姓名"); * this.txName.Focus(); * return -1; * } * if (string.IsNullOrEmpty(cl_Sex.Text) || string.IsNullOrEmpty(cl_Sex.Tag.ToString())) * { * MessageBox.Show("请输入借阅病案的病人性别"); * this.cl_Sex.Focus(); * return -1; * } * * if (string.IsNullOrEmpty(cListBoxResonan.Text)) * { * MessageBox.Show("请输入借阅原因"); * this.cListBoxResonan.Focus(); * return -1; * } * * if (string.IsNullOrEmpty(cListBempNo.Text)) * { * MessageBox.Show("请输入借阅人工号"); * this.cListBempNo.Focus(); * return -1; * } * */ return(1); }
/// <summary> /// /// </summary> /// <returns></returns> private NineVigor.Domain.HealthRecord.Entity.CasLend GetLendInfo() { NineVigor.Domain.HealthRecord.Entity.CasLend saveinfo = new NineVigor.Domain.HealthRecord.Entity.CasLend(); /* * string inpatientOldNo = string.Empty; * string inpatientNewNo = string.Empty; * if (string.IsNullOrEmpty(inpationNo)) * { * inpatientOldNo = "ZY01" + "J" + this.caseNo.Text.PadLeft(9, '0'); * inpatientNewNo = "ZY01" + this.caseNo.Text.PadLeft(10, '0'); * } * else * { * inpatientNewNo = inpationNo; * } * * * Neusoft.HISFC.Models.HealthRecord.Base tempObj = new Neusoft.HISFC.Models.HealthRecord.Base(); * Neusoft.HISFC.Models.HealthRecord.Base tempObj1 = this.baseDml.GetCaseBaseInfo(inpatientNewNo); * Neusoft.HISFC.Models.HealthRecord.Base tempObj2 = this.baseDml.GetCaseBaseInfo(inpatientOldNo); * Neusoft.HISFC.Models.HealthRecord.Lend Saveinfo = new Neusoft.HISFC.Models.HealthRecord.Lend(); * if (!string.IsNullOrEmpty(tempObj1.PatientInfo.ID)) * tempObj = tempObj1; * else * tempObj = tempObj2; * * if (!string.IsNullOrEmpty(tempObj.PatientInfo.ID)) * { * Saveinfo.SeqNO = this.card.GetSequence("Case.CaseCard.LendCase.Seq"); * if (Saveinfo.SeqNO == null || Saveinfo.SeqNO == "") * { * MessageBox.Show("获取序号失败"); * return null; * } * * * Saveinfo.CaseBase.PatientInfo.ID = tempObj.PatientInfo.ID;//住院流水号 * Saveinfo.CaseBase.CaseNO = tempObj.CaseNO;//病人住院号 * Saveinfo.CaseBase.PatientInfo.Name = tempObj.PatientInfo.Name; //病人姓名 * Saveinfo.CaseBase.PatientInfo.Sex.ID = tempObj.PatientInfo.Sex.ID;//性别 * Saveinfo.CaseBase.PatientInfo.Birthday = tempObj.PatientInfo.Birthday;//出生日期 * Saveinfo.CaseBase.PatientInfo.PVisit.InTime = tempObj.PatientInfo.PVisit.InTime;//入院日期 * Saveinfo.CaseBase.PatientInfo.PVisit.OutTime = tempObj.PatientInfo.PVisit.OutTime;//出院日期 * Saveinfo.CaseBase.InDept.ID = tempObj.InDept.ID; //入院科室代码 * Saveinfo.CaseBase.InDept.Name = tempObj.InDept.Name; //入院科室名称 * Saveinfo.CaseBase.OutDept.ID = tempObj.OutDept.ID; //出院科室代码 * Saveinfo.CaseBase.OutDept.Name = tempObj.OutDept.Name; //出院科室名称 * if (this.cListBempNo.Tag != null) * { * Saveinfo.EmployeeInfo.ID = this.cListBempNo.Tag.ToString();//借阅人代号 * } * Saveinfo.EmployeeInfo.Name = this.cListBempNo.Text;//借阅人姓名 * * try * { * Saveinfo.EmployeeDept.ID = ht[Saveinfo.EmployeeInfo.ID].ToString(); //借阅人所在科室代码 * Saveinfo.EmployeeDept.Name = deptHelper.GetName(Saveinfo.EmployeeDept.ID); //借阅人所在科室名称 * } * catch (Exception ex) * { * * } * Saveinfo.LendDate = Neusoft.FrameWork.Function.NConvert.ToDateTime(baseDml.GetSysDateTime()); //借阅日期 * Saveinfo.PrerDate = txReturnTime.Value; //预定还期 * * //省医默认写死 内借 * Saveinfo.LendKind = "1"; ; //借阅性质 * * Saveinfo.LendStus = "1"; ;//病历状态 1借出/2返还 * Saveinfo.ID = baseDml.Operator.ID; //操作员代号 * Saveinfo.OperInfo.OperTime = Neusoft.FrameWork.Function.NConvert.ToDateTime(baseDml.GetSysDateTime()); //操作时间 * Saveinfo.ReturnOperInfo.ID = ""; //归还操作员代号 * Saveinfo.ReturnDate = Neusoft.FrameWork.Function.NConvert.ToDateTime("3000-1-1"); //实际归还日期 * Saveinfo.CardNO = Saveinfo.EmployeeInfo.ID;//卡号 * //备注-借阅原因-电话 * Saveinfo.Remark = this.neuTextBox1.Text; * if (cListBoxResonan.Tag != null) * { * Saveinfo.LendReason = cListBoxResonan.Tag.ToString(); * } * Saveinfo.EmplTel = this.neuTxbTelphone.Text; * } * else * { * Saveinfo.SeqNO = this.card.GetSequence("Case.CaseCard.LendCase.Seq"); * if (Saveinfo.SeqNO == null || Saveinfo.SeqNO == "") * { * MessageBox.Show("获取序号失败"); * return null; * } * Saveinfo.LendDate = Neusoft.FrameWork.Function.NConvert.ToDateTime(baseDml.GetSysDateTime()); //借阅日期 * Saveinfo.PrerDate = txReturnTime.Value; //预定还期 * if (this.cListBempNo.Tag != null) * { * Saveinfo.EmployeeInfo.ID = this.cListBempNo.Tag.ToString();//借阅人代号 * } * Saveinfo.EmployeeInfo.Name = this.cListBempNo.Text;//借阅人姓名 * try * { * Saveinfo.EmployeeDept.ID = ht[Saveinfo.EmployeeInfo.ID].ToString(); //借阅人所在科室代码 * Saveinfo.EmployeeDept.Name = deptHelper.GetName(Saveinfo.EmployeeDept.ID); //借阅人所在科室名称 * } * catch (Exception ex) * { * * } * * Saveinfo.CaseBase.CaseNO = this.caseNo.Text; * //省医默认写死 内借 * Saveinfo.LendKind = "1"; ; //借阅性质 * * Saveinfo.LendStus = "1"; ;//病历状态 1借出/2返还 * Saveinfo.ID = baseDml.Operator.ID; //操作员代号 * Saveinfo.OperInfo.OperTime = Neusoft.FrameWork.Function.NConvert.ToDateTime(baseDml.GetSysDateTime()); //操作时间 * Saveinfo.ReturnOperInfo.ID = ""; //归还操作员代号 * Saveinfo.ReturnDate = Neusoft.FrameWork.Function.NConvert.ToDateTime("3000-1-1"); //实际归还日期 * Saveinfo.CardNO = Saveinfo.EmployeeInfo.ID;//卡号 * * if (string.IsNullOrEmpty(inpationNo)) * { * Saveinfo.CaseBase.PatientInfo.ID = "ZY01" + caseNo.Text.Trim();//住院流水号 * } * else * { * Saveinfo.CaseBase.PatientInfo.ID =inpationNo;//住院流水号 * } * * Saveinfo.CaseBase.PatientInfo.Name = this.txName.Text; //病人姓名 * if (this.cl_Sex.Tag != null) * { * Saveinfo.CaseBase.PatientInfo.Sex.ID = this.cl_Sex.Tag.ToString();//性别 * } * * Saveinfo.Remark = this.neuTextBox1.Text; * if (cListBoxResonan.Tag != null) * { * Saveinfo.LendReason = cListBoxResonan.Tag.ToString(); * } * Saveinfo.EmplTel = this.neuTxbTelphone.Text; * } * */ return(saveinfo); }