/// <summary> /// 修改 /// </summary> /// <returns></returns> private long m_lngModify() { long lngRes = 0; try { //从界面获取表单值 clsCourseDiseasesRecord objContent = new clsCourseDiseasesRecord(); objContent.m_strInPatientID = strRecordInPatientID; objContent.m_dtmInPatientDate = DateTime.Parse(strRecordInPatientDate); objContent.m_dtmOpenDate = DateTime.Now; objContent.m_dtmCreateDate = DateTime.Parse(strRecordCreateDate); objContent.m_strDiseasesRecordContent = m_txtRecordContent.Text; objContent.m_strDiseasesRecordContentXml = m_txtRecordContent.m_strGetXmlText(); //签名 //foreach(Control ctlSub in this.Controls) //{ // if(ctlSub.Name=="m_txtSign") // { objContent.m_strModifyUserID = ((clsEmrEmployeeBase_VO)txtSign.Tag).m_strEMPNO_CHR; // } //} clsIntensiveTendRecordService objserv = new clsIntensiveTendRecordService(); //电子签名 //记录ID通常为 住院号+住院时间 || 住院号+记录时间 来识别唯一 格式 00000056-2005-10-10 10:20:20 clsEmrDigitalSign_VO objSign_VO = new clsEmrDigitalSign_VO(); objSign_VO.m_strFORMID_VCHR = this.Name; objSign_VO.m_strFORMRECORDID_VCHR = objContent.m_strInPatientID.Trim() + "-" + objContent.m_dtmInPatientDate.ToString("yyyy-MM-dd HH:mm:ss"); objSign_VO.m_strSIGNIDID_VCHR = clsEMRLogin.LoginInfo.m_strEmpID; objSign_VO.m_strRegisterId = m_objBaseCurrentPatient.m_StrRegisterId; clsCheckSignersController objCheck = new clsCheckSignersController(); if (objCheck.m_lngSign(objContent, objSign_VO) == -1) { return(-1); } lngRes = objserv.m_lngModifyRecordContent(objContent); } catch (Exception ex) { string strMsg = ex.Message; } return(lngRes); }
protected override void m_mthSetDeletedGUIFromContent(iCareData.clsTrackRecordContent p_objContent) { clsCourseDiseasesRecord objContent = (clsCourseDiseasesRecord)p_objContent; //把表单值赋值到界面,由子窗体重载实现 this.m_mthClearRecordInfo(); //赋值到表单 m_txtRecordContent.m_mthSetNewText(objContent.m_strDiseasesRecordContent, objContent.m_strDiseasesRecordContentXml); m_dtpCreateDate.Value = objContent.m_dtmCreateDate; clsEmployee objEmployee = new clsEmployee(objContent.m_strModifyUserID); if (objEmployee != null) { txtSign.Text = objEmployee.m_StrLastName; txtSign.Tag = objEmployee; } this.txtSign.Enabled = false; this.m_dtpCreateDate.Enabled = false; }
/// <summary> /// 保存 /// </summary> /// <returns></returns> private long m_lngSave() { long lngRes = 0; try { //获取服务器时间 string strTimeNow = new clsPublicDomain().m_strGetServerTime(); //从界面获取表单值 clsCourseDiseasesRecord objContent = new clsCourseDiseasesRecord(); objContent.m_strInPatientID = strRecordInPatientID; objContent.m_dtmInPatientDate = DateTime.Parse(strRecordInPatientDate); objContent.m_dtmOpenDate = DateTime.Parse(strTimeNow); objContent.m_dtmCreateDate = m_dtpCreateDate.Value; objContent.m_strDiseasesRecordContent = m_txtRecordContent.Text; //objContent.m_strRecordContent_Right = m_txtRecordContent.m_strGetRightText(); objContent.m_strDiseasesRecordContentXml = m_txtRecordContent.m_strGetXmlText(); objContent.m_strClass = GetClassWith(m_dtpCreateDate.Value); objContent.m_strModifyUserID = ((clsEmrEmployeeBase_VO)txtSign.Tag).m_strEMPNO_CHR; objContent.m_strCreateUserID = ((clsEmrEmployeeBase_VO)txtSign.Tag).m_strEMPNO_CHR; clsIntensiveTendRecordService objserv = new clsIntensiveTendRecordService(); //电子签名 //记录ID通常为 住院号+住院时间 || 住院号+记录时间 来识别唯一 格式 00000056-2005-10-10 10:20:20 clsEmrDigitalSign_VO objSign_VO = new clsEmrDigitalSign_VO(); objSign_VO.m_strFORMID_VCHR = this.Name; objSign_VO.m_strFORMRECORDID_VCHR = objContent.m_strInPatientID.Trim() + "-" + objContent.m_dtmInPatientDate.ToString("yyyy-MM-dd HH:mm:ss");; objSign_VO.m_strSIGNIDID_VCHR = clsEMRLogin.LoginInfo.m_strEmpID; objSign_VO.m_strRegisterId = m_objBaseCurrentPatient.m_StrRegisterId; clsCheckSignersController objCheck = new clsCheckSignersController(); if (objCheck.m_lngSign(objContent, objSign_VO) == -1) { return(-1); } lngRes = objserv.m_lngAddNewRecordContent(objContent); } catch (Exception ex) { string strMsg = ex.Message; } return(lngRes); }