Ejemplo n.º 1
0
        /// <summary>
        /// 获得合同单位数组
        /// </summary>
        /// <param name="pactUnit">合同单位实体</param>
        /// <returns>获得合同单位数组</returns>
        private string[] GetPactUnitParams(Neusoft.HISFC.Models.Base.PactInfo pactUnit)
        {
            string[] args =
            {
                pactUnit.ID,
                pactUnit.PayKind.ID,
                pactUnit.Rate.PubRate.ToString(),
                pactUnit.Rate.PayRate.ToString(),
                pactUnit.Rate.OwnRate.ToString(),
                pactUnit.Rate.RebateRate.ToString(),
                pactUnit.Rate.ArrearageRate.ToString(),
                NConvert.ToInt32(pactUnit.Rate.IsBabyShared).ToString(),
                NConvert.ToInt32(pactUnit.IsNeedMCard).ToString(),
                NConvert.ToInt32(pactUnit.IsInControl).ToString(),
                pactUnit.ItemType,
                pactUnit.DayQuota.ToString(),
                pactUnit.MonthQuota.ToString(),
                pactUnit.YearQuota.ToString(),
                pactUnit.OnceQuota.ToString(),
                pactUnit.PriceForm,
                pactUnit.BedQuota.ToString(),
                pactUnit.AirConditionQuota.ToString(),
                pactUnit.SortID.ToString(),
                this.Operator.ID,
                pactUnit.ShortName,
                pactUnit.PactDllName,
                pactUnit.PactDllDescription
            };

            return(args);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 释放资源
        /// </summary>
        /// <param name="isDisposing"></param>
        protected override void Dispose(bool isDisposing)
        {
            if (this.alreadyDisposed)
            {
                return;
            }

            if (this.operEnvironment != null)
            {
                this.operEnvironment.Dispose();
                this.operEnvironment = null;
            }
            if (this.group != null)
            {
                this.group.Dispose();
                this.group = null;
            }
            if (this.pact != null)
            {
                this.pact.Dispose();
                this.pact = null;
            }
            if (this.statClass != null)
            {
                this.statClass.Dispose();
                this.statClass = null;
            }

            base.Dispose(isDisposing);

            this.alreadyDisposed = true;
        }
Ejemplo n.º 3
0
        /// <summary>
        /// 通过合同单位编码获得
        /// </summary>
        /// <param name="pactCode">合同单位编码</param>
        /// <returns>成功 1 失败 -1</returns>
        public int GetInterfaceFromPact(string pactCode)
        {
            if (this.interfaceHash.ContainsKey(pactCode))
            {
                this.medcaredInterface = (IMedcare)this.interfaceHash[pactCode];
                if (this.medcaredInterface != null)
                {
                    return(1);
                }
            }

            if (this.trans != null)
            {
                this.pactManager.SetTrans(this.trans);
            }

            Neusoft.HISFC.Models.Base.PactInfo pactInfo = this.pactManager.GetPactUnitInfoByPactCode(pactCode);
            if (pactInfo == null)
            {
                this.errMsg = "获得患者合同单位出错!(接口)" + this.pactManager.Err;

                return(-1);
            }
            if (pactInfo.PactDllName == null || pactInfo.PactDllName == string.Empty)
            {
                this.errMsg = "编号为: " + pactCode + "名称为: " + pactInfo.Name + "的合同单位没有维护待遇算法!";

                return(-1);
            }

            try
            {
                // Assembly a = Assembly.LoadFrom(Neusoft.FrameWork.WinForms.Classes.Function.PluginPath + "\\SI\\" + pactInfo.PactDllName);
                Assembly a = Assembly.LoadFrom(System.Windows.Forms.Application.StartupPath + "\\" + Neusoft.FrameWork.WinForms.Classes.Function.PluginPath + "\\SI\\" + pactInfo.PactDllName);


                System.Type[] types = a.GetTypes();
                foreach (System.Type type in types)
                {
                    if (type.GetInterface("IMedcare") != null)
                    {
                        this.medcaredInterface = (IMedcare)System.Activator.CreateInstance(type);
                    }
                }
            }
            catch (Exception e)
            {
                this.errMsg = e.Message;

                return(-1);
            }

            this.interfaceHash.Add(pactCode, this.medcaredInterface);

            return(1);
        }
Ejemplo n.º 4
0
        /// <summary>
        /// 接口回滚方法
        /// </summary>
        /// <returns>成功 1 失败 -1</returns>
        public long Rollback()
        {
            //{21105AAF-1A77-4614-9D13-C3F3233E8DE9}
            #region 旧代码-屏蔽
            //if (this.pactCode == null)
            //{
            //    this.errMsg = "合同单位没有赋值";

            //    return -1;
            //}
            //if (this.medcaredInterface == null)
            //{
            //    int returnValue = this.GetInterfaceFromPact(this.pactCode);
            //    if (returnValue == -1)
            //    {
            //        this.errMsg = this.medcaredInterface.ErrMsg;
            //        return -1;
            //    }
            //}

            //return this.medcaredInterface.Rollback();
            #endregion

            ArrayList pactList = this.pactManager.QueryPactUnitAll();
            if (pactList == null)
            {
                this.errMsg = "查找合同单位失败";
                return(-1);
            }
            if (pactList.Count == 0)
            {
                this.errMsg = "合同单位未维护";
                return(-1);
            }
            for (int i = 0; i < pactList.Count; i++)
            {
                Neusoft.HISFC.Models.Base.PactInfo nowPactCode = pactList[i] as Neusoft.HISFC.Models.Base.PactInfo;

                IMedcare myMedcare = null;
                if (this.interfaceHash.ContainsKey(nowPactCode.ID))
                {
                    myMedcare = (IMedcare)this.interfaceHash[nowPactCode.ID];
                    if (myMedcare != null)
                    {
                        if (myMedcare.Rollback() < 0)
                        {
                            return(-1);
                        }
                    }
                }
            }
            return(1);
        }
Ejemplo n.º 5
0
        /// <summary>
        /// 接口提交方法
        /// </summary>
        /// <returns>成功 1 失败 -1</returns>
        public long Commit()
        {
            //{7E721E47-0F64-4b43-8B42-36926A96D9CB}
            #region 旧代码-屏蔽
            //if (this.pactCode == null)
            //{
            //    this.errMsg = "合同单位没有赋值";

            //    return -1;
            //}
            //if (this.medcaredInterface == null)
            //{
            //    int returnValue = this.GetInterfaceFromPact(this.pactCode);
            //    if (returnValue == -1)
            //    {
            //        this.errMsg = this.medcaredInterface.ErrMsg;
            //        return -1;
            //    }
            //}

            //return this.medcaredInterface.Commit();
            #endregion

            ArrayList pactList = this.pactManager.QueryPactUnitAll();
            if (pactList == null)
            {
                this.errMsg = "查找合同单位失败";
                return(-1);
            }
            if (pactList.Count == 0)
            {
                this.errMsg = "合同单位未维护";
                return(-1);
            }
            for (int i = 0; i < pactList.Count; i++)
            {
                Neusoft.HISFC.Models.Base.PactInfo nowPactCode = pactList[i] as Neusoft.HISFC.Models.Base.PactInfo;

                IMedcare myMedcare = null;
                if (this.interfaceHash.ContainsKey(nowPactCode.ID))
                {
                    myMedcare = (IMedcare)this.interfaceHash[nowPactCode.ID];
                    if (myMedcare != null)
                    {
                        if (myMedcare.Commit() < 0)
                        {
                            return(-1);
                        }
                    }
                }
            }
            return(1);
        }
Ejemplo n.º 6
0
        /// <summary>
        /// 根据合同单位标示返回支付类别名称
        /// </summary>
        /// <param name="strID"></param>
        /// <returns></returns>
        private Neusoft.FrameWork.Models.NeuObject GetPactUnitByID(string strID)
        {
            Neusoft.FrameWork.Models.NeuObject obj = new Neusoft.FrameWork.Models.NeuObject();
            Neusoft.HISFC.Models.Base.PactInfo p   = new Neusoft.HISFC.Models.Base.PactInfo();
            p = this.myPactUnit.GetPactUnitInfoByPactCode(strID);
            if (p == null)
            {
                MessageBox.Show("检索合同单位出错" + this.myPactUnit.Err, "提示");
                return(null);
            }
            if (p.PayKind.ID == "" || p.PayKind == null)
            {
                MessageBox.Show("该合同单位的结算类别没有维护", "提示");
                return(null);
            }
            else
            {
                switch (p.PayKind.ID)
                {
                case "01":
                    obj.Name = "自费"; obj.ID = "01";
                    break;

                case "02":
                    obj.Name = "保险";
                    obj.ID   = "02";
                    break;

                case "03":
                    obj.Name = "公费在职";
                    obj.ID   = "03";
                    break;

                case "04":
                    obj.Name = "公费退休";
                    obj.ID   = "04";
                    break;

                case "05":
                    obj.Name = "公费高干";
                    obj.ID   = "05";
                    break;

                default:
                    break;
                }
            }
            return(obj);
        }
Ejemplo n.º 7
0
        /// <summary>
        /// 获得插入合同单位信息数组
        /// </summary>
        /// <param name="pactUnit">合同单位实体</param>
        /// <returns>获得合同单位数组</returns>
        private string[] GetInsertPactUnitParams(Neusoft.HISFC.Models.Base.PactInfo pactUnit)
        {
            #region Sql

            /*insert into fin_com_pactunitinfo
             * ( pact_code,pact_name,paykind_code,PRICE_FORM ,
             * pub_ratio,pay_ratio,own_ratio,eco_ratio ,arr_ratio,baby_flag,mcard_flag,
             * control_flag ,flag,day_limit ,month_limit,year_limit,once_limit ,
             * BED_LIMIT,AIR_LIMIT ,SORT_ID ,OPER_CODE,OPER_DATE,SIMPLE_NAME, DLL_NAME,DLL_DESCRIPTION )
             * values ('{0}','{1}','{2}','{3}',{4},{5},
             * {6},{7},{8},'{9}','{10}','{11}','{12}',{13},{14},{15},{16},{17},{18},{19},'{20}',sysdate,'{21}','{22}','{23}')
             *
             */
            #endregion
            string[] args =
            {
                pactUnit.ID,
                pactUnit.Name,
                pactUnit.PayKind.ID,
                pactUnit.PriceForm,
                pactUnit.Rate.PubRate.ToString(),
                pactUnit.Rate.PayRate.ToString(),
                pactUnit.Rate.OwnRate.ToString(),
                pactUnit.Rate.RebateRate.ToString(),
                pactUnit.Rate.ArrearageRate.ToString(),
                NConvert.ToInt32(pactUnit.Rate.IsBabyShared).ToString(),
                NConvert.ToInt32(pactUnit.IsNeedMCard).ToString(),
                NConvert.ToInt32(pactUnit.IsInControl).ToString(),
                pactUnit.ItemType,
                pactUnit.DayQuota.ToString(),
                pactUnit.MonthQuota.ToString(),
                pactUnit.YearQuota.ToString(),
                pactUnit.OnceQuota.ToString(),
                pactUnit.BedQuota.ToString(),
                pactUnit.AirConditionQuota.ToString(),
                pactUnit.SortID.ToString(),
                this.Operator.ID,
                pactUnit.ShortName,
                pactUnit.PactDllName,
                pactUnit.PactDllDescription
            };

            return(args);
        }
Ejemplo n.º 8
0
        protected override void OnLoad()
        {
            base.OnLoad();

            // 部门下拉列表
            System.Collections.ArrayList list_department = new System.Collections.ArrayList();

            if (department1 == Department.住院)
            {
                list_department.Add("住院");
            }
            else if (department1 == Department.门诊)
            {
                list_department.Add("门诊");
            }
            else if (department1 == Department.全院)
            {
                list_department.Add("全院");
                list_department.Add("住院");
                list_department.Add("门诊");
            }

            for (int i = 0; i < list_department.Count; i++)
            {
                this.ncboDepartment.Items.Add(list_department[i]);
            }

            ncboDepartment.alItems.AddRange(list_department);

            if (ncboDepartment.Items.Count > 0)
            {
                ncboDepartment.SelectedIndex = 0;
                department = "ALL";
            }

            // 统计大类下拉列表
            Neusoft.HISFC.BizProcess.Integrate.Manager manager = new Neusoft.HISFC.BizProcess.Integrate.Manager();
            System.Collections.ArrayList list_bigtype          = manager.GetConstantList("FEECODESTAT");

            //Neusoft.HISFC.Models.Base.Const top_bigtype = new Neusoft.HISFC.Models.Base.Const();
            //top_bigtype.ID = "ALL";
            //top_bigtype.Name = "全部";

            //this.ncboReportCode.Items.Add(top_bigtype);

            foreach (Neusoft.HISFC.Models.Base.Const var_bigtype in list_bigtype)
            {
                this.ncboReportCode.Items.Add(var_bigtype);
            }

            //this.ncboReportCode.alItems.Add(top_bigtype);
            this.ncboReportCode.alItems.AddRange(list_bigtype);

            if (ncboReportCode.Items.Count > 0)
            {
                ncboReportCode.SelectedIndex = 0;
                reportCode = ((Neusoft.HISFC.Models.Base.Const)ncboReportCode.alItems[this.ncboReportCode.SelectedIndex]).ID;   //((Neusoft.HISFC.Models.Base.Const)ncboReportCode.alItems[0]).ID.ToString();
                reportName = ((Neusoft.HISFC.Models.Base.Const)ncboReportCode.alItems[this.ncboReportCode.SelectedIndex]).Name; //((Neusoft.HISFC.Models.Base.Const)ncboReportCode.alItems[0]).Name;
            }

            // 科室下拉列表
            System.Collections.ArrayList list_dept = new System.Collections.ArrayList();

            list_dept.Add("开单科室");
            list_dept.Add("执行科室");
            list_dept.Add("患者所在科室");

            for (int i = 0; i < list_dept.Count; i++)
            {
                this.ncboDept.Items.Add(list_dept[i]);
            }

            this.ncboDept.alItems.AddRange(list_dept);

            if (ncboDept.Items.Count > 0)
            {
                ncboDept.SelectedIndex = 0;
                dept = ncboDept.alItems[0].ToString();
            }

            // 合同单位下拉列表
            Neusoft.HISFC.BizLogic.Fee.PactUnitInfo pactManager = new Neusoft.HISFC.BizLogic.Fee.PactUnitInfo();
            System.Collections.ArrayList            list_pact   = pactManager.QueryPactUnitAll();

            Neusoft.HISFC.Models.Base.PactInfo top_pact = new Neusoft.HISFC.Models.Base.PactInfo();
            top_pact.ID   = "ALL";
            top_pact.Name = "全部";
            this.ncboPact.Items.Add(top_pact);

            foreach (Neusoft.HISFC.Models.Base.PactInfo var_pact in list_pact)
            {
                this.ncboPact.Items.Add(var_pact);
            }

            this.ncboPact.alItems.Add(top_pact);
            this.ncboPact.alItems.AddRange(list_pact);

            if (ncboPact.Items.Count > 0)
            {
                ncboPact.SelectedIndex = 0;
                pactCode = ((Neusoft.HISFC.Models.Base.PactInfo)ncboPact.alItems[0]).ID;
                pactName = ((Neusoft.HISFC.Models.Base.PactInfo)ncboPact.alItems[0]).Name;
            }
        }
Ejemplo n.º 9
0
        /// <summary>
        /// 根据合同单位和项目代码得到项目价格
        /// </summary>
        /// <param name="patient"></param>
        /// <param name="IsDrug"></param>
        /// <param name="ItemID"></param>
        /// <param name="Price"></param>
        /// <returns></returns>
        public int GetPrice(Neusoft.HISFC.Models.RADT.PatientInfo patient, HISFC.Models.Base.EnumItemType IsDrug, string ItemID, ref decimal Price)
        {
            string strSql = "";

            try
            {
                if (IsDrug == Neusoft.HISFC.Models.Base.EnumItemType.Drug)
                {
                    #region 药品,直接取零售价格
                    #region sql
                    //				SELECT retail_price    --参考零售价
                    //				  FROM pha_com_baseinfo   --药品目录表
                    //				 WHERE parent_code='[父级编码]' and current_code='[本级编码]' and drug_code='{0}'
                    #endregion
                    if (this.Sql.GetSql("Fee.InvoiceService.GetDrugPrice", ref strSql) == -1)
                    {
                        return(-1);
                    }

                    strSql = string.Format(strSql, ItemID);
                    if (this.ExecQuery(strSql) == -1)
                    {
                        return(-1);
                    }
                    int count = 0;

                    while (Reader.Read())
                    {
                        Price = Neusoft.FrameWork.Function.NConvert.ToDecimal(Reader[0].ToString());
                        count++;
                    }
                    Reader.Close();
                    if (count == 0)
                    {
                        this.Err     = "Fee.InvoiceService.GetDrugPrice";
                        this.ErrCode = "未检索到行!";
                        return(-1);
                    }
                    #endregion
                }
                else if (IsDrug == Neusoft.HISFC.Models.Base.EnumItemType.UnDrug)
                {
                    #region 非药品,根据合同单位取项目价格
                    //获得患者合同单位
                    Neusoft.HISFC.Models.Base.PactInfo pact = this.GetPactUnitInfoByPactCode(patient.Pact.ID);
                    if (pact == null)
                    {
                        this.Err     = "Fee.InvoiceService.GetDrugPrice";
                        this.ErrCode = "未检索到行!";
                        return(-1);
                    }
                    if (this.Sql.GetSql("Fee.InvoiceService.GetUndrugPrice", ref strSql) == -1)
                    {
                        return(-1);
                    }
                    strSql = string.Format(strSql, ItemID);
                    if (this.ExecQuery(strSql) == -1)
                    {
                        return(-1);
                    }
                    int count = 0;

                    while (Reader.Read())
                    {
                        if (pact.PriceForm == "默认价")
                        {
                            Price = Neusoft.FrameWork.Function.NConvert.ToDecimal(Reader[0].ToString());
                        }
                        //如果患者年龄小于15周岁,取儿童价
                        TimeSpan Age = new TimeSpan(this.GetDateTimeFromSysDateTime().Ticks - patient.Birthday.Ticks);
                        if (Age.Days / 365 < 15)
                        {
                            Price = Neusoft.FrameWork.Function.NConvert.ToDecimal(Reader[1].ToString());
                            if (Price == 0)
                            {
                                Price = Neusoft.FrameWork.Function.NConvert.ToDecimal(Reader[0].ToString());
                            }
                        }
                        //既是儿童,又是特诊患者去特诊价
                        if (pact.PriceForm == "特诊价")
                        {
                            Price = Neusoft.FrameWork.Function.NConvert.ToDecimal(Reader[2].ToString());
                            if (Price == 0)
                            {
                                Price = Neusoft.FrameWork.Function.NConvert.ToDecimal(Reader[0].ToString());
                            }
                        }
                        count++;
                    }
                    Reader.Close();

                    if (count == 0)
                    {
                        this.Err     = "Fee.InvoiceService.GetDrugPrice";
                        this.ErrCode = "未检索到行!";
                        return(-1);
                    }
                    #endregion
                }
            }
            catch (Exception e)
            {
                this.Err     = "Fee.InvoiceService.GetDrugPrice";
                this.ErrCode = e.Message;
                if (Reader.IsClosed == false)
                {
                    Reader.Close();
                }
                return(-1);
            }
            return(0);
        }
Ejemplo n.º 10
0
 /// <summary>
 /// 删除合同单位信息
 /// </summary>
 /// <param name="pactUnit">合同单位实体</param>
 /// <returns>成功 1 失败 -1</returns>
 public int DeletePactUnitInfo(Neusoft.HISFC.Models.Base.PactInfo pactUnit)
 {
     return(this.UpdateSingleTable("Fee.InvocieService.DeletePactUnitInfo", pactUnit.ID, pactUnit.ItemType));
 }
Ejemplo n.º 11
0
        /// <summary>
        /// 根据SQL语句查询合同单位信息
        /// </summary>
        /// <param name="sql">查询得SQL语句</param>
        /// <param name="args">参数</param>
        /// <returns>成功 合同单位信息集合 失败 null</returns>
        private ArrayList QueryPactUnitBySql(string sql, params string[] args)
        {
            if (this.ExecQuery(sql, args) == -1)
            {
                return(null);
            }

            ArrayList pactUnitList = new ArrayList();//费用明细数组

            Neusoft.HISFC.Models.Base.PactInfo pactUnit = null;

            try
            {
                while (this.Reader.Read())
                {
                    pactUnit = new Neusoft.HISFC.Models.Base.PactInfo();

                    pactUnit.ID                 = this.Reader[0].ToString();                        //合同代码
                    pactUnit.Name               = this.Reader[1].ToString();                        //合同单位名称
                    pactUnit.PayKind.ID         = this.Reader[2].ToString();                        //结算类别
                    pactUnit.Rate.PubRate       = NConvert.ToDecimal(Reader[3].ToString().Trim());  //公费比例
                    pactUnit.Rate.PayRate       = NConvert.ToDecimal(Reader[4].ToString().Trim());  //自付比例
                    pactUnit.Rate.OwnRate       = NConvert.ToDecimal(Reader[5].ToString().Trim());  //自费比例
                    pactUnit.Rate.RebateRate    = NConvert.ToDecimal(Reader[6].ToString().Trim());  //优惠比例
                    pactUnit.Rate.ArrearageRate = NConvert.ToDecimal(Reader[7].ToString().Trim());  //欠费比例
                    pactUnit.Rate.IsBabyShared  = NConvert.ToBoolean(Reader[8].ToString());         //婴儿标志 0 无关 1 有关
                    pactUnit.IsNeedMCard        = NConvert.ToBoolean(Reader[9].ToString().Trim());  //是否要求必须有医疗证号 0 否 1 是
                    pactUnit.IsInControl        = NConvert.ToBoolean(Reader[10].ToString().Trim()); //是否受监控 1受监控0不受监控
                    pactUnit.ItemType           = Reader[11].ToString().Trim();                     //标志  0 全部 1 药品 2 非药品
                    pactUnit.DayQuota           = NConvert.ToDecimal(Reader[12].ToString().Trim()); //日限额
                    pactUnit.MonthQuota         = NConvert.ToDecimal(Reader[13].ToString().Trim()); //月限额
                    pactUnit.YearQuota          = NConvert.ToDecimal(Reader[14].ToString().Trim()); //年限额
                    pactUnit.OnceQuota          = NConvert.ToDecimal(Reader[15].ToString().Trim()); //一次限
                    string PriceForm = Reader[16].ToString();
                    if (PriceForm == "0")
                    {
                        pactUnit.PriceForm = "默认价";
                    }
                    else if (PriceForm == "1")
                    {
                        pactUnit.PriceForm = "特诊价";
                    }
                    else if (PriceForm == "2")
                    {
                        pactUnit.PriceForm = "儿童价";
                    }
                    pactUnit.BedQuota           = NConvert.ToDecimal(Reader[17].ToString()); //床位限额
                    pactUnit.AirConditionQuota  = NConvert.ToDecimal(Reader[18].ToString()); //空调限额
                    pactUnit.SortID             = NConvert.ToInt32(Reader[19]);              //序号
                    pactUnit.ShortName          = Reader[20].ToString();                     //合同单位简称
                    pactUnit.PactDllName        = Reader[21].ToString();                     //待遇dll名称
                    pactUnit.PactDllDescription = Reader[22].ToString();                     //待遇dll说明
                    pactUnitList.Add(pactUnit);
                }

                this.Reader.Close();

                return(pactUnitList);
            }
            catch (Exception e)
            {
                this.Err = e.Message;
                this.WriteErr();

                if (!this.Reader.IsClosed)
                {
                    this.Reader.Close();
                }

                return(null);
            }
        }
Ejemplo n.º 12
0
 /// <summary>
 /// 插入合同单位信息
 /// </summary>
 /// <param name="pactUnit">合同单位实体</param>
 /// <returns>成功 1 失败 -1</returns>
 public int InsertPactUnitInfo(Neusoft.HISFC.Models.Base.PactInfo pactUnit)
 {
     return(this.UpdateSingleTable("Fee.InvocieService.InsertPactUnitInfo", this.GetInsertPactUnitParams(pactUnit)));
 }
Ejemplo n.º 13
0
        public ArrayList GetPactUnitInfo()
        {
            string strSql = "";

            if (this.Sql.GetSql("Fee.PactUnitInfo.GetPactUnitInfo", ref strSql) == -1)
            {
                return(null);
            }
            try
            {
                this.ExecQuery(strSql);
                while (this.Reader.Read())
                {
                    Neusoft.HISFC.Models.Base.PactInfo info = new Neusoft.HISFC.Models.Base.PactInfo();

                    //合同代码
                    info.ID = Reader[0].ToString();
                    //合同单位名称
                    info.Name = Reader[1].ToString();

                    //结算类别
                    info.PayKind.ID = Reader[2].ToString();

                    //公费比例
                    info.Rate.PubRate = NConvert.ToDecimal(Reader[3].ToString().Trim());

                    //自付比例
                    info.Rate.PayRate = NConvert.ToDecimal(Reader[4].ToString().Trim());

                    //自费比例
                    info.Rate.OwnRate = NConvert.ToDecimal(Reader[5].ToString().Trim());

                    //优惠比例
                    info.Rate.RebateRate = NConvert.ToDecimal(Reader[6].ToString().Trim());

                    //欠费比例
                    info.Rate.ArrearageRate = NConvert.ToDecimal(Reader[7].ToString().Trim());

                    //婴儿标志 0 无关 1 有关
                    info.Rate.IsBabyShared = NConvert.ToBoolean(Reader[8].ToString());

                    //是否要求必须有医疗证号 0 否 1 是
                    info.IsNeedMCard = NConvert.ToBoolean(Reader[9].ToString().Trim());

                    //是否受监控 1受监控0不受监控
                    info.IsInControl = NConvert.ToBoolean(Reader[10].ToString().Trim());

                    //标志  0 全部 1 药品 2 非药品
                    info.ItemType = Reader[11].ToString().Trim();

                    //日限额
                    if (Reader[12] != DBNull.Value)
                    {
                        info.DayQuota = NConvert.ToDecimal(Reader[12].ToString().Trim());
                    }

                    if (Reader[13] != DBNull.Value)
                    {
                        //月限额
                        info.MonthQuota = NConvert.ToDecimal(Reader[13].ToString().Trim());
                    }
                    if (Reader[14] != DBNull.Value)
                    {
                        //年限额
                        info.YearQuota = NConvert.ToDecimal(Reader[14].ToString().Trim());
                    }
                    if (Reader[15] != DBNull.Value)
                    {
                        //一次限额
                        info.OnceQuota = NConvert.ToDecimal(Reader[15].ToString().Trim());
                    }
                    string PriceForm = Reader[16].ToString();
                    if (PriceForm == "0")
                    {
                        info.PriceForm = "默认价";
                    }
                    else if (PriceForm == "1")
                    {
                        info.PriceForm = "特诊价";
                    }
                    else if (PriceForm == "2")
                    {
                        info.PriceForm = "儿童价";
                    }
                    else
                    {
                    }
                    //取两位小数By Maokb -060920
                    if (Reader[17] != DBNull.Value)
                    {
                        info.BedQuota = NConvert.ToDecimal(Reader[17].ToString());
                    }
                    if (Reader[18] != DBNull.Value)
                    {
                        info.AirConditionQuota = NConvert.ToDecimal(Reader[18].ToString());
                    }
                    if (Reader[19] != DBNull.Value)
                    {
                        info.SortID = NConvert.ToInt32(Reader[19]);
                    }
                    //合同单位简称
                    info.ShortName = Reader[20].ToString();
                    list.Add(info);
                    info = null;
                }
                this.Reader.Close();
            }
            catch (Exception ee)
            {
                this.Err = ee.Message;
                list     = null;
            }
            return(list);
        }
Ejemplo n.º 14
0
        protected override void OnLoad()
        {
            //填充数据 费用类别

            Neusoft.HISFC.BizProcess.Integrate.Manager manager = new Neusoft.HISFC.BizProcess.Integrate.Manager();
            ArrayList constantList = manager.GetConstantList("FEECODESTAT");



            foreach (Neusoft.HISFC.Models.Base.Const con in constantList)
            {
                cmbReportCode.Items.Add(con);
            }

            if (cmbReportCode.Items.Count >= 0)
            {
                cmbReportCode.SelectedIndex = 0;
                reportCode = ((Neusoft.HISFC.Models.Base.Const)cmbReportCode.Items[0]).ID;
                reportName = ((Neusoft.HISFC.Models.Base.Const)cmbReportCode.Items[0]).Name;
            }

            //填充合同单位

            Neusoft.HISFC.BizLogic.Fee.PactUnitInfo pactManager = new Neusoft.HISFC.BizLogic.Fee.PactUnitInfo();
            ArrayList alPactList = new ArrayList();



            // cmbPact.Items.Add();
            alPactList = pactManager.QueryPactUnitAll();
            Neusoft.HISFC.Models.Base.PactInfo tmpPactInfo = new Neusoft.HISFC.Models.Base.PactInfo();
            tmpPactInfo.ID        = "ALL";
            tmpPactInfo.Name      = "全部";
            tmpPactInfo.SpellCode = "QB";

            cmbPact.Items.Add(tmpPactInfo);

            foreach (Neusoft.HISFC.Models.Base.PactInfo pact in alPactList)
            {
                cmbPact.Items.Add(pact);
            }

            if (cmbPact.Items.Count >= 0)
            {
                cmbPact.SelectedIndex = 0;
                pactCode = ((Neusoft.HISFC.Models.Base.PactInfo)cmbPact.Items[0]).ID;
                pactName = ((Neusoft.HISFC.Models.Base.PactInfo)cmbPact.Items[0]).Name;
            }

            ///查询条件

            comDept.ClearItems();
            if (deptZone1 == DeptZone.ALL_DEPT)
            {
                comDept.Items.Add("按挂号科室查询");
                comDept.Items.Add("按医生所在科室查询");
                comDept.Items.Add("按执行科室查询");
            }
            if (deptZone1 == DeptZone.DOC_DEPT)
            {
                comDept.Items.Add("按医生所在科室查询");
                comDept.Enabled = false;
            }
            if (deptZone1 == DeptZone.EXE_DEPT)
            {
                comDept.Items.Add("按执行科室查询");
                comDept.Enabled = false;
            }
            if (deptZone1 == DeptZone.REG_DEPT)
            {
                comDept.Items.Add("按挂号科室查询");
                comDept.Enabled = false;
            }
            if (comDept.Items.Count >= 0)
            {
                comDept.SelectedIndex = 0;
            }
            base.OnLoad();
        }
        protected override void OnLoad()
        {
            base.OnLoad();

            // 部门下拉列表
            this.ncboDepart.Items.Add("全院");
            this.ncboDepart.Items.Add("门诊");
            this.ncboDepart.Items.Add("住院");

            this.ncboDepart.alItems.Add("全院");
            this.ncboDepart.alItems.Add("门诊");
            this.ncboDepart.alItems.Add("住院");

            if (ncboDepart.Items.Count > 0)
            {
                ncboDepart.SelectedIndex = 0;
                type = ncboDepart.Items[this.ncboDepart.SelectedIndex].ToString();
            }

            // 统计大类下拉列表
            Neusoft.HISFC.BizProcess.Integrate.Manager manager = new Neusoft.HISFC.BizProcess.Integrate.Manager();
            System.Collections.ArrayList constantList          = manager.GetConstantList("FEECODESTAT");

            Neusoft.HISFC.Models.Base.Const top = new Neusoft.HISFC.Models.Base.Const();
            top.ID   = "ALL";
            top.Name = "全  部";

            // 下拉列表加载第一个选项“全部”
            this.cboReportCode.Items.Add(top);

            foreach (Neusoft.HISFC.Models.Base.Const con in constantList)
            {
                cboReportCode.Items.Add(con);
            }

            // 下拉列表键盘选择框加载第一个选项“全部”以及加载列表
            this.cboReportCode.alItems.Add(top);
            this.cboReportCode.alItems.AddRange(constantList);

            if (cboReportCode.Items.Count > 0)
            {
                cboReportCode.SelectedIndex = 0;
                reportCode = ((Neusoft.HISFC.Models.Base.Const)cboReportCode.Items[0]).ID;
                reportName = ((Neusoft.HISFC.Models.Base.Const)cboReportCode.Items[0]).Name;
            }

            // 医疗类型下拉列表
            Neusoft.HISFC.BizLogic.Fee.PactUnitInfo pactManager = new Neusoft.HISFC.BizLogic.Fee.PactUnitInfo();
            System.Collections.ArrayList            pactList    = pactManager.QueryPactUnitAll();

            Neusoft.HISFC.Models.Base.PactInfo top_pact = new Neusoft.HISFC.Models.Base.PactInfo();
            top_pact.ID   = "ALL";
            top_pact.Name = "全  部";

            this.ncboPact.Items.Add(top_pact);

            foreach (Neusoft.HISFC.Models.Base.PactInfo pact in pactList)
            {
                ncboPact.Items.Add(pact);
            }

            this.ncboPact.alItems.Add(top_pact);
            this.ncboPact.alItems.Add(pactList);

            if (ncboPact.Items.Count > 0)
            {
                ncboPact.SelectedIndex = 0;
                pactCode = ((Neusoft.HISFC.Models.Base.PactInfo)ncboPact.Items[0]).ID;
                pactName = ((Neusoft.HISFC.Models.Base.PactInfo)ncboPact.Items[0]).Name;
            }
        }