示例#1
0
 /// <summary>
 /// 设置应用程序图标
 /// </summary>
 /// <param name="frm"></param>
 public void SetApplicationIco(Form frm)
 {
     frm.Icon = CommonFunctions.ApplicationIcon();
 }
示例#2
0
        /// <summary>
        ///
        /// </summary>
        private void QueryResult()
        {
            string SQLString = string.Empty;

            SQLString = string.Format(@"SELECT  center_id ,
                                                    hosp_code ,
                                                    ( SELECT    Value
                                                      FROM      HIS_InterfaceHN.dbo.JC_TypeCompareTable
                                                      WHERE     TypeID = 4
                                                                AND Name = HIS_InterfaceHN.dbo.Interface_AddMatch.match_type
                                                    ) AS 'match_type' ,
                                                    hosp_code ,
                                                    hosp_name
                                            FROM    HIS_InterfaceHN.dbo.Interface_AddMatch
                                            WHERE   HIS_InterfaceHN.dbo.Interface_AddMatch.ID = {0};

                                            SELECT  HIS_InterfaceHN.dbo.JC_Interface_CenterDir.ID ,
                                                    HIS_InterfaceHN.dbo.JC_Interface_CenterDir.medi_item_type ,
                                                    HIS_InterfaceHN.dbo.JC_Interface_CenterDir.item_code ,
                                                    HIS_InterfaceHN.dbo.JC_Interface_CenterDir.item_name ,
                                                    HIS_InterfaceHN.dbo.JC_Interface_CenterDir.modelID ,
                                                    ( SELECT    Name
                                                      FROM      HIS_InterfaceHN.dbo.JC_Model
                                                      WHERE     Code = HIS_InterfaceHN.dbo.JC_Interface_CenterDir.modelID
                                                    ) AS 'model' ,
                                                    HIS_InterfaceHN.dbo.JC_Interface_CenterDir.price
                                            FROM    HIS_InterfaceHN.dbo.Interface_AddMatch
                                                    LEFT OUTER JOIN HIS_InterfaceHN.dbo.JC_Interface_CenterDir ON HIS_InterfaceHN.dbo.Interface_AddMatch.hosp_name = HIS_InterfaceHN.dbo.JC_Interface_CenterDir.item_name
                                            WHERE   ( HIS_InterfaceHN.dbo.Interface_AddMatch.ID = {0} )
                                            ORDER BY HIS_InterfaceHN.dbo.Interface_AddMatch.price;", this._AddMatchID);

            try
            {
                DataSet ds = Alif.DBUtility.DbHelperSQL.Query(SQLString);

                this.lblCenterID.Text   = string.Format("中心编码:{0}", ds.Tables[0].Rows[0]["center_id"].ToString().Trim());
                this.lblHospitalID.Text = string.Format("医院编码:{0}", ds.Tables[0].Rows[0]["hosp_code"].ToString().Trim());
                this.lblMatchType.Text  = string.Format("匹配类型:{0}", ds.Tables[0].Rows[0]["match_type"].ToString().Trim());
                this.lblHosp_code.Text  = string.Format("医院目录编码:{0}", ds.Tables[0].Rows[0]["hosp_code"].ToString().Trim());
                this.lblHosp_name.Text  = string.Format("医院目录名称:{0}", ds.Tables[0].Rows[0]["hosp_name"].ToString().Trim());

                this.c1FlexGridSelectDirCompare.DataSource = ds.Tables[1];

                this.c1FlexGridSelectDirCompare.Cols["ID"].Visible      = false;
                this.c1FlexGridSelectDirCompare.Cols["modelID"].Visible = false;

                if (!this.c1FlexGridSelectDirCompare.Cols.Contains("model"))
                {
                    this.c1FlexGridSelectDirCompare.Cols["item_code"].Caption = "中心项目编码";
                    this.c1FlexGridSelectDirCompare.Cols["item_code"].Width   = 110;
                    this.c1FlexGridSelectDirCompare.Cols["item_name"].Caption = "中心项目名称";
                    this.c1FlexGridSelectDirCompare.Cols["item_name"].Width   = 270;
                }
                else
                {
                    this.c1FlexGridSelectDirCompare.Cols["item_code"].Caption = "中心药品编码";
                    this.c1FlexGridSelectDirCompare.Cols["item_code"].Width   = 110;
                    this.c1FlexGridSelectDirCompare.Cols["item_name"].Caption = "中心药品名称";
                    this.c1FlexGridSelectDirCompare.Cols["item_name"].Width   = 160;
                    this.c1FlexGridSelectDirCompare.Cols["model"].Caption     = "剂型";
                    this.c1FlexGridSelectDirCompare.Cols["model"].Width       = 110;
                }

                this.c1FlexGridSelectDirCompare.Cols["price"].Caption = "价格";
                this.c1FlexGridSelectDirCompare.Cols["price"].Width   = 80;

                this.c1FlexGridSelectDirCompare.Cols["medi_item_type"].Caption = "匹配类型";
                this.c1FlexGridSelectDirCompare.Cols["medi_item_type"].Width   = 60;
            }
            catch (Exception ex)
            {
                CommonFunctions.MsgError("查询医院目录编号对应的信息发生错误,错误原因:" + ex.Message);
            }
        }