1月16号之前的asn版本修改组织输入为asn 号输入

This commit is contained in:
duandongmei
2019-01-21 18:26:22 +06:00
parent 7e1875b384
commit 9ff1643e30
6 changed files with 24 additions and 20 deletions

View File

@@ -165,9 +165,11 @@ public class IpCfgService extends CrudService<IpCfgDao,BaseIpCfg> {
}
}
if(regionDict!=null) {
String org=entity.getUserRegion4();
List<AsnGroupInfo> asnGroupInfos=asnGroupInfoDao.getValidConfigGroupInfoByName(org);
for(AsnGroupInfo info:asnGroupInfos) {
AsnGroupInfo asnSearch=new AsnGroupInfo();
asnSearch.setOrganization(entity.getUserRegion4());
asnSearch.setAsnId(Long.valueOf(entity.getUserRegion5()));
AsnGroupInfo info=asnGroupInfoDao.getGroupInfo(asnSearch);
if(info != null){
BaseStringCfg<AsnKeywordCfg> asnKeywordCfg=new AsnKeywordCfg();
BeanUtils.copyProperties(entity, asnKeywordCfg,new String[]{"cfgId","cfgDesc","cfgRegionCode","cfgType","userRegion1","userRegion2","userRegion3"});
asnKeywordCfg.setTableName(AsnKeywordCfg.getTablename());
@@ -233,10 +235,12 @@ public class IpCfgService extends CrudService<IpCfgDao,BaseIpCfg> {
}
if(regionDict!=null) {
//先删除asn keyword
String org=entity.getUserRegion4();
stringCfgDao.deleteAsnKeyword(entity);
List<AsnGroupInfo> asnGroupInfos=asnGroupInfoDao.getValidConfigGroupInfoByName(org);
for(AsnGroupInfo info:asnGroupInfos) {
AsnGroupInfo asnSearch=new AsnGroupInfo();
asnSearch.setOrganization(entity.getUserRegion4());
asnSearch.setAsnId(Long.valueOf(entity.getUserRegion5()));
AsnGroupInfo info=asnGroupInfoDao.getGroupInfo(asnSearch);
if(info != null){
BaseStringCfg<AsnKeywordCfg> asnKeywordCfg=new AsnKeywordCfg();
BeanUtils.copyProperties(entity, asnKeywordCfg,new String[]{"cfgId","cfgDesc","cfgRegionCode","cfgType","userRegion1","userRegion2","userRegion3"});
asnKeywordCfg.setTableName(AsnKeywordCfg.getTablename());