(1)为了使用批量更新,修改了updateByPrimaryKeySelective方法的方法名为update

(2)多域类配置加入地域IP
(3)多域类配置可任选
(4)多域类配置加入批量删除,审核
This commit is contained in:
wangxin
2018-04-13 13:50:29 +08:00
parent 0dd7f79af0
commit 9a130d864d
28 changed files with 1218 additions and 1437 deletions

View File

@@ -325,7 +325,7 @@ public class BaseController {
}
protected void setSaveOrUpdateProps(Model model,BaseCfg cfg,String areaCfgIds) throws Exception{
String tableName=cfg.getTableName();
List<AreaIpCfg> areaCfg=cfg.getAreaCfg();
List<BaseIpCfg> areaCfg=cfg.getAreaCfg();
List<AreaBean> areaIsps=cfg.getAreaIsp();
if(Constants.IS_AREA_EFFECTIVE_NO==cfg.getIsAreaEffective()){
cfg.setAreaEffectiveIds("");
@@ -372,11 +372,11 @@ public class BaseController {
Date date=new Date();
cfg.setIsValid(Constants.VALID_NO);
cfg.setIsAudit(Constants.AUDIT_NOT_YET);
if(cfg.getCfgId()==null){
if(cfg.getCfgId()==null){//新增
cfg.setCreatorId(cfg.getCurrentUser().getId());
cfg.setCreateTime(date);
if(Constants.IS_AREA_EFFECTIVE_YES==cfg.getIsAreaEffective()&&areaCfg!=null){
for(AreaIpCfg area:areaCfg){
for(BaseIpCfg area:areaCfg){
area.setTableName(AreaIpCfg.getTablename());
area.setServiceId(serviceId);
area.setCompileId(cfg.getCompileId());
@@ -400,18 +400,18 @@ public class BaseController {
}else if(cfg instanceof ComplexkeywordCfg){
complexStringCfgService.addStringCfg((ComplexkeywordCfg)cfg,areaCfg);
}
}else{
}else{//修改
cfg.setEditorId(cfg.getCurrentUser().getId());
cfg.setEditTime(new Date());
List<AreaIpCfg> updateAreaCfg=new ArrayList<>();
List<AreaIpCfg> deleteAreaCfg=new ArrayList<>();
List<AreaIpCfg> addAreaCfg=new ArrayList<>();
List<BaseIpCfg> updateAreaCfg=new ArrayList<>();
List<BaseIpCfg> deleteAreaCfg=new ArrayList<>();
List<BaseIpCfg> addAreaCfg=new ArrayList<>();
String[] cfgIds=null;
if(!StringUtils.isBlank(areaCfgIds)){
cfgIds=areaCfgIds.split(",");
}
if(Constants.IS_AREA_EFFECTIVE_YES==cfg.getIsAreaEffective()&&areaCfg!=null){
for(AreaIpCfg area:areaCfg){
for(BaseIpCfg area:areaCfg){
area.setTableName(AreaIpCfg.getTablename());
area.setServiceId(serviceId);
area.setCompileId(cfg.getCompileId());