pxy ip控制审核重定向字段添加

This commit is contained in:
wangxin
2018-07-06 14:57:05 +08:00
parent 807b82e8c9
commit 0f713d3730

View File

@@ -228,6 +228,19 @@ public class IpCfgService extends CrudService<IpCfgDao,BaseIpCfg> {
}else if(Constants.SERVICE_IP_RATELIMIT==cfg.getServiceId().intValue()){
maatCfg.setUserRegion(Constants.USERREGION_RATE_LIMIT+"="+cfg.getRatelimit());
}
if(!StringUtil.isEmpty(cfg.getUserRegion1())){
String userRegion = "";
if(cfg.getUserRegion1().startsWith(Constants.REDIRECT_RESPONSE_CODE_STARTWITH)){
userRegion = Constants.REDIRECT_RESPONSE_CODE_KEY+"="+cfg.getUserRegion1()+
Constants.USER_REGION_SPLIT+
Constants.REDIRECT_URL_KEY+"="+cfg.getUserRegion2();
}else{
userRegion = Constants.REDIRECT_RESPONSE_CODE_KEY+"="+cfg.getUserRegion1()+
Constants.USER_REGION_SPLIT+
Constants.REDIRECT_CONTENT_KEY+"="+cfg.getUserRegion2();
}
maatCfg.setUserRegion(userRegion);
}
configCompileList.add(maatCfg);
maatBean.setOpAction(Constants.INSERT_ACTION);
maatBean.setConfigCompileList(configCompileList);