Example #1
0
        /// <summary>
        /// 刷新上传费用
        /// </summary>
        public void BrushUploadFee()
        {
            if (zy_PatList != null)
            {
                ZY_PresOrder zypo = new ZY_PresOrder();
                zypo.PatListID = zy_PatList.PatListID;
                dt1            = zypo.GetPresDataTableOld();

                dt2 = null;
                if (zy_PatList.patientInfo.ACCOUNTTYPE.Trim() == "农合")
                {
                    if (zy_PatList.patientInfo.MediCard != null && zy_PatList.patientInfo.MediCard != "")
                    {
                        IzyInterface nccmInterface = NccmFactory.Create();
                        if (nccmInterface != null)
                        {
                            nccmInterface.zyPatlist = zy_PatList;
                            dt2 = nccmInterface.DownloadzyPatFee(null);
                        }
                    }
                }
                view.dgvHisFee  = dt1;
                view.dgvNccmFee = dt2;
            }
        }
Example #2
0
        private void _SinglePatUpdate()
        {
            try
            {
                ZY_PresOrder zypo = new ZY_PresOrder();
                zypo.PatListID = zy_PatList.PatListID;

                if (zy_PatList == null)
                {
                    view.rtbMessage = "没有指定病人!\n";
                    BackUpdateType();
                    return;
                }

                //加载农合病人信息,为农合病人做准备
                view.rtbMessage = "正在上传[" + zy_PatList.patientInfo.PatName + "]数据!\n";
                if (zy_PatList.patientInfo.MediCard != null && zy_PatList.patientInfo.MediCard.Trim() != "")
                {
                    //第一步:实例化接口对象
                    nccmInterface = NccmFactory.Create();
                    if (nccmInterface == null)
                    {
                        view.rtbMessage = "没有开启上传接口!\n";
                    }
                    else
                    {
                        //第二步:病人信息赋值
                        nccmInterface.zyPatlist = zy_PatList;
                        view.rtbMessage         = "根据[" + zy_PatList.patientInfo.PatName + "]医疗证号获取病人信息!\n";
                        //第三步:根据医疗证号获取最新的农合病人信息

                        view.rtbMessage = "获取[" + zy_PatList.patientInfo.PatName + "]病人信息成功!\n";
                        //第四步:提取病人上传的费用信息
                        DataTable dt = zypo.GetPresDataTable();
                        view.rtbMessage = "提取[" + zy_PatList.patientInfo.PatName + "]病人费用成功!\n";
                        if (dt.Rows.Count > 0)
                        {
                            //第五步:更改所有费用为上传标志
                            //int[] presID = new int[dt.Rows.Count];
                            //for (int i = 0; i < dt.Rows.Count; i++)
                            //{
                            //    presID[i] = Convert.ToInt32(dt.Rows[i]["PRESORDERID"]);
                            //}
                            //HIS.ZY_BLL.OP_PresManage.UpdateComp(presID);
                            //第六步:调用费用上传接口(上传失败的费用会更改上传标识)

                            Hashtable hashtable = new Hashtable();
                            hashtable.Add("FeeDetail", zyNccmInterface.ConvertFeeDetail(dt));

                            nccmInterface.UploadzyPatFee(hashtable);
                            view.rtbMessage = "上传[" + zy_PatList.patientInfo.PatName + "]成功!\n";
                        }
                    }
                }
                else
                {
                    view.rtbMessage = "没有指定病人或此病人不是符合类型的病人!\n";
                }
            }
            catch
            {
                view.rtbMessage = "上传失败!\n";
            }
            BackUpdateType();
        }