فهرست منبع

20001接口调试改造传参改浮点型和整型

837390164@qq.com 10 ماه پیش
والد
کامیت
eaa15073e8
2فایلهای تغییر یافته به همراه21 افزوده شده و 13 حذف شده
  1. 10 8
      Forms/SaleBillInfo.cs
  2. 11 5
      InsuBusiness.cs

+ 10 - 8
Forms/SaleBillInfo.cs

@@ -13,7 +13,9 @@ namespace PTMedicalInsurance.Forms
 {
     public partial class SaleBillInfo : Form
     {
-        public string entId, code, medicalDrugId, salePkg, unpackCount, drugSalePrice, batchNo;
+        public string entId, code, medicalDrugId, batchNo;
+        public decimal drugSalePrice = 0, unpackCount = 0;
+        public int salePkg = 0;
 
         private void SaleBillInfo_Load(object sender, EventArgs e)
         {
@@ -56,9 +58,9 @@ namespace PTMedicalInsurance.Forms
             entId = tb_JRZDBS.Text;
             code = tb_ZSM.Text;
             medicalDrugId = tb_YBYPBM.Text;
-            salePkg = cbb_CLBS.Text.Substring(0, 7);
-            unpackCount = tb_CBXSSL.Text;
-            drugSalePrice = tb_YPLSJG.Text;
+            salePkg = int.Parse(cbb_CLBS.Text.Substring(0, 7));
+            unpackCount = decimal.Parse(tb_CBXSSL.Text);
+            drugSalePrice = decimal.Parse(tb_YPLSJG.Text);
             batchNo = tb_SCPC.Text;
 
             if ((code == "") && (batchNo == ""))            
@@ -68,10 +70,10 @@ namespace PTMedicalInsurance.Forms
             }
 
             decimal count;
-            count = decimal.Parse(unpackCount);
+            count = unpackCount;
             if (cbb_CLBS.SelectedIndex != 0)            
             {
-                if ((count <= 0) || (unpackCount == ""))                
+                if ((count <= 0) || (tb_CBXSSL.Text == ""))                
                 {
                     MessageBox.Show("整包销售时【拆包销售数量】传0,拆零销售时【拆包销售数量】传大于0的整数!");
                     return;
@@ -79,8 +81,8 @@ namespace PTMedicalInsurance.Forms
             }
 
             decimal price;
-            price = decimal.Parse(drugSalePrice);
-            if ((price <= 0) || (drugSalePrice == ""))            
+            price = drugSalePrice;
+            if ((price <= 0) || (tb_YPLSJG.Text == ""))            
             {
                 MessageBox.Show("【药品零售价格】无效!");
                 return;

+ 11 - 5
InsuBusiness.cs

@@ -1605,25 +1605,31 @@ namespace PTMedicalInsurance
                     case "BasicData"://基础数据维护
                         {
                             BasicData bd = new BasicData();
-                            bd.ShowDialog();
+                            if (bd.ShowDialog() != DialogResult.OK)
+                            {
+                                rtnResult = JsonHelper.setExceptionJson(-100, "", "已退出基础数据维护界面").ToString();
+                                return rtnResult;
+                            }
                             break;
                         }
                     case "Exception"://异常处理
                         {
                             //显示异常处理界面
                             HandleException frmEX = new HandleException();
-                            if (frmEX.ShowDialog() == DialogResult.OK)
+                            if (frmEX.ShowDialog() != DialogResult.OK)
                             {
-
+                                rtnResult = JsonHelper.setExceptionJson(-100, "", "已退出异常处理界面").ToString();
+                                return rtnResult;
                             }
                             break;
                         }
                     case "CheckAndClearing"://对账清算
                         {
                             Clearing frmEX = new Clearing();
-                            if (frmEX.ShowDialog() == DialogResult.OK)
+                            if (frmEX.ShowDialog() != DialogResult.OK)
                             {
-
+                                rtnResult = JsonHelper.setExceptionJson(-100, "", "已退出对账清算界面").ToString();
+                                return rtnResult;
                             }
                             break;
                         }