瀏覽代碼

门诊退费异常导致强制退HIS结算判断是否因为异常原因退费调用接口

837390164@qq.com 2 天之前
父節點
當前提交
c535d48b39
共有 6 個文件被更改,包括 58 次插入43 次删除
  1. 11 6
      Business/IrisServices.cs
  2. 1 1
      Forms/OutpatientRegistration.cs
  3. 10 10
      Forms/OutpatientRegistration.designer.cs
  4. 2 3
      Forms/SettlementInfo.cs
  5. 30 23
      InsuBusiness.cs
  6. 4 0
      Variables/Struct.cs

+ 11 - 6
Business/IrisServices.cs

@@ -730,8 +730,14 @@ namespace PTMedicalInsurance.Business
             decimal ybAmt, psnAcctAmt, hospAmt, psnCashAmt, medFee, commercialReimamt, commercialRenflag;
             try
             {
-                JObject joExpContent = JObject.Parse(JsonHelper.getDestValue(jo, "exp_content"));
-                Global.Set.wltpayAmt = JsonHelper.getDestValue(joExpContent, "medIns_wallet_pay");    
+                Global.Set.medIns_wallet_pay = "0";
+                Global.Set.medIns_wallet_balance = "0";
+                if (string.IsNullOrEmpty(JsonHelper.getDestValue(jo, "exp_content")) == false)                
+                {              
+                    JObject joExpContent = JObject.Parse(JsonHelper.getDestValue(jo, "exp_content"));
+                    Global.Set.medIns_wallet_pay = JsonHelper.getDestValue(joExpContent, "medIns_wallet_pay");
+                    Global.Set.medIns_wallet_balance = JsonHelper.getDestValue(joExpContent, "medIns_wallet_balance");
+                }
 
                 commercialRenflag = getFee(jo, "commercial_renflag"); //商保支付标志
                 commercialReimamt = getFee(jo, "commercial_reimamt"); //商保支付金额 50
@@ -749,7 +755,7 @@ namespace PTMedicalInsurance.Business
                       + getFee(jo, "cvlserv_pay") //公务员医疗补助
                       + getFee(jo, "maf_pay") //医疗救助基金支出
                       + getFee(jo, "oth_pay")  //其他支出        500
-                      + decimal.Parse(Global.Set.wltpayAmt); //医保钱包支付金额
+                      + decimal.Parse(Global.Set.medIns_wallet_pay); //医保钱包支付金额
 
                 psnAcctAmt = getFee(jo, "acct_pay");     //账户支付金额 100
                 psnCashAmt = getFee(jo, "psn_cash_pay"); //现金支付金额 200
@@ -1598,9 +1604,8 @@ namespace PTMedicalInsurance.Business
                 joSetlinfo.Add("HISAdmTime", Global.Set.hisAdmTime);
                 joSetlinfo.Add("HISDischargeTime", Global.Set.hisDischargeTime); 
 
-                JObject joExpContent = JObject.Parse(JsonHelper.getDestValue(joSetlinfo, "exp_content"));
-                joSetlinfo.Add("medIns_wallet_balance", JsonHelper.getDestValue(joExpContent, "medIns_wallet_balance")); //医保钱包余额
-                joSetlinfo.Add("medIns_wallet_pay", JsonHelper.getDestValue(joExpContent, "medIns_wallet_pay")); //医保钱包支付金额
+                joSetlinfo.Add("medIns_wallet_balance", Global.Set.medIns_wallet_balance); //医保钱包余额
+                joSetlinfo.Add("medIns_wallet_pay", Global.Set.medIns_wallet_pay); //医保钱包支付金额
 
                 JObject joRtn = invoker.invokeInsuService(JsonHelper.setIrisInpar("09010051", joSetlinfo).ToString(), "插入结算信息");
                 if (JsonHelper.parseIrisRtnValue(joRtn, out errMsg) != 0)

+ 1 - 1
Forms/OutpatientRegistration.cs

@@ -147,7 +147,7 @@ namespace PTMedicalInsurance.Forms
             //string insuranceTypeRtn = iris.Invoke(insuranceTypeParam);
             //dynamic insuranceTypeRtnRtnJson = JsonConvert.DeserializeObject(insuranceTypeRtn);
             //dtInsuranceType = (DataTable)insuranceTypeRtnRtnJson.ToObject(typeof(DataTable));
-            rbg_AccUseFalg.SelectedIndex = 1;
+            rbg_AccUseFalg.SelectedIndex = 1; 
             personAccountUsedFlag = "1";
         }
 

+ 10 - 10
Forms/OutpatientRegistration.designer.cs

@@ -30,7 +30,7 @@ namespace PTMedicalInsurance.Forms
         /// </summary>
         private void InitializeComponent()
         {
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
             this.panel1 = new System.Windows.Forms.Panel();
             this.rbg_AccUseFalg = new Sunny.UI.UIRadioButtonGroup();
             this.dblkcbxDiseaseType = new PTControl.DBLookupCombox();
@@ -100,12 +100,12 @@ namespace PTMedicalInsurance.Forms
             "2-钱包支付",
             "3-钱包个人账户都使用"});
             this.rbg_AccUseFalg.ItemSize = new System.Drawing.Size(200, 40);
-            this.rbg_AccUseFalg.Location = new System.Drawing.Point(955, 0);
+            this.rbg_AccUseFalg.Location = new System.Drawing.Point(977, 0);
             this.rbg_AccUseFalg.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
             this.rbg_AccUseFalg.MinimumSize = new System.Drawing.Size(1, 1);
             this.rbg_AccUseFalg.Name = "rbg_AccUseFalg";
             this.rbg_AccUseFalg.Padding = new System.Windows.Forms.Padding(0, 32, 0, 0);
-            this.rbg_AccUseFalg.Size = new System.Drawing.Size(242, 190);
+            this.rbg_AccUseFalg.Size = new System.Drawing.Size(220, 190);
             this.rbg_AccUseFalg.TabIndex = 24;
             this.rbg_AccUseFalg.Text = "医保个人账户使用标志";
             this.rbg_AccUseFalg.TextAlignment = System.Drawing.ContentAlignment.MiddleCenter;
@@ -298,13 +298,13 @@ namespace PTMedicalInsurance.Forms
             // 
             this.dgvDiagnose.AllowUserToAddRows = false;
             this.dgvDiagnose.BorderStyle = System.Windows.Forms.BorderStyle.None;
-            dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.ButtonShadow;
-            dataGridViewCellStyle2.Font = new System.Drawing.Font("新宋体", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.WindowText;
-            dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight;
-            dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.WindowText;
-            dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
-            this.dgvDiagnose.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2;
+            dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.ButtonShadow;
+            dataGridViewCellStyle1.Font = new System.Drawing.Font("新宋体", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
+            dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+            dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.WindowText;
+            dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+            this.dgvDiagnose.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
             this.dgvDiagnose.ColumnHeadersHeight = 40;
             this.dgvDiagnose.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
             this.dgvDiagnose.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {

+ 2 - 3
Forms/SettlementInfo.cs

@@ -82,9 +82,8 @@ namespace PTMedicalInsurance.Forms
             this.tbCommercialReimamt.Text = joSettlmentInfo["commercial_reimamt"].ToString();
             this.tbCommercialRenflag.Text = joSettlmentInfo["commercial_renflag"].ToString();
 
-            //JObject joExpContent = JObject.Parse(JsonHelper.getDestValue(joSettlmentInfo, "exp_content"));            
-            //tbMedInsWalletBalance.Text = JsonHelper.getDestValue(joExpContent, "medIns_wallet_balance");
-            //tbMedInsWalletPay.Text = JsonHelper.getDestValue(joExpContent, "medIns_wallet_pay");
+            this.tbMedInsWalletBalance.Text = Global.Set.medIns_wallet_balance;
+            this.tbMedInsWalletPay.Text = Global.Set.medIns_wallet_pay;
 
             Global.Set.acctPay = joSettlmentInfo["acct_pay"].ToString();
             setDgvSettlDetailHeader();

+ 30 - 23
InsuBusiness.cs

@@ -1039,30 +1039,38 @@ namespace PTMedicalInsurance
                                 rtnResult = JsonHelper.setExceptionJson(-1, "取消平台结算信息", outParam).ToString();
                                 //return rtnResult;
                             }
-                            //中心取消传送
-                            if (cBus.cancleFeeUpload("2205", out errMsg) != 0)
-                            {
-                                rtnResult = JsonHelper.setExceptionJson(-1, "取消中心费用", errMsg).ToString();
-                                return rtnResult;
-                            }
-                            //云平台取消传送
-                            if (mIS.deleteFee(out errMsg) != 0)
-                            {
-                                rtnResult = JsonHelper.setExceptionJson(-1, "删除医保平台费用", errMsg).ToString();
-                                return rtnResult;
-                            }
-                            //取消中心登记
-                            if (cBus.cancleRegister("2202", out outParam) != 0)
-                            {
-                                rtnResult = JsonHelper.setExceptionJson(-1, "中心取消登记失败,", outParam).ToString();
-                                return rtnResult;
-                            }
-                            //取消医保平台登记
-                            if (mIS.cancleRegister(3, out outParam) != 0)
+
+                            if (newSettleID != "YC")
                             {
-                                rtnResult = JsonHelper.setExceptionJson(-1, "中心取消登记成功,但云医保平台取消失败,", outParam).ToString();
-                                return rtnResult;
+                                //中心取消传送
+                                if (cBus.cancleFeeUpload("2205", out errMsg) != 0)
+                                {
+                                    rtnResult = JsonHelper.setExceptionJson(-1, "取消中心费用", errMsg).ToString();
+                                    return rtnResult;
+                                }
+
+                                //云平台取消传送
+                                if (mIS.deleteFee(out errMsg) != 0)
+                                {
+                                    rtnResult = JsonHelper.setExceptionJson(-1, "删除医保平台费用", errMsg).ToString();
+                                    return rtnResult;
+                                }
+
+                                //取消中心登记
+                                if (cBus.cancleRegister("2202", out outParam) != 0)
+                                {
+                                    rtnResult = JsonHelper.setExceptionJson(-1, "中心取消登记失败,", outParam).ToString();
+                                    return rtnResult;
+                                }
+
+                                //取消医保平台登记
+                                if (mIS.cancleRegister(3, out outParam) != 0)
+                                {
+                                    rtnResult = JsonHelper.setExceptionJson(-1, "中心取消登记成功,但云医保平台取消失败,", outParam).ToString();
+                                    return rtnResult;
+                                }
                             }
+
                             //退HIS结算
                             if (hIS.cancleSettlementInfo(joParam, out outParam) != 0)
                             {
@@ -1075,7 +1083,6 @@ namespace PTMedicalInsurance
                                 return rtnResult;
                             }
                         }
-
                     case "M6"://门诊移动支付结算
                         {
                             MobilePay mp = new MobilePay(InParam, out errMsg);

+ 4 - 0
Variables/Struct.cs

@@ -222,6 +222,10 @@ namespace PTMedicalInsurance.Variables
         public string clearingWay;
         public string clearingOrgan;
         public string acctPay;
+
+        public string medIns_wallet_balance;
+        public string medIns_wallet_pay;
+
         DateTime occurTime;
 
         public int hospitalizationsTimes;