|
@@ -273,46 +273,30 @@ namespace PTMedicalInsurance.Business
|
|
}
|
|
}
|
|
public int MobilePayCancelSettlement(out string outPar)
|
|
public int MobilePayCancelSettlement(out string outPar)
|
|
{
|
|
{
|
|
- string errMsg;
|
|
+ string inParam,errMsg;
|
|
outPar = "";
|
|
outPar = "";
|
|
try
|
|
try
|
|
{
|
|
{
|
|
-
|
|
+ if (Get6203Inpar(out errMsg) != 0)
|
|
-
|
|
|
|
- if (Get6203Inpar(out errMsg) != 0)
|
|
|
|
- {
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
- YH6203Inpar = errMsg;
|
|
|
|
- JObject jo6203Rtn = invoker.invokeMPService("6203", M6203Inpar);
|
|
|
|
-
|
|
|
|
- if (ParseCenterRtnValue(jo6203Rtn, out errMsg) != 0)
|
|
|
|
- {
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
- else
|
|
|
|
- {
|
|
|
|
- string newSettlID = JsonHelper.getDestValue(jo6203Rtn,"");
|
|
|
|
-
|
|
|
|
- cancleSettlement(newSettlID,out errMsg);
|
|
|
|
-
|
|
|
|
- }
|
|
|
|
- **/
|
|
|
|
-
|
|
|
|
-
|
|
|
|
- if (cancleSettlement(MPat.settlID, out errMsg) != 0)
|
|
|
|
{
|
|
{
|
|
outPar = errMsg;
|
|
outPar = errMsg;
|
|
return -1;
|
|
return -1;
|
|
}
|
|
}
|
|
- else
|
|
+ inParam = errMsg;
|
|
|
|
+ JObject jo6203Rtn = invoker.invokeMPService("6203", inParam);
|
|
|
|
+
|
|
|
|
+ if (JsonHelper.parseMPRtnValue(jo6203Rtn, out errMsg) != 0)
|
|
{
|
|
{
|
|
outPar = errMsg;
|
|
outPar = errMsg;
|
|
- return 0;
|
|
+ return -1;
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ return cancleSettlement(MPat.settlID, out outPar);
|
|
}
|
|
}
|
|
catch (Exception ex)
|
|
catch (Exception ex)
|
|
{
|
|
{
|
|
|
|
+ outPar = ex.Message;
|
|
return -1;
|
|
return -1;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -720,16 +704,16 @@ namespace PTMedicalInsurance.Business
|
|
return -1;
|
|
return -1;
|
|
}
|
|
}
|
|
JObject joRtn = JObject.Parse(errMsg);
|
|
JObject joRtn = JObject.Parse(errMsg);
|
|
- JObject joSettl = JObject.Parse(JsonHelper.getDestValue(joRtn, "data"));
|
|
+ JObject joSettl = JObject.Parse(JsonHelper.getDestValue(joRtn, "result.data[0]"));
|
|
|
|
|
|
|
|
|
|
joInpar.Add("payOrdId", JsonHelper.getDestValue(joSettl, "SettlementID"));
|
|
joInpar.Add("payOrdId", JsonHelper.getDestValue(joSettl, "SettlementID"));
|
|
- joInpar.Add("appRefdSn", JsonHelper.getDestValue(joSettl, ""));
|
|
+ joInpar.Add("appRefdSn", Utils.GetTradeNo());
|
|
- joInpar.Add("appRefdTime", JsonHelper.getDestValue(joSettl, ""));
|
|
+ joInpar.Add("appRefdTime", JsonHelper.getDestValue(joInsuAdmObj, "appRefdTime"));
|
|
joInpar.Add("totlRefdAmt", JsonHelper.getDestValue(joSettl, "Sumamt"));
|
|
joInpar.Add("totlRefdAmt", JsonHelper.getDestValue(joSettl, "Sumamt"));
|
|
joInpar.Add("psnAcctRefdAmt", JsonHelper.getDestValue(joSettl, "AccountPaySumamt"));
|
|
joInpar.Add("psnAcctRefdAmt", JsonHelper.getDestValue(joSettl, "AccountPaySumamt"));
|
|
joInpar.Add("fundRefdAmt", JsonHelper.getDestValue(joSettl, "FundPaySumamt"));
|
|
joInpar.Add("fundRefdAmt", JsonHelper.getDestValue(joSettl, "FundPaySumamt"));
|
|
- joInpar.Add("cashRefdAmt", JsonHelper.getDestValue(joInsuAdmObj, "PersonCashPay"));
|
|
+ joInpar.Add("cashRefdAmt", JsonHelper.getDestValue(joSettl, "PersonCashPay"));
|
|
joInpar.Add("ecToken", MPat.token);
|
|
joInpar.Add("ecToken", MPat.token);
|
|
joInpar.Add("refdType", "ALL");
|
|
joInpar.Add("refdType", "ALL");
|
|
joInpar.Add("expData", "");
|
|
joInpar.Add("expData", "");
|
|
@@ -1422,10 +1406,10 @@ namespace PTMedicalInsurance.Business
|
|
joSetlinfo.Add("OtherPay", MSettl.otherPay);
|
|
joSetlinfo.Add("OtherPay", MSettl.otherPay);
|
|
joSetlinfo.Add("FundPaySumamt", MSettl.fundPaySumamt);
|
|
joSetlinfo.Add("FundPaySumamt", MSettl.fundPaySumamt);
|
|
joSetlinfo.Add("PersonPaySumamt", MSettl.personPaySumamt);
|
|
joSetlinfo.Add("PersonPaySumamt", MSettl.personPaySumamt);
|
|
- joSetlinfo.Add("AccountPaySumamt", MSettl.accountMutualAidAmount);
|
|
+ joSetlinfo.Add("AccountPaySumamt", MSettl.accountPaySumamt);
|
|
joSetlinfo.Add("PersonCashPay", MSettl.personCashPay);
|
|
joSetlinfo.Add("PersonCashPay", MSettl.personCashPay);
|
|
joSetlinfo.Add("Balance", MSettl.balance);
|
|
joSetlinfo.Add("Balance", MSettl.balance);
|
|
- joSetlinfo.Add("AccountMutualAidAmount", "");
|
|
+ joSetlinfo.Add("AccountMutualAidAmount", MSettl.accountMutualAidAmount);
|
|
joSetlinfo.Add("OrganSettlementID", "");
|
|
joSetlinfo.Add("OrganSettlementID", "");
|
|
joSetlinfo.Add("ClearingOrgan", MSettl.clearingOrgan);
|
|
joSetlinfo.Add("ClearingOrgan", MSettl.clearingOrgan);
|
|
joSetlinfo.Add("ClearingWay", MSettl.clearingWay);
|
|
joSetlinfo.Add("ClearingWay", MSettl.clearingWay);
|
|
@@ -1580,26 +1564,5 @@ namespace PTMedicalInsurance.Business
|
|
}
|
|
}
|
|
#endregion
|
|
#endregion
|
|
|
|
|
|
- #region 解析中心返回
|
|
|
|
-
|
|
|
|
-
|
|
|
|
-
|
|
|
|
-
|
|
|
|
-
|
|
|
|
-
|
|
|
|
- public int ParseCenterRtnValue(JObject joRtn, out string errorMsg)
|
|
|
|
- {
|
|
|
|
- try
|
|
|
|
- {
|
|
|
|
- errorMsg = JsonHelper.getDestValue(joRtn, "message");
|
|
|
|
- return int.Parse(JsonHelper.getDestValue(joRtn, "code"));
|
|
|
|
- }
|
|
|
|
- catch (Exception ex)
|
|
|
|
- {
|
|
|
|
- errorMsg = "解析银海移动支付返参发生异常:" + ex.Message;
|
|
|
|
- return -1;
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- #endregion
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|