/// <summary> /// 报告单赋值 /// </summary> /// <param name="dr"></param> public void m_mthSetreportvalue(DataRow dr) { //年龄 DateTime dteBirth = Convert.ToDateTime(dr["birth_dat"].ToString()); string age = com.digitalwave.controls.clsArithmetic.CalcAge(dteBirth); applyid = dr["applyid_vchr"].ToString(); m_strApplyId = applyid; this.m_objViewer.lblRepNO.Text = "NO: " + applyid; this.m_objViewer.lblRepName.Text = dr["name_vchr"].ToString(); this.m_objViewer.lblRepSex.Text = dr["sex_chr"].ToString(); this.m_objViewer.lblRepAge.Text = age; this.m_objViewer.lblRepCardNo.Text = dr["patientcardid_chr"].ToString(); this.m_objViewer.lblRepDept.Text = dr["deptname_vchr"].ToString(); DataTable dt = new DataTable(); long ret = objSvc.m_lngGetopsrecord(applyid, out dt); if (dt.Rows.Count == 1) { //手术时间 string opsdate = ((DateTime)dt.Rows[0]["opsdate_dat"]).ToString("yyyy-MM-dd"); //麻醉方式 int index = 0; string anamodecode = dt.Rows[0]["opsanamode_chr"].ToString(); for (int i = 0; i < anamode.Length; i++) { if (anamodecode == anamode[i]) { index = i; break; } } this.m_objViewer.lblRepYear.Text = opsdate.Substring(0, 4); this.m_objViewer.lblRepMonth.Text = opsdate.Substring(5, 2); this.m_objViewer.lblRepDay.Text = opsdate.Substring(8, 2); this.m_objViewer.txtRepOPSName.Text = dt.Rows[0]["opsname_vchr"].ToString(); this.m_objViewer.txtRepDiagbegin.Text = dt.Rows[0]["prediagnoses_vchr"].ToString(); this.m_objViewer.txtRepDiagend.Text = dt.Rows[0]["enddiagnoses_vchr"].ToString(); this.m_objViewer.txtRepMaindoctor.Tag = dt.Rows[0]["opsdoctor_chr"].ToString(); this.m_objViewer.txtRepMaindoctor.Text = m_intGetEmployeeNameInfoByID(" empid_chr ='" + dt.Rows[0]["opsdoctor_chr"].ToString() + "'"); this.m_objViewer.txtRepAssidoctor.Tag = dt.Rows[0]["opsassistant1_chr"].ToString(); this.m_objViewer.txtRepAssidoctor.Text = m_intGetEmployeeNameInfoByID(" empid_chr ='" + dt.Rows[0]["opsassistant1_chr"].ToString() + "'"); this.m_objViewer.txtRepMedtool.Tag = dt.Rows[0]["opsappliance_chr"].ToString(); this.m_objViewer.txtRepMedtool.Text = m_intGetEmployeeNameInfoByID(" empid_chr ='" + dt.Rows[0]["opsappliance_chr"].ToString() + "'"); this.m_objViewer.cboAnamode.SelectedIndex = index; this.m_objViewer.txtRepAnadoctor.Tag = dt.Rows[0]["anaemp1_chr"].ToString(); this.m_objViewer.txtRepAnadoctor.Text = m_intGetEmployeeNameInfoByID(" empid_chr ='" + dt.Rows[0]["anaemp1_chr"].ToString() + "'"); this.m_objViewer.txtRepOPSStepandResult.Text = dt.Rows[0]["opsresult_vchr"].ToString(); this.m_objViewer.txtRepDoctor.Tag = dt.Rows[0]["signdoctor_chr"].ToString(); this.m_objViewer.txtRepDoctor.Text = m_intGetEmployeeNameInfoByID(" empid_chr ='" + dt.Rows[0]["signdoctor_chr"].ToString() + "'"); this.m_objViewer.txtRepSigndate.Text = ((DateTime)dt.Rows[0]["signdate_dat"]).ToString("yyyy-MM-dd"); if (dt.Rows[0]["status_int"].ToString().Trim() == "1") { this.m_objViewer.lblRepsave.Text = "已审核"; } else { this.m_objViewer.lblRepsave.Text = "已保存"; } } else { this.m_objViewer.lblRepYear.Text = ""; this.m_objViewer.lblRepMonth.Text = ""; this.m_objViewer.lblRepDay.Text = ""; this.m_objViewer.txtRepOPSName.Text = dr["itemname_vchr"].ToString(); strOPSName = this.m_objViewer.txtRepOPSName.Text; this.m_objViewer.txtRepDiagbegin.Text = ""; this.m_objViewer.txtRepDiagend.Text = ""; this.m_objViewer.txtRepMaindoctor.Text = ""; this.m_objViewer.txtRepAssidoctor.Text = ""; this.m_objViewer.txtRepMedtool.Text = ""; this.m_objViewer.cboAnamode.SelectedIndex = 0; this.m_objViewer.txtRepAnadoctor.Text = ""; this.m_objViewer.txtRepOPSStepandResult.Text = ""; this.m_objViewer.txtRepDoctor.Tag = this.m_objViewer.LoginInfo.m_strEmpID; this.m_objViewer.txtRepDoctor.Text = this.m_objViewer.LoginInfo.m_strEmpName; this.m_objViewer.txtRepSigndate.Text = DateTime.Now.ToString("yyyy-MM-dd"); this.m_objViewer.lblRepsave.Text = ""; } this.m_mthSelectBill(1); billflag = 1; }