|
@@ -105,11 +105,7 @@ namespace PTMedicalInsurance.Business
|
|
|
{
|
|
|
inf = new InterfaceInfo();
|
|
|
inf.hospitalDr = int.Parse(JsonHelper.getDestValue(joInpar, "HospitalDr"));
|
|
|
- if (joInpar.ContainsKey("hisHospitalDr"))
|
|
|
- {
|
|
|
- inf.hisHospitalDr = int.Parse(JsonHelper.getDestValue(joInpar, "hisHospitalDr"));
|
|
|
- }
|
|
|
-
|
|
|
+ inf.hisHospitalDr = int.Parse(JsonHelper.getDestValue(joInpar, "hisHospitalDr"));
|
|
|
inf.hospitalName = JsonHelper.getDestValue(joInpar, "HospitalName");
|
|
|
inf.interfaceDr = int.Parse(JsonHelper.getDestValue(joInpar, "ID"));
|
|
|
inf.interfaceID = JsonHelper.getDestValue(joInpar, "InterfaceID");
|
|
@@ -163,63 +159,63 @@ namespace PTMedicalInsurance.Business
|
|
|
inf.cainfo = "";
|
|
|
}
|
|
|
|
|
|
- ///// <summary>
|
|
|
- ///// 根据壳程序传入的入参设置全局接口变量
|
|
|
- ///// </summary>
|
|
|
- ///// <param name="joInpar"></param>
|
|
|
- ///// <param name="inf"></param>
|
|
|
- //public void setGlobalInterface_Plat(JObject joInpar, out InterfaceInfo inf)
|
|
|
- //{
|
|
|
- // inf = new InterfaceInfo();
|
|
|
+ /// <summary>
|
|
|
+ /// 根据壳程序传入的入参设置全局接口变量
|
|
|
+ /// </summary>
|
|
|
+ /// <param name="joInpar"></param>
|
|
|
+ /// <param name="inf"></param>
|
|
|
+ public void setGlobalInterface_Plat(JObject joInpar, out InterfaceInfo inf)
|
|
|
+ {
|
|
|
+ inf = new InterfaceInfo();
|
|
|
|
|
|
- // inf.hospitalDr = int.Parse(JsonHelper.getDestValue(joInpar, "hospitalID"));
|
|
|
- // inf.hisHospitalDr = int.Parse(JsonHelper.getDestValue(joInpar, "hisHospitalDr"));
|
|
|
- // inf.hospitalName = JsonHelper.getDestValue(joInpar, "hospitalName");
|
|
|
- // inf.interfaceDr = int.Parse(JsonHelper.getDestValue(joInpar, "medInsuInterfaceID"));
|
|
|
- // inf.interfaceID = JsonHelper.getDestValue(joInpar, "interfaceNO");
|
|
|
- // //inf.oper = "3";
|
|
|
- // inf.centerURL = JsonHelper.getDestValue(joInpar, "centerURL");
|
|
|
- // inf.areaCode = JsonHelper.getDestValue(joInpar, "areaCode");
|
|
|
- // inf.dllName = JsonHelper.getDestValue(joInpar, "dLLName");
|
|
|
- // inf.hospitalNO = JsonHelper.getDestValue(joInpar, "hospitalNO");
|
|
|
- // inf.version = "v1.0";
|
|
|
- // inf.signatureType = "SM2";
|
|
|
- // inf.recivedSystem = "YBXT";
|
|
|
- // //inf.AK = "583ebd87f99f4be19a6c425d5ecb89fc";
|
|
|
- // //inf.SK = "m9pKPKPnlfMcpJNtSjtvRCN2Rgg=";
|
|
|
- // inf.dev_safe_info = "";
|
|
|
- // inf.dev_no = Global.curEvt.mac;
|
|
|
+ inf.hospitalDr = int.Parse(JsonHelper.getDestValue(joInpar, "hospitalID"));
|
|
|
+ inf.hisHospitalDr = int.Parse(JsonHelper.getDestValue(joInpar, "hisHospitalDr"));
|
|
|
+ inf.hospitalName = JsonHelper.getDestValue(joInpar, "hospitalName");
|
|
|
+ inf.interfaceDr = int.Parse(JsonHelper.getDestValue(joInpar, "medInsuInterfaceID"));
|
|
|
+ inf.interfaceID = JsonHelper.getDestValue(joInpar, "interfaceNO");
|
|
|
+ //inf.oper = "3";
|
|
|
+ inf.centerURL = JsonHelper.getDestValue(joInpar, "centerURL");
|
|
|
+ inf.areaCode = JsonHelper.getDestValue(joInpar, "areaCode");
|
|
|
+ inf.dllName = JsonHelper.getDestValue(joInpar, "dLLName");
|
|
|
+ inf.hospitalNO = JsonHelper.getDestValue(joInpar, "hospitalNO");
|
|
|
+ inf.version = "v1.0";
|
|
|
+ inf.signatureType = "SM2";
|
|
|
+ inf.recivedSystem = "YBXT";
|
|
|
+ //inf.AK = "583ebd87f99f4be19a6c425d5ecb89fc";
|
|
|
+ //inf.SK = "m9pKPKPnlfMcpJNtSjtvRCN2Rgg=";
|
|
|
+ inf.dev_safe_info = "";
|
|
|
+ inf.dev_no = Global.curEvt.mac;
|
|
|
|
|
|
- // IniFile ini = new IniFile(Global.curEvt.path + @"\INSUConfigure.ini");
|
|
|
- // Global.inf.fixedPointType = ini.ReadValue("FixedPointInfo", "TYPE"); //1.省本级 2.市本级 3.区本级
|
|
|
+ IniFile ini = new IniFile(Global.curEvt.path + @"\INSUConfigure.ini");
|
|
|
+ Global.inf.fixedPointType = ini.ReadValue("FixedPointInfo", "TYPE"); //1.省本级 2.市本级 3.区本级
|
|
|
|
|
|
|
|
|
- // inf.centerURL2 = JsonHelper.getDestValue(joInpar, "centerURL2");
|
|
|
- // byte[] b = Base64.Decode(inf.centerURL2);
|
|
|
- // string centerURL2 = System.Text.Encoding.UTF8.GetString(b);
|
|
|
- // JObject joCenterURL2 = JObject.Parse(centerURL2);
|
|
|
+ inf.centerURL2 = JsonHelper.getDestValue(joInpar, "centerURL2");
|
|
|
+ byte[] b = Base64.Decode(inf.centerURL2);
|
|
|
+ string centerURL2 = System.Text.Encoding.UTF8.GetString(b);
|
|
|
+ JObject joCenterURL2 = JObject.Parse(centerURL2);
|
|
|
|
|
|
|
|
|
|
|
|
- // inf.MobilePay.url = JsonHelper.getDestValue(joCenterURL2, "mobilePay.url");
|
|
|
- // inf.MobilePay.appid = JsonHelper.getDestValue(joCenterURL2, "mobilePay.appid");
|
|
|
- // inf.MobilePay.secretKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.secretKey");
|
|
|
- // inf.MobilePay.privateKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.privateKey");
|
|
|
- // inf.MobilePay.publicKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.publicKey");
|
|
|
+ inf.MobilePay.url = JsonHelper.getDestValue(joCenterURL2, "mobilePay.url");
|
|
|
+ inf.MobilePay.appid = JsonHelper.getDestValue(joCenterURL2, "mobilePay.appid");
|
|
|
+ inf.MobilePay.secretKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.secretKey");
|
|
|
+ inf.MobilePay.privateKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.privateKey");
|
|
|
+ inf.MobilePay.publicKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.publicKey");
|
|
|
|
|
|
- // inf.PresCir.url = JsonHelper.getDestValue(joCenterURL2, "mobilePay.url");
|
|
|
- // inf.PresCir.appid = JsonHelper.getDestValue(joCenterURL2, "mobilePay.appid");
|
|
|
- // inf.PresCir.secretKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.secretKey");
|
|
|
- // inf.PresCir.privateKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.privateKey");
|
|
|
- // inf.PresCir.publicKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.publicKey");
|
|
|
+ inf.PresCir.url = JsonHelper.getDestValue(joCenterURL2, "mobilePay.url");
|
|
|
+ inf.PresCir.appid = JsonHelper.getDestValue(joCenterURL2, "mobilePay.appid");
|
|
|
+ inf.PresCir.secretKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.secretKey");
|
|
|
+ inf.PresCir.privateKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.privateKey");
|
|
|
+ inf.PresCir.publicKey = JsonHelper.getDestValue(joCenterURL2, "mobilePay.publicKey");
|
|
|
|
|
|
|
|
|
- // inf.ecURL = JsonHelper.getDestValue(joCenterURL2, "core.ecURL");
|
|
|
- // inf.cardURL = JsonHelper.getDestValue(joCenterURL2, "core.cardURL");
|
|
|
+ inf.ecURL = JsonHelper.getDestValue(joCenterURL2, "core.ecURL");
|
|
|
+ inf.cardURL = JsonHelper.getDestValue(joCenterURL2, "core.cardURL");
|
|
|
|
|
|
- // inf.cainfo = "";
|
|
|
+ inf.cainfo = "";
|
|
|
|
|
|
- //}
|
|
|
+ }
|
|
|
|
|
|
/// <summary>
|
|
|
/// 初始化环境
|
|
@@ -253,7 +249,15 @@ namespace PTMedicalInsurance.Business
|
|
|
if (joInterface != null)
|
|
|
{
|
|
|
//获取当前接口详细信息
|
|
|
- setGlobalInterface(joInterface, out Global.inf);
|
|
|
+ //获取当前接口详细信息
|
|
|
+ if (Global.businessType == "P1")
|
|
|
+ {
|
|
|
+ setGlobalInterface_Plat(joInterface, out Global.inf);
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ setGlobalInterface(joInterface, out Global.inf);
|
|
|
+ }
|
|
|
Global.inf.originalInterfaceDr = Global.inf.interfaceDr;
|
|
|
JObject joSession = JObject.Parse(JsonHelper.getDestValue(joInparam, "session[0]"));
|
|
|
if (joSession != null)
|