Commit 288a9cf2 by fudahua

会员标签同步-删除标签

parent 824e5770
......@@ -3,6 +3,7 @@ package com.gic.haoban.manage.service.service.impl;
import com.gic.commons.util.ToolUtil;
import com.gic.haoban.manage.api.dto.QywxTagInfoDTO;
import com.gic.haoban.manage.api.dto.QywxTagItemDTO;
import com.gic.haoban.manage.api.enums.QywxTagRelationSyncFlagEnum;
import com.gic.haoban.manage.api.enums.QywxTagRelationTypeEnum;
import com.gic.haoban.manage.service.dao.mapper.QywxTagItemMapper;
import com.gic.haoban.manage.service.dao.mapper.QywxTagMapper;
......@@ -250,6 +251,10 @@ public class QywxTagServiceImpl implements QywxTagService {
@Override
public boolean changeRelationSyncFlagByMemberTagId(String wxEnterpriseId, String memberTagId, Integer syncFlag) {
if (syncFlag == QywxTagRelationSyncFlagEnum.DEL.getType() || syncFlag == QywxTagRelationSyncFlagEnum.FAIL.getType()) {
this.closeSync(wxEnterpriseId, memberTagId);
return true;
}
qywxTagRelationMapper.changeRelationSyncFlag(wxEnterpriseId, memberTagId, syncFlag);
return true;
}
......
......@@ -334,7 +334,8 @@ public class QywxTagApiServiceImpl implements QywxTagApiService {
TabQywxTagRelation relation = relations.stream().findFirst().get();
logger.info("删除标签组 关闭同步:{}", relation.getMemberTagId());
//删除同步 关闭同步
this.closeSync(wxEnterpriseDto.getWxEnterpriseId(), relation.getMemberTagId());
qywxTagService.closeSync(wxEnterpriseDto.getWxEnterpriseId(), relation.getMemberTagId());
qywxTagService.delQywxTag(callbackDTO.getTagId(), wxEnterpriseDto.getWxEnterpriseId());
//标签项
} else if (relationTypeEnum.getTagType() == QywxTagRelationTypeEnum.TAG_ITEM.getTagType()) {
......@@ -346,7 +347,8 @@ public class QywxTagApiServiceImpl implements QywxTagApiService {
}
logger.info("删除标签 关闭同步:{}", qywxTagRelation.getMemberTagId());
//删除同步 关闭同步
this.closeSync(wxEnterpriseDto.getWxEnterpriseId(), qywxTagRelation.getMemberTagId());
qywxTagService.closeSync(wxEnterpriseDto.getWxEnterpriseId(), qywxTagRelation.getMemberTagId());
qywxTagService.delQywxTagItemById(wxEnterpriseDto.getWxEnterpriseId(), qywxTagRelation.getQywxTagItemId());
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment