|
|
@@ -9,7 +9,6 @@ import com.uas.platform.b2c.fa.payment.support.UserInfoSupport;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
import org.springframework.util.StringUtils;
|
|
|
-import org.springframework.web.bind.annotation.RequestBody;
|
|
|
import org.springframework.web.client.RestTemplate;
|
|
|
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
@@ -148,10 +147,10 @@ public class BankReceiptsServiceImpl implements BankReceiptsService {
|
|
|
map.put(PingAnField.VERIFYCODE, verifyCode);
|
|
|
} else {
|
|
|
map.putAll(infoMap);
|
|
|
- map.put(PingAnField.ORDERID, "200031114620180109UHTX1CS0");
|
|
|
+ map.put(PingAnField.ORDERID, "200031114620180109UJRBAWB0");
|
|
|
map.put(PingAnField.CURRENCY, "RMB");
|
|
|
map.put("amount", "10.00");
|
|
|
- map.put("paydate", "20180109112109");
|
|
|
+ map.put("paydate", "20180109195546");
|
|
|
map.put("customerId", "19901120");
|
|
|
map.put("verifyCode", "111111");
|
|
|
map.put("issInsCode", "HXB");
|
|
|
@@ -204,17 +203,6 @@ public class BankReceiptsServiceImpl implements BankReceiptsService {
|
|
|
return loadHtml;
|
|
|
}
|
|
|
|
|
|
- /**
|
|
|
- * 微信预支付的接口
|
|
|
- *
|
|
|
- * @param json 传入的支付信息
|
|
|
- * @return String
|
|
|
- */
|
|
|
- @Override
|
|
|
- public String weChatPrePay(JSONObject json) {
|
|
|
- return null;
|
|
|
- }
|
|
|
-
|
|
|
/**
|
|
|
* 微信支付的接口
|
|
|
*
|
|
|
@@ -222,7 +210,18 @@ public class BankReceiptsServiceImpl implements BankReceiptsService {
|
|
|
* @return String
|
|
|
*/
|
|
|
@Override
|
|
|
- public String weChatPay(@RequestBody JSONObject json) {
|
|
|
- return null;
|
|
|
+ public String weChatPay(JSONObject json) {
|
|
|
+ HashMap<String, String> map = new HashMap<>();
|
|
|
+ if (json == null || json.size() == 0) {
|
|
|
+ map.put("orderId", "200031114620180109UJZMZWY0");
|
|
|
+ map.put("currency", "RMB");
|
|
|
+ map.put("amount", "10.00");
|
|
|
+ map.put("objectName", "");
|
|
|
+ map.put("paydate", "20180109220355");
|
|
|
+ } else {
|
|
|
+ //TODO
|
|
|
+ }
|
|
|
+ String loadHtml = restTemplate.postForObject("http://192.168.253.119:20280/weChat/pay", map, String.class);
|
|
|
+ return loadHtml;
|
|
|
}
|
|
|
}
|