Browse Source

Merge branch 'master' of http://git.tjyourong.com.cn/ctop/adsp-boot

syh 5 years ago
parent
commit
bc45fa8a3c

+ 0 - 10
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/CallbackController.java

@@ -63,7 +63,6 @@ public class CallbackController {
     private IReportService reportService;
 
 
-
     @GetMapping("/qywexin")
     public void qywexin(HttpServletRequest request,
                         HttpServletResponse response,
@@ -322,8 +321,6 @@ public class CallbackController {
                 userAllocationQueryWrapper.eq("media_id", 1);
                 userAllocationQueryWrapper.orderByDesc("create_time");
                 userAllocationQueryWrapper.last("limit 1");
-
-
                 UserAllocation checkUserAllocation = allocationMapper.selectOne(userAllocationQueryWrapper);
                 if (!Check.isNull(checkUserAllocation)) {
                     text.append("accountId:" + accountId + ",授权名称为:" + (String) advertiserDataMap.get("name") + ",绑定失败,失败原因:已被" + checkUserAllocation.getUserName() + "绑定。")
@@ -347,11 +344,6 @@ public class CallbackController {
                 userAllocation.setWarningAmount(warningAmount);
                 userAllocation.setCreateTime(new Date());
                 userAllocation.setUpdateTime(new Date());
-                allocationMapper.deleteById(userAllocation.getId());
-                Map<String, Object> deleteUserMap = new HashMap<>();
-                deleteUserMap.put("advertiser_id", advertiserId);
-                deleteUserMap.put("account_id", token.getAccountId());
-                allocationMapper.deleteByMap(deleteUserMap);
                 int j = allocationMapper.insert(userAllocation);
                 if (j > 0) {
                     log.info("同步分配用户表完成,task_id:{},accountId:{}", state, token.getAccountId());
@@ -373,6 +365,4 @@ public class CallbackController {
     }
 
 
-
-
 }

+ 4 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/MaterialInfoController.java

@@ -493,6 +493,10 @@ public class MaterialInfoController {
         List<String> effiList = materialInfoService.getEffiCode();
         Object createTime = materialInfo.getCreateTime();
         materialInfo.setCreateTime(null);
+        Long projectId = materialInfo.getProjectId();
+        if(projectId != null){
+            queryWrapper.eq("project_id", projectId);
+        }
         queryWrapper.in("code", effiList);
         queryWrapper.groupBy("code");
         //queryWrapper = QueryGenerator.initQueryWrapper(materialInfo, req.getParameterMap());