/// <summary> /// 设置时间提示信息 /// </summary> /// <param name="currentEmrModel"></param> /// <param name="firstEmrModel"></param> private void ComputeDateTime(EmrModel currentEmrModel, EmrModel firstEmrModel, List <EmrModel> modelList) { try { if (null != currentEmrModel && null != firstEmrModel) { if (currentEmrModel.FirstDailyEmrModel) {///修改的病历是首程 m_MinDateTime = DS_BaseService.GetInHostTime((int)m_App.CurrentPatientInfo.NoOfFirstPage); this.labelControlTip.Text = "病程时间应大于入院时间 " + m_MinDateTime.ToString("yyyy-MM-dd HH:mm:ss"); EmrModel firstModel = modelList.Where(p => !p.FirstDailyEmrModel).OrderByDescending(q => q.DisplayTime).FirstOrDefault(); if (null != firstModel) { m_MaxDateTime = firstModel.DisplayTime; this.labelControlTip.Text += ",小于下一个病历时间 " + firstModel.DisplayTime.ToString("yyyy-MM-dd HH:mm:ss") + "。"; } } else {///修改的病历不是首程 m_MinDateTime = firstEmrModel.DisplayTime; this.labelControlTip.Text = "病程时间应大于首次病程时间 " + m_MinDateTime.ToString("yyyy-MM-dd HH:mm:ss"); } } else { m_MinDateTime = DS_BaseService.GetInHostTime((int)m_App.CurrentPatientInfo.NoOfFirstPage); this.labelControlTip.Text = "病程时间应大于入院时间 " + m_MinDateTime.ToString("yyyy-MM-dd HH:mm:ss"); } } catch (Exception ex) { throw ex; } }