<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<repositoryVO id="__gMmXr1hqJoOCSikLNbN">
  <name>payFunction</name>
  <parentId>__LgZds5MVHW3o08T7UcX</parentId>
  <applicationid>__LgZds5MVHW3o08T7UcX</applicationid>
  <content><![CDATA[function payFunction(outId,inId,sumPrice,orderId,payName,bcx){
  var bcxPay="1111111111111111";
  println("进入支付");
var SAAS_URL = "http://attends.test.baibaodun.cn/";
  var Security = new Packages.cn.myapps.common.util.Security();
  var accessToken = Security.getToken(getWebUser().getId());
var URLConnector = Packages.cn.hutool.http.HttpRequest;
var domainid = getDomainid();
  
var payUrl = SAAS_URL+"wallet/com-wallet-account-transfer?tlkDomainId="+domainid+"&outId="+outId+"&inId="+inId+"&amount="+sumPrice+"&comment="+orderId+"-资格证退款"+"&needActiveCode=0";
var rtJsonStr = URLConnector.post(payUrl).header("userV5Token","1").header("access_token",accessToken).execute().body();
 // var rtJsonStrs = eval('('+rtJsonStr+')');
  var rtJsonStrData = eval('('+rtJsonStr+')');
  println("rtJsonStrData==>" + rtJsonStrData.retType);
if('0'.equals(rtJsonStrData.retType)){
   var amount=bcx;

 var payUrl2 = SAAS_URL+"wallet/com-wallet-account-transfer?tlkDomainId="+domainid+"&outId="+bcxPay+"&inId="+outId+"&amount="+amount+"&comment="+orderId+"-平台服务费退款"+"&needActiveCode=0";
var rtJsonStr2 = URLConnector.post(payUrl2).header("userV5Token","1").header("access_token",accessToken).execute().body();
 // var rtJsonStrs = eval('('+rtJsonStr+')');
  var rtJsonStrData2 = eval('('+rtJsonStr2+')');
if('0'.equals(rtJsonStrData2.retType)){
  return "success";
 }else{
   return "平台服务费退款异常："+rtJsonStrData2.msg;
 }
}else{
 return "报名费用退款异常："+rtJsonStrData.msg;
}
  

}]]></content>
  <version>4</version>
</repositoryVO>