/// <summary> /// 获取所有数据元 /// </summary> private void GetAllDataElement() { try { //将所有数据元都取出来 需要改进 点find按钮是获取 DataElementEntity dataElementEntity = new DataElementEntity(); dataElementEntity.ElementId = ""; dataElementEntity.ElementName = ""; dataElementEntity.ElementPYM = ""; dataElementEntity.ElementClass = ""; DataElemntBiz dataElemntBiz = new CommonTableConfig.DataElemntBiz(m_app); if (CommonTabHelper.DataElementListAll == null) { CommonTabHelper.DataElementListAll = dataElemntBiz.GetDataElement(dataElementEntity); } repositoryItemSearchLookUpEdit1.DataSource = CommonTabHelper.DataElementListAll; } catch (Exception ex) { throw ex; } }
//初始化界面的 后台 private void InitData() { inCommonNoteBiz.GetDetaliInCommonNoteByDay(ref m_inCommonNote, ref m_InCommonNoteTab, "", ""); if (m_InCommonNoteTab.InCommonNoteItemList == null || m_InCommonNoteTab.InCommonNoteItemList.Count == 0) { m_InCommonNoteTab.InCommonNoteItemList = InCommonNoteBiz.ConvertItem(m_commonNote_TabEntity); foreach (var item in m_InCommonNoteTab.InCommonNoteItemList) { item.InCommonNote_Tab_Flow = m_InCommonNoteTab.InCommonNote_Tab_Flow; item.InCommonNoteFlow = m_InCommonNoteTab.InCommonNoteFlow; item.CreateDoctorID = m_app.User.DoctorId; item.CreateDoctorName = m_app.User.DoctorName; //item.InCommonNote_Item_Flow = Guid.NewGuid().ToString(); item.RecordDate = DateUtil.getDateTime(System.DateTime.Now.ToString(), DateUtil.NORMAL_SHORT); item.RecordTime = DateUtil.getDateTime(System.DateTime.Now.ToString(), DateUtil.NORMAL_LONG).Substring(11, 8); item.RecordDoctorName = m_app.User.DoctorName; } } scorlInfo.Controls.Clear(); for (int i = 0; i < m_InCommonNoteTab.InCommonNoteItemList.Count; i++) { List <InCommonNoteItemEntity> inCommonNoteItemEntityList = m_InCommonNoteTab.InCommonNoteItemList; if (i == 0) { //记录时间 UCRecordDateTime uCRecordDateTime = new UCRecordDateTime(inCommonNoteItemEntityList[i].RecordDate, inCommonNoteItemEntityList[i].RecordTime); point = new Point(0, 0); uCRecordDateTime.Location = point; uCRecordDateTime.Name = "uCRecordDateTime"; scorlInfo.Controls.Add(uCRecordDateTime); } if (inCommonNoteItemEntityList[i].DataElement == null) { DataElemntBiz dataElemntBiz = new CommonTableConfig.DataElemntBiz(m_app); var dateelement = dataElemntBiz.GetDataElement(inCommonNoteItemEntityList[i].DataElementFlow); inCommonNoteItemEntityList[i].DataElement = dateelement; } //项目 ucLabText ucLabText = new ucLabText(inCommonNoteItemEntityList[i]); ucLabText.Height = 40; ucLabText.Width = 319; int row = (i + 1) / 3; int colmn = (i + 1) % 3; point.X = ucLabText.Width * colmn; point.Y = ucLabText.Height * row; ucLabText.Location = point; scorlInfo.Controls.Add(ucLabText); if (i == inCommonNoteItemEntityList.Count - 1) { // 记录人 UCRecordDoctor uCRecordDoctor = new UCRecordDoctor(inCommonNoteItemEntityList[i].RecordDoctorName); uCRecordDoctor.Height = 40; uCRecordDoctor.Width = 319; uCRecordDoctor.Name = "uCRecordDoctor"; int row1 = (i + 2) / 3; int colmn1 = (i + 2) % 3; point.X = uCRecordDoctor.Width * colmn1; point.Y = uCRecordDoctor.Height * row1; uCRecordDoctor.Location = point; scorlInfo.Controls.Add(uCRecordDoctor); } } }