Exemplo n.º 1
0
        public void buildOrderResultData(CiOrderDO ciorderdo, XCellRender cell)
        {
            ICiorderMDOCrudService orderService = XapServiceMgr.find <ICiorderMDOCrudService>();
            CiOrderDO dborderdo = orderService.findById(ciorderdo.Id_or);

            if (dborderdo == null)
            {
                ciorderdo.SetDeleted();
                return;
            }
            ciorderdo.Eu_hpindicjudge = dborderdo.Eu_hpindicjudge;
            ciorderdo.Eu_uncporjudge  = dborderdo.Eu_uncporjudge;
            List <XOrderResultData> resultList = cell.Value as List <XOrderResultData>;

            //LogicEx.GetInstance().getHpXOrderResultData(ciorderdo, resultList[0]);
            //LogicEx.GetInstance().getCporHpXOrderResultData(ciorderdo, resultList[1]);
            cell.Value = OrReportPictureButton.GetInstance().buildOrderResultData(dborderdo);
        }
Exemplo n.º 2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected virtual void XapFormControl_FormCreated(object sender, EventArgs e)
        {
            // 初始化医嘱组件
            string path = Application.StartupPath + "\\modules\\iihci\\ui\\commoncontent\\OrderContent.xml";

            doctorOrderConfig = this.Deserialize(path);

            gv = this.xapFormControl1.GetGridView("order");
            gv.DataTable.DataDisplay            += tabControl_DataDisplay;
            gv.DataTable.CustomerCellMouseClick += OnXapFromGrid_CellClick;
            gv.DataTable.MultiCheckChanged      += new EventHandler <MutilCheckedEventArgs>(mutilCheckedEventArgs);
            gv.DataTable.SelectedAllChanged     += new EventHandler(SelectedAllChanged);
            gv.MouseClick                  += OnXapFromGrid_MouseClick;
            gv.MouseDoubleClick            += OnXapFromGrid_MouseDoubleClick;
            gv.ReadOnly                     = true;
            gv.DataTable.CrossBackColor     = true;
            gv.DataTable.Rows.DefaultHeight = 30;

            UdidocDO[] udidocs = OrReportPictureButton.GetInstance().getMap()[EnDictCodeConst.SD_ENTP_OUTPATIENT];
            if (udidocs == null)
            {
                udidocs = new UdidocDO[0];
            }
            int columnWidth = 6 + (2 + RelativeUIParam.RELATIVECELLSIZE.Height) * udidocs.Length;

            columnWidth = columnWidth <= 90 ? 90 : columnWidth;
            gv.DataTable.Columns["customercolumn_check_result"].Width        = columnWidth;
            gv.DataTable.Columns["customercolumn_check_result"].DefalutWidth = columnWidth;

            List <ControlTab> tabs       = xapFormControl1.FormModel.Tabs;
            XTabControl       tabControl = tabs[0].tabContrl;

            tabControl.SelectedChanging     += TabControl_SelectedChanging;
            tabControl.SelectedIndexChanged += tabControl_SelectedIndexChanged;
            XTabPage xtab = tabControl.XTabPages[1];

            this.orderPresView = this.createOrderPresControl();
            xtab.PageControl   = this.orderPresView;
            foreach (XDataColumn item in gv.DataTable.Columns)
            {
                item.AlignCell = StringAlignment.Center;
            }
        }
Exemplo n.º 3
0
        /// <summary>
        /// 设置单元格属性
        /// <para>设置单元格显示内容,绑定事件</para>
        /// </summary>
        /// <param name="cell"></param>
        /// <param name="ciorder"></param>
        private void setCellContent(XCellRender cell, CiOrderDO ciorder)
        {
            if (ciorder.Sd_srvtp == null)
            {
                cell.ValueText = "加载失败,缺少服务分类!";
                return;
            }

            string sd_srvtp = ciorder.Sd_srvtp.Substring(0, 2);

            List <XOrderResultData> resultList = OrReportPictureButton.GetInstance().buildOrderResultData(ciorder);

            cell.Value       = resultList;
            cell.MouseClick += new MouseEventHandler(cell_MouseClick);

            //if (cusotmCellDic.ContainsKey(sd_srvtp))
            //{
            //    cell.ValueObj = ciorder;
            //    cell.ValueText = "报告出具";
            //    cell.MouseClick += new MouseEventHandler(cell_MouseClick);
            //}
        }
Exemplo n.º 4
0
        protected void tabControl_DataDisplay(Object sender, XDataDisplayEventArgs e)
        {
            var row = sender as XDataRow;

            if (row != null)
            {
                foreach (UserRender render in row.UserRenderList)
                {
                    if (render is DoctorOrderCard)
                    {
                        var card = render as DoctorOrderCard;
                        card.DoctorOrderConfig = this.doctorOrderConfig;
                    }
                }
            }
            if (row != null && row.ColumnCellDict.ContainsKey("customercolumn_check_result"))
            {
                var ciorderdo  = row.RowDataSource as CiOrderDO;
                var resultList = OrReportPictureButton.GetInstance().buildOrderResultData(ciorderdo);
                (row.ColumnCellDict["customercolumn_check_result"] as XCellRender).Value = resultList;
            }
        }