generated from root/miduo_server
悠谷支付调整,新增0.1折支付
parent
3f7a2cf13b
commit
f6fab373b5
|
|
@ -39,12 +39,13 @@ public class GetUserController extends HttpServlet {
|
|||
serviceMap.put("QUICK2", new QuickVerifyService2("QUICK2"));
|
||||
serviceMap.put("QUICK3", new QuickVerifyService3("QUICK3"));
|
||||
serviceMap.put("YOUGU", new YouGuVerifyService("YG"));
|
||||
serviceMap.put("YGXQ", new YouGuVerifyService("YGXQ"));
|
||||
serviceMap.put("YGXQ", new YouguXiaoqiVerifyService("YGXQ"));
|
||||
serviceMap.put("YGDC", new YouguDiscountVerifyService("YGDC"));
|
||||
serviceMap.put("DUOYOU", new DuoYouVerifyService("DUOYOU"));
|
||||
serviceMap.put("AIWAN", new AiWanVerifyService("AIWAN"));
|
||||
serviceMap.put("HF", new HFVerifyService("HF"));
|
||||
// serviceMap.put("ANJIU", new AnJiuVerifyService("ANJIU"));
|
||||
serviceMap.put("FENGTI", new FengTiVerifyService("FENGTI"));
|
||||
// serviceMap.put("ANJIU", new AnJiuVerifyService("ANJIU"));
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -80,8 +80,8 @@ public class FengTiVerifyService extends AbstractVerifyService {
|
|||
|
||||
@Override
|
||||
boolean doVerify(VerifyParams params) {
|
||||
String url = "http://47.95.231.223/webapi/checkUserInfo";
|
||||
LOGGER.info("疯体登录验证-->{}",params.getOpenId());
|
||||
String url = "http://checkuser.quickapi.net/v2/checkUserInfo";
|
||||
LOGGER.info("疯体IOS登录验证-->{}",params.getOpenId());
|
||||
Map<String,String> parms = new HashMap<>();
|
||||
parms.put("token",params.getToken());
|
||||
parms.put("uid",params.getOpenId());
|
||||
|
|
|
|||
|
|
@ -80,28 +80,22 @@ public class YouGuVerifyService extends AbstractVerifyService {
|
|||
|
||||
@Override
|
||||
boolean doVerify(VerifyParams params) {
|
||||
String url = "http://smi.648sy.com/tcx/auth";
|
||||
String log = "youguVerifyService";
|
||||
|
||||
if (sign.equals("YGXQ")){
|
||||
url = "http://smi.648sy.com/tcxxqzf/auth";
|
||||
log = "youguXQVerifyService";
|
||||
}
|
||||
LOGGER.info("{}登录验证-->{}",log,params.getOpenId());
|
||||
String loginUrl = "http://smi.648sy.com/tcx/auth";
|
||||
LOGGER.info("悠谷渠道登录验证-->{}",params.getOpenId());
|
||||
Map<String,String> parms = new HashMap<>();
|
||||
parms.put("token",params.getToken());
|
||||
parms.put("uid",params.getOpenId());
|
||||
boolean result = false;
|
||||
try {
|
||||
String r = HttpUtils.doPost(url, parms);
|
||||
String r = HttpUtils.doPost(loginUrl, parms);
|
||||
JSONObject jsonObject = JSON.parseObject(r);
|
||||
int errno = jsonObject.getIntValue("errno");
|
||||
LOGGER.info("{}请求结果:{}",log,r);
|
||||
LOGGER.info("悠谷渠道登录验证请求结果:{}",r);
|
||||
if(errno == 0){
|
||||
result = true;
|
||||
}
|
||||
}catch (IOException e){
|
||||
LOGGER.info("{}验证失败,{}",log,e.getMessage());
|
||||
LOGGER.info("悠谷渠道登录验证验证失败,{}",e.getMessage());
|
||||
return false;
|
||||
}
|
||||
return result;
|
||||
|
|
|
|||
|
|
@ -0,0 +1,46 @@
|
|||
package com.ljsd.service;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ljsd.pojo.VerifyParams;
|
||||
import com.ljsd.util.AppConstans;
|
||||
import com.ljsd.util.HttpUtils;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
public class YouguDiscountVerifyService extends YouGuVerifyService {
|
||||
private static final Logger LOGGER = LoggerFactory.getLogger(YouguDiscountVerifyService.class);
|
||||
|
||||
public YouguDiscountVerifyService(String sign) {
|
||||
super(sign);
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean doVerify(VerifyParams params) {
|
||||
String loginUrl = "http://smi.648sy.com/tcxldyzb/auth";
|
||||
LOGGER.info("悠谷渠道登录验证-->{}",params.getOpenId());
|
||||
Map<String,String> parms = new HashMap<>();
|
||||
parms.put("token",params.getToken());
|
||||
parms.put("uid",params.getOpenId());
|
||||
boolean result = false;
|
||||
try {
|
||||
String r = HttpUtils.doPost(loginUrl, parms);
|
||||
JSONObject jsonObject = JSON.parseObject(r);
|
||||
int errno = jsonObject.getIntValue("errno");
|
||||
LOGGER.info("悠谷渠道登录验证请求结果:{}",r);
|
||||
if(errno == 0){
|
||||
result = true;
|
||||
}
|
||||
}catch (IOException e){
|
||||
LOGGER.info("悠谷渠道登录验证验证失败,{}",e.getMessage());
|
||||
return false;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
package com.ljsd.service;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ljsd.pojo.VerifyParams;
|
||||
import com.ljsd.util.HttpUtils;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
public class YouguXiaoqiVerifyService extends YouGuVerifyService {
|
||||
private static final Logger LOGGER = LoggerFactory.getLogger(YouguXiaoqiVerifyService.class);
|
||||
|
||||
public YouguXiaoqiVerifyService(String sign) {
|
||||
super(sign);
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean doVerify(VerifyParams params) {
|
||||
String loginUrl = "http://smi.648sy.com/tcxxqzf/auth";
|
||||
LOGGER.info("悠谷渠道登录验证-->{}",params.getOpenId());
|
||||
Map<String,String> parms = new HashMap<>();
|
||||
parms.put("token",params.getToken());
|
||||
parms.put("uid",params.getOpenId());
|
||||
boolean result = false;
|
||||
try {
|
||||
String r = HttpUtils.doPost(loginUrl, parms);
|
||||
JSONObject jsonObject = JSON.parseObject(r);
|
||||
int errno = jsonObject.getIntValue("errno");
|
||||
LOGGER.info("悠谷渠道登录验证请求结果:{}",r);
|
||||
if(errno == 0){
|
||||
result = true;
|
||||
}
|
||||
}catch (IOException e){
|
||||
LOGGER.info("悠谷渠道登录验证验证失败,{}",e.getMessage());
|
||||
return false;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue