音视频地址增加SubscribeId配置.
This commit is contained in:
@@ -618,7 +618,12 @@ public class AvContentCfgService extends BaseService{
|
||||
*/
|
||||
public BaseIpCfg getContIpCfgById(BaseIpCfg entity) {
|
||||
entity.setTableName("av_cont_ip_cfg");
|
||||
return avContentCfgDao.findIpCfgById(entity);
|
||||
BaseIpCfg cfg = avContentCfgDao.findIpCfgById(entity);
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(cfg, subscribeIdCfg, new String[] {"cfgId","isValid"});
|
||||
List<NtcSubscribeIdCfg> list = stringCfgDao.findSubscribeIdCfgList(subscribeIdCfg);
|
||||
cfg.setNtcSubscribeIdCfgList(list);
|
||||
return cfg;
|
||||
}
|
||||
@Transactional(readOnly=false,rollbackFor=RuntimeException.class)
|
||||
public void saveOrUpdateContIp(BaseIpCfg entity,String areaCfgIds){
|
||||
@@ -641,6 +646,18 @@ public class AvContentCfgService extends BaseService{
|
||||
logger.info("获取编译ID出错");
|
||||
throw new MaatConvertException("<spring:message code=\"request_service_failed\"/>:"+e.getMessage());
|
||||
}
|
||||
|
||||
// 添加subscribeId
|
||||
if(entity.getNtcSubscribeIdCfgList()!=null){
|
||||
for(NtcSubscribeIdCfg cfg:entity.getNtcSubscribeIdCfgList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
entity.setCompileId(compileIds.get(0));
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
stringCfgDao.saveSubscribeIdCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(compileIds != null && compileIds.size() >0 && compileIds.get(0) != 0){
|
||||
entity.setCompileId(compileIds.get(0));
|
||||
|
||||
@@ -733,6 +750,21 @@ public class AvContentCfgService extends BaseService{
|
||||
entity.setEditorId(UserUtils.getUser().getId());
|
||||
entity.setEditTime(editTime);
|
||||
avContentCfgDao.updateIp(entity);
|
||||
|
||||
entity.setCreateTime(new Date());
|
||||
entity.setCreatorId(entity.getCurrentUser().getId());
|
||||
// 删除SubscribeId配置再进行添加
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(entity, subscribeIdCfg,new String[]{"cfgId","cfgType"});
|
||||
stringCfgDao.deleteSubscribeIdCfg(subscribeIdCfg);
|
||||
if(entity.getNtcSubscribeIdCfgList()!=null){
|
||||
for(NtcSubscribeIdCfg cfg:entity.getNtcSubscribeIdCfgList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
stringCfgDao.saveSubscribeIdCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -757,6 +789,14 @@ public class AvContentCfgService extends BaseService{
|
||||
entity.setEditorId(UserUtils.getUser().getId());
|
||||
entity.setEditTime(new Date());
|
||||
avContentCfgDao.updateIp(entity);
|
||||
// 查询域配置信息
|
||||
BaseIpCfg cfg = this.getContIpCfgById(entity);
|
||||
if(cfg.getNtcSubscribeIdCfgList() != null && cfg.getNtcSubscribeIdCfgList().size()>0) {
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(cfg, subscribeIdCfg, new String[] {"cfgId","cfgType","tableName"});
|
||||
stringCfgDao.updateSubscribeIdCfg(subscribeIdCfg);
|
||||
}
|
||||
|
||||
AreaIpCfg areaIpCfg=new AreaIpCfg();
|
||||
BeanUtils.copyProperties(entity, areaIpCfg);
|
||||
areaIpCfgDao.updateAreaIpCfgValid(areaIpCfg);
|
||||
@@ -829,6 +869,19 @@ public class AvContentCfgService extends BaseService{
|
||||
}
|
||||
}
|
||||
|
||||
// 修改审核状态
|
||||
BaseIpCfg baseIpCfg = this.getContIpCfgById(entity);
|
||||
if(!StringUtil.isEmpty(baseIpCfg.getNtcSubscribeIdCfgList())) {
|
||||
NtcSubscribeIdCfg cfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(entity, cfg, new String[] {"cfgId","cfgType"});
|
||||
stringCfgDao.updateSubscribeIdCfg(cfg);
|
||||
if(isAudit==1) {
|
||||
Map<String,List> map = cfgConvert(strRegionList,baseIpCfg.getNtcSubscribeIdCfgList(),2,entity,groupRelationList);
|
||||
groupRelationList=map.get("groupList");
|
||||
strRegionList=map.get("dstList");
|
||||
}
|
||||
}
|
||||
|
||||
//构造提交综合服务参数格式,一条配置提交一次综合服务
|
||||
if(isAudit==1){
|
||||
maatCfg.initDefaultValue();
|
||||
@@ -900,7 +953,12 @@ public class AvContentCfgService extends BaseService{
|
||||
*/
|
||||
public BaseIpCfg getPicIpCfgById(BaseIpCfg entity) {
|
||||
entity.setTableName("av_pic_ip_cfg");
|
||||
return avContentCfgDao.findIpCfgById(entity);
|
||||
BaseIpCfg cfg = avContentCfgDao.findIpCfgById(entity);
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(cfg, subscribeIdCfg,new String[] {"cfgId","isValid"});
|
||||
List<NtcSubscribeIdCfg> list = stringCfgDao.findSubscribeIdCfgList(subscribeIdCfg);
|
||||
cfg.setNtcSubscribeIdCfgList(list);
|
||||
return cfg;
|
||||
}
|
||||
@Transactional(readOnly=false,rollbackFor=RuntimeException.class)
|
||||
public void saveOrUpdatePicIp(BaseIpCfg entity,String areaCfgIds){
|
||||
@@ -923,6 +981,18 @@ public class AvContentCfgService extends BaseService{
|
||||
logger.info("获取编译ID出错");
|
||||
throw new MaatConvertException("<spring:message code=\"request_service_failed\"/>:"+e.getMessage());
|
||||
}
|
||||
|
||||
// 添加subscribeId
|
||||
if(entity.getNtcSubscribeIdCfgList()!=null){
|
||||
for(NtcSubscribeIdCfg cfg:entity.getNtcSubscribeIdCfgList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
entity.setCompileId(compileIds.get(0));
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
stringCfgDao.saveSubscribeIdCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(compileIds != null && compileIds.size() >0 && compileIds.get(0) != 0){
|
||||
entity.setCompileId(compileIds.get(0));
|
||||
|
||||
@@ -1015,6 +1085,21 @@ public class AvContentCfgService extends BaseService{
|
||||
entity.setEditorId(UserUtils.getUser().getId());
|
||||
entity.setEditTime(editTime);
|
||||
avContentCfgDao.updateIp(entity);
|
||||
|
||||
entity.setCreateTime(new Date());
|
||||
entity.setCreatorId(entity.getCurrentUser().getId());
|
||||
// 删除SubscribeId配置再进行添加
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(entity, subscribeIdCfg,new String[]{"cfgId","cfgType"});
|
||||
stringCfgDao.deleteSubscribeIdCfg(subscribeIdCfg);
|
||||
if(entity.getNtcSubscribeIdCfgList()!=null){
|
||||
for(NtcSubscribeIdCfg cfg:entity.getNtcSubscribeIdCfgList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType"});
|
||||
stringCfgDao.saveSubscribeIdCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1039,6 +1124,14 @@ public class AvContentCfgService extends BaseService{
|
||||
entity.setEditorId(UserUtils.getUser().getId());
|
||||
entity.setEditTime(new Date());
|
||||
avContentCfgDao.updateIp(entity);
|
||||
// 查询域配置信息
|
||||
BaseIpCfg cfg = this.getPicIpCfgById(entity);
|
||||
if(cfg.getNtcSubscribeIdCfgList() != null && cfg.getNtcSubscribeIdCfgList().size()>0) {
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(cfg, subscribeIdCfg, new String[] {"cfgId","cfgTyep","tableName"});
|
||||
stringCfgDao.updateSubscribeIdCfg(subscribeIdCfg);
|
||||
}
|
||||
|
||||
AreaIpCfg areaIpCfg=new AreaIpCfg();
|
||||
BeanUtils.copyProperties(entity, areaIpCfg);
|
||||
areaIpCfgDao.updateAreaIpCfgValid(areaIpCfg);
|
||||
@@ -1112,6 +1205,19 @@ public class AvContentCfgService extends BaseService{
|
||||
}
|
||||
}
|
||||
|
||||
// 修改审核状态
|
||||
BaseIpCfg baseIpCfg = this.getPicIpCfgById(entity);
|
||||
if(!StringUtil.isEmpty(baseIpCfg.getNtcSubscribeIdCfgList())) {
|
||||
NtcSubscribeIdCfg cfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(entity, cfg, new String[] {"cfgId","cfgType"});
|
||||
stringCfgDao.updateSubscribeIdCfg(cfg);
|
||||
if(isAudit==1) {
|
||||
Map<String,List> map = cfgConvert(strRegionList,baseIpCfg.getNtcSubscribeIdCfgList(),2,entity,groupRelationList);
|
||||
groupRelationList=map.get("groupList");
|
||||
strRegionList=map.get("dstList");
|
||||
}
|
||||
}
|
||||
|
||||
//构造提交综合服务参数格式,一条配置提交一次综合服务
|
||||
if(isAudit==1){
|
||||
maatCfg.initDefaultValue();
|
||||
@@ -1182,9 +1288,14 @@ public class AvContentCfgService extends BaseService{
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
public BaseStringCfg getContUrlCfgById(BaseStringCfg entity) {
|
||||
public BaseStringCfg<NtcSubscribeIdCfg> getContUrlCfgById(BaseStringCfg entity) {
|
||||
entity.setTableName("av_cont_url_cfg");
|
||||
return avContentCfgDao.findStringCfgById(entity);
|
||||
BaseStringCfg cfg = avContentCfgDao.findStringCfgById(entity);
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(cfg, subscribeIdCfg, new String[] {"cfgId","isValid"});
|
||||
List<NtcSubscribeIdCfg> list = stringCfgDao.findSubscribeIdCfgList(subscribeIdCfg);
|
||||
cfg.setNtcSubscribeIdCfgList(list);
|
||||
return cfg;
|
||||
}
|
||||
@Transactional(readOnly=false,rollbackFor=RuntimeException.class)
|
||||
public void saveOrUpdateContUrl(BaseStringCfg<BaseStringCfg> entity,String areaCfgIds){
|
||||
@@ -1207,6 +1318,20 @@ public class AvContentCfgService extends BaseService{
|
||||
logger.info("获取编译ID出错");
|
||||
throw new MaatConvertException("<spring:message code=\"request_service_failed\"/>:"+e.getMessage());
|
||||
}
|
||||
|
||||
// 添加subscribeId
|
||||
if(entity.getNtcSubscribeIdCfgList()!=null){
|
||||
for(NtcSubscribeIdCfg cfg:entity.getNtcSubscribeIdCfgList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
entity.setCompileId(compileIds.get(0));
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType",
|
||||
"cfgKeywords","exprType",
|
||||
"matchMethod","isHexbin"});
|
||||
stringCfgDao.saveSubscribeIdCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(compileIds != null && compileIds.size() >0 && compileIds.get(0) != 0){
|
||||
entity.setCompileId(compileIds.get(0));
|
||||
|
||||
@@ -1273,6 +1398,23 @@ public class AvContentCfgService extends BaseService{
|
||||
entity.setEditTime(editTime);
|
||||
entity.setTableName("av_cont_url_cfg");
|
||||
avContentCfgDao.updateString(entity);
|
||||
|
||||
entity.setCreateTime(new Date());
|
||||
entity.setCreatorId(entity.getCurrentUser().getId());
|
||||
// 删除SubscribeId配置再进行添加
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(entity, subscribeIdCfg,new String[]{"cfgId","cfgType"});
|
||||
stringCfgDao.deleteSubscribeIdCfg(subscribeIdCfg);
|
||||
if(entity.getNtcSubscribeIdCfgList()!=null){
|
||||
for(NtcSubscribeIdCfg cfg:entity.getNtcSubscribeIdCfgList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType",
|
||||
"cfgKeywords","exprType",
|
||||
"matchMethod","isHexbin"});
|
||||
stringCfgDao.saveSubscribeIdCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1297,6 +1439,13 @@ public class AvContentCfgService extends BaseService{
|
||||
entity.setEditorId(UserUtils.getUser().getId());
|
||||
entity.setEditTime(new Date());
|
||||
avContentCfgDao.updateString(entity);
|
||||
// 查询域配置信息
|
||||
BaseStringCfg cfg = this.getContUrlCfgById(entity);
|
||||
if(cfg.getNtcSubscribeIdCfgList() != null && cfg.getNtcSubscribeIdCfgList().size()>0) {
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(cfg, subscribeIdCfg, new String[] {"cfgId","cfgType","tableName"});
|
||||
stringCfgDao.updateSubscribeIdCfg(subscribeIdCfg);
|
||||
}
|
||||
AreaIpCfg areaIpCfg=new AreaIpCfg();
|
||||
BeanUtils.copyProperties(entity, areaIpCfg);
|
||||
areaIpCfgDao.updateAreaIpCfgValid(areaIpCfg);
|
||||
@@ -1360,6 +1509,20 @@ public class AvContentCfgService extends BaseService{
|
||||
}
|
||||
}
|
||||
|
||||
// 修改审核状态
|
||||
BaseStringCfg baseStrCfg = this.getContUrlCfgById(entity);
|
||||
if(!StringUtil.isEmpty(baseStrCfg.getNtcSubscribeIdCfgList())) {
|
||||
NtcSubscribeIdCfg cfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(entity, cfg, new String[] {"cfgId","cfgType","cfgKeywords",
|
||||
"exprType","matchMethod","isHexbin"});
|
||||
stringCfgDao.updateSubscribeIdCfg(cfg);
|
||||
if(isAudit==1) {
|
||||
Map<String,List> map = cfgConvert(strRegionList,baseStrCfg.getNtcSubscribeIdCfgList(),2,entity,groupRelationList);
|
||||
groupRelationList=map.get("groupList");
|
||||
strRegionList=map.get("dstList");
|
||||
}
|
||||
}
|
||||
|
||||
//构造提交综合服务参数格式,一条配置提交一次综合服务
|
||||
if(isAudit==1){
|
||||
maatCfg.initDefaultValue();
|
||||
@@ -1429,9 +1592,14 @@ public class AvContentCfgService extends BaseService{
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
public BaseStringCfg getPicUrlCfgById(BaseStringCfg entity) {
|
||||
public BaseStringCfg<NtcSubscribeIdCfg> getPicUrlCfgById(BaseStringCfg entity) {
|
||||
entity.setTableName("av_pic_url_cfg");
|
||||
return avContentCfgDao.findStringCfgById(entity);
|
||||
BaseStringCfg cfg = avContentCfgDao.findStringCfgById(entity);
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(cfg, subscribeIdCfg, new String[] {"cfgId","isValid"});
|
||||
List<NtcSubscribeIdCfg> list = stringCfgDao.findSubscribeIdCfgList(subscribeIdCfg);
|
||||
cfg.setNtcSubscribeIdCfgList(list);
|
||||
return cfg;
|
||||
}
|
||||
@Transactional(readOnly=false,rollbackFor=RuntimeException.class)
|
||||
public void saveOrUpdatePicUrl(BaseStringCfg<BaseStringCfg> entity,String areaCfgIds){
|
||||
@@ -1454,6 +1622,20 @@ public class AvContentCfgService extends BaseService{
|
||||
logger.info("获取编译ID出错");
|
||||
throw new MaatConvertException("<spring:message code=\"request_service_failed\"/>:"+e.getMessage());
|
||||
}
|
||||
|
||||
// 添加subscribeId
|
||||
if(entity.getNtcSubscribeIdCfgList()!=null){
|
||||
for(NtcSubscribeIdCfg cfg:entity.getNtcSubscribeIdCfgList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
entity.setCompileId(compileIds.get(0));
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType",
|
||||
"cfgKeywords","exprType",
|
||||
"matchMethod","isHexbin"});
|
||||
stringCfgDao.saveSubscribeIdCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(compileIds != null && compileIds.size() >0 && compileIds.get(0) != 0){
|
||||
entity.setCompileId(compileIds.get(0));
|
||||
|
||||
@@ -1520,6 +1702,23 @@ public class AvContentCfgService extends BaseService{
|
||||
entity.setEditTime(editTime);
|
||||
entity.setTableName("av_pic_url_cfg");
|
||||
avContentCfgDao.updateString(entity);
|
||||
|
||||
entity.setCreateTime(new Date());
|
||||
entity.setCreatorId(entity.getCurrentUser().getId());
|
||||
// 删除SubscribeId配置再进行添加
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(entity, subscribeIdCfg,new String[]{"cfgId","cfgType"});
|
||||
stringCfgDao.deleteSubscribeIdCfg(subscribeIdCfg);
|
||||
if(entity.getNtcSubscribeIdCfgList()!=null){
|
||||
for(NtcSubscribeIdCfg cfg:entity.getNtcSubscribeIdCfgList()){
|
||||
if(StringUtils.isNotBlank(cfg.getCfgKeywords())){
|
||||
BeanUtils.copyProperties(entity, cfg,new String[]{"cfgRegionCode","cfgType",
|
||||
"cfgKeywords","exprType",
|
||||
"matchMethod","isHexbin"});
|
||||
stringCfgDao.saveSubscribeIdCfg(cfg);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1544,6 +1743,13 @@ public class AvContentCfgService extends BaseService{
|
||||
entity.setEditorId(UserUtils.getUser().getId());
|
||||
entity.setEditTime(new Date());
|
||||
avContentCfgDao.updateString(entity);
|
||||
// 查询域配置信息
|
||||
BaseStringCfg cfg = this.getContUrlCfgById(entity);
|
||||
if(cfg.getNtcSubscribeIdCfgList() != null && cfg.getNtcSubscribeIdCfgList().size()>0) {
|
||||
NtcSubscribeIdCfg subscribeIdCfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(cfg, subscribeIdCfg, new String[] {"cfgId","cfgType","tableName"});
|
||||
stringCfgDao.updateSubscribeIdCfg(subscribeIdCfg);
|
||||
}
|
||||
AreaIpCfg areaIpCfg=new AreaIpCfg();
|
||||
BeanUtils.copyProperties(entity, areaIpCfg);
|
||||
areaIpCfgDao.updateAreaIpCfgValid(areaIpCfg);
|
||||
@@ -1607,6 +1813,20 @@ public class AvContentCfgService extends BaseService{
|
||||
}
|
||||
}
|
||||
|
||||
// 修改审核状态
|
||||
BaseStringCfg baseStrCfg = this.getPicUrlCfgById(entity);
|
||||
if(!StringUtil.isEmpty(baseStrCfg.getNtcSubscribeIdCfgList())) {
|
||||
NtcSubscribeIdCfg cfg = new NtcSubscribeIdCfg();
|
||||
BeanUtils.copyProperties(entity, cfg, new String[] {"cfgId","cfgType","cfgKeywords",
|
||||
"exprType","matchMethod","isHexbin"});
|
||||
stringCfgDao.updateSubscribeIdCfg(cfg);
|
||||
if(isAudit==1) {
|
||||
Map<String,List> map = cfgConvert(strRegionList,baseStrCfg.getNtcSubscribeIdCfgList(),2,entity,groupRelationList);
|
||||
groupRelationList=map.get("groupList");
|
||||
strRegionList=map.get("dstList");
|
||||
}
|
||||
}
|
||||
|
||||
//构造提交综合服务参数格式,一条配置提交一次综合服务
|
||||
if(isAudit==1){
|
||||
maatCfg.initDefaultValue();
|
||||
|
||||
Reference in New Issue
Block a user