Browse Source

Merge branch 'matomo' of wangfan/adweb3-server into master

wangfan 2 months ago
parent
commit
ff3f5c3872
15 changed files with 117 additions and 111 deletions
  1. BIN
      conf/adweb_v3.sql.zip
  2. 8 7
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebEnquiryBlacklistController.java
  3. 18 17
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebEnquiryController.java
  4. 2 2
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebPublicBlackEmailController.java
  5. 2 2
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebPublicBlackIpController.java
  6. 8 8
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebPublicEnquriyRuleController.java
  7. 2 2
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebSiteBlackEmailController.java
  8. 4 4
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebSiteBlackIpController.java
  9. 13 13
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/service/impl/AdwebEnquiryServiceImpl.java
  10. 9 5
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/service/impl/EnquiryEmailMessageServiceImpl.java
  11. 7 7
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/product/service/impl/AdwebProductServiceImpl.java
  12. 4 5
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/site/controller/AdwebSiteController.java
  13. 5 5
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/site/controller/AdwebSiteManageController.java
  14. 5 5
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/site/service/impl/AdwebSiteServiceImpl.java
  15. 30 29
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/userCountry/controller/AdwebUserCountryController.java

BIN
conf/adweb_v3.sql.zip


+ 8 - 7
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebEnquiryBlacklistController.java

@@ -1,7 +1,7 @@
 package org.jeecg.modules.adweb.enquiry.controller;
 
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
 import com.baomidou.mybatisplus.core.toolkit.StringUtils;
@@ -11,6 +11,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
 import jakarta.annotation.Resource;
 import jakarta.servlet.http.HttpServletRequest;
 import jakarta.servlet.http.HttpServletResponse;
+import kotlin.jvm.internal.Lambda;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.shiro.SecurityUtils;
 import org.jeecg.common.api.vo.Result;
@@ -188,9 +189,9 @@ public class AdwebEnquiryBlacklistController extends JeecgController<AdwebEnquir
         blacklist.setCreateTime(new Date());
         adwebEnquiryBlacklistService.save(blacklist);
 
-        UpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new UpdateWrapper<>();
-        enquiryUpdateWrapper.eq("id", adwebEnquiry.getId());
-        enquiryUpdateWrapper.set("status", 0);
+        LambdaUpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new LambdaUpdateWrapper<>();
+        enquiryUpdateWrapper.eq(AdwebEnquiry::getId, adwebEnquiry.getId());
+        enquiryUpdateWrapper.set(AdwebEnquiry::getStatus, 0);
         adwebEnquiryService.update(enquiryUpdateWrapper);
 
         return Result.OK("添加成功!");
@@ -234,9 +235,9 @@ public class AdwebEnquiryBlacklistController extends JeecgController<AdwebEnquir
     public Result<?> removeBlacklist(@RequestParam(name = "id") String id) {
         LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
 
-        UpdateWrapper<AdwebEnquiryBlacklist> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.in("id", id.split(","));
-        updateWrapper.set("status", 0);
+        LambdaUpdateWrapper<AdwebEnquiryBlacklist> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.in(AdwebEnquiryBlacklist::getId, id.split(","));
+        updateWrapper.set(AdwebEnquiryBlacklist::getStatus, 0);
         adwebEnquiryBlacklistService.update(updateWrapper);
         return Result.OK("删除成功!");
     }

+ 18 - 17
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebEnquiryController.java

@@ -2,7 +2,7 @@ package org.jeecg.modules.adweb.enquiry.controller;
 
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import io.swagger.v3.oas.annotations.Operation;
@@ -33,6 +33,7 @@ import org.jeecg.modules.adweb.enquiry.dto.param.EnquirySearchDto;
 import org.jeecg.modules.adweb.enquiry.dto.result.EnquiryListDto;
 import org.jeecg.modules.adweb.enquiry.dto.result.EnquirySpecialFields;
 import org.jeecg.modules.adweb.enquiry.entity.AdwebEnquiry;
+import org.jeecg.modules.adweb.enquiry.entity.AdwebEnquiryBlacklist;
 import org.jeecg.modules.adweb.enquiry.entity.EnquiryEmailMessage;
 import org.jeecg.modules.adweb.enquiry.mapper.AdwebEnquiryMapper;
 import org.jeecg.modules.adweb.enquiry.service.IAdwebEnquiryService;
@@ -515,9 +516,9 @@ public class AdwebEnquiryController extends JeecgController<AdwebEnquiry, IAdweb
         if (disableAdminRead && (sysAdwebApi.isAdmin() || sysAdwebApi.isChannelAdmin())) {
             return Result.OK();
         }
-        UpdateWrapper<AdwebEnquiry> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.in("id", id);
-        updateWrapper.set("read_status", 1);
+        LambdaUpdateWrapper<AdwebEnquiry> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.in(AdwebEnquiry::getId, id);
+        updateWrapper.set(AdwebEnquiry::getReadStatus, 1);
         adwebEnquiryService.update(updateWrapper);
         return Result.OK();
     }
@@ -530,9 +531,9 @@ public class AdwebEnquiryController extends JeecgController<AdwebEnquiry, IAdweb
     @ResponseBody
     public Result<String> getEnquiryTrans(String query, String id) {
         String text = awsTranslateUtils.translate(query);
-        UpdateWrapper<AdwebEnquiry> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.eq("id", id);
-        updateWrapper.set("trans_content", text);
+        LambdaUpdateWrapper<AdwebEnquiry> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.eq(AdwebEnquiry::getId, id);
+        updateWrapper.set(AdwebEnquiry::getTrackStatus, text);
         adwebEnquiryService.update(updateWrapper);
 
         return Result.ok(text);
@@ -565,10 +566,10 @@ public class AdwebEnquiryController extends JeecgController<AdwebEnquiry, IAdweb
             return Result.error("该账户未设置邮箱!");
         }
         List<String> idList = Arrays.asList(ids.split(","));
-        UpdateWrapper<AdwebEnquiry> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.in("id", idList);
-        updateWrapper.set("principal_uid", uid);
-        updateWrapper.set("principal_type", 1);
+        LambdaUpdateWrapper<AdwebEnquiry> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.in(AdwebEnquiry::getId, idList);
+        updateWrapper.set(AdwebEnquiry::getPrincipalUid, uid);
+        updateWrapper.set(AdwebEnquiry::getPrincipalType, 1);
         adwebEnquiryService.update(updateWrapper);
 
         QueryWrapper<AdwebEnquiry> queryWrapper = new QueryWrapper<>();
@@ -654,9 +655,9 @@ public class AdwebEnquiryController extends JeecgController<AdwebEnquiry, IAdweb
     public Result<?> refreshBatch(@RequestBody AdwebEnquiry adwebEnquiry) {
         LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
 
-        UpdateWrapper<AdwebEnquiry> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.in("id", adwebEnquiry.getNo().split(","));
-        updateWrapper.set("status", 1);
+        LambdaUpdateWrapper<AdwebEnquiry> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.in(AdwebEnquiry::getId, adwebEnquiry.getNo().split(","));
+        updateWrapper.set(AdwebEnquiry::getStatus, 1);
         adwebEnquiryService.update(updateWrapper);
 
         return Result.OK("批量复原成功!");
@@ -671,9 +672,9 @@ public class AdwebEnquiryController extends JeecgController<AdwebEnquiry, IAdweb
     @GetMapping(value = "/delBatch")
     public Result<?> delBatch(@RequestParam("id") String id) {
 
-        UpdateWrapper<AdwebEnquiry> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.in("id", id.split(","));
-        updateWrapper.set("status", 0);
+        LambdaUpdateWrapper<AdwebEnquiry> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.in(AdwebEnquiry::getId, id.split(","));
+        updateWrapper.set(AdwebEnquiry::getStatus, 0);
         this.adwebEnquiryService.update(updateWrapper);
         return Result.OK("批量删除成功!");
     }

+ 2 - 2
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebPublicBlackEmailController.java

@@ -1,7 +1,7 @@
 package org.jeecg.modules.adweb.enquiry.controller;
 
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import io.swagger.v3.oas.annotations.Operation;
@@ -241,7 +241,7 @@ public class AdwebPublicBlackEmailController extends JeecgController<AdwebPublic
             return Result.error("未找到对应数据");
         }
 
-        boolean update = adwebPublicBlackEmailService.update(new UpdateWrapper<AdwebPublicBlackEmail>().in("id", idList).set("status", 0));
+        boolean update = adwebPublicBlackEmailService.update(new LambdaUpdateWrapper<AdwebPublicBlackEmail>().in(AdwebPublicBlackEmail::getId, idList).set(AdwebPublicBlackEmail::getStatus, 0));
 
         //删除redis中的数据
         for (AdwebPublicBlackEmail enquiryPublicBlackEmail : list) {

+ 2 - 2
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebPublicBlackIpController.java

@@ -1,7 +1,7 @@
 package org.jeecg.modules.adweb.enquiry.controller;
 
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import io.swagger.v3.oas.annotations.Operation;
@@ -236,7 +236,7 @@ public class AdwebPublicBlackIpController extends JeecgController<AdwebPublicBla
             return Result.error("该IP不存在");
         }
 
-        adwebBlackIpService.update(new UpdateWrapper<AdwebPublicBlackIp>().in("id", idList).set("status", 0));
+        adwebBlackIpService.update(new LambdaUpdateWrapper<AdwebPublicBlackIp>().in(AdwebPublicBlackIp::getId, idList).set(AdwebPublicBlackIp::getStatus, 0));
 
         for (AdwebPublicBlackIp adwebBlackIp : list) {
             adwebRedisUtil.del(IpTenMinKey + adwebBlackIp.getIp());

+ 8 - 8
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebPublicEnquriyRuleController.java

@@ -5,7 +5,7 @@ import cn.hutool.poi.excel.ExcelReader;
 import cn.hutool.poi.excel.ExcelUtil;
 import cn.hutool.poi.excel.ExcelWriter;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import io.swagger.v3.oas.annotations.Operation;
@@ -142,7 +142,7 @@ public class AdwebPublicEnquriyRuleController extends JeecgController<AdwebPubli
         if (id == null) {
             return Result.error("参数不识别!");
         }
-        boolean update = adwebEnquiryRuleService.update(new UpdateWrapper<AdwebPublicEnquiryRule>().set("status", 0).eq("id", id));
+        boolean update = adwebEnquiryRuleService.update(new LambdaUpdateWrapper<AdwebPublicEnquiryRule>().set(AdwebPublicEnquiryRule::getStatus, 0).eq(AdwebPublicEnquiryRule::getId, id));
 
         return update ? Result.OK("删除成功!") : Result.error("删除失败!");
     }
@@ -161,7 +161,7 @@ public class AdwebPublicEnquriyRuleController extends JeecgController<AdwebPubli
             return Result.error("参数不识别!");
         }
         List<String> idList = Arrays.asList(ids.split(","));
-        boolean update = adwebEnquiryRuleService.update(new UpdateWrapper<AdwebPublicEnquiryRule>().set("status", 0).in("id", idList));
+        boolean update = adwebEnquiryRuleService.update(new LambdaUpdateWrapper<AdwebPublicEnquiryRule>().set(AdwebPublicEnquiryRule::getStatus, 0).in(AdwebPublicEnquiryRule::getId, idList));
         return update ? Result.OK("批量删除成功!") : Result.error("批量删除失败!");
     }
 
@@ -265,11 +265,11 @@ public class AdwebPublicEnquriyRuleController extends JeecgController<AdwebPubli
             }
 
             for (AdwebPublicEnquiryRule adwebEnquiryRule : rulesList) {
-                UpdateWrapper updateWrapper = new UpdateWrapper();
-                updateWrapper.eq("word", adwebEnquiryRule.getWord());
-                updateWrapper.ne("status", 0);
-                updateWrapper.eq("use_status", 0);
-                updateWrapper.set("translate_word", adwebEnquiryRule.getTranslateWord());
+                LambdaUpdateWrapper<AdwebPublicEnquiryRule> updateWrapper = new LambdaUpdateWrapper();
+                updateWrapper.eq(AdwebPublicEnquiryRule::getWord, adwebEnquiryRule.getWord());
+                updateWrapper.ne(AdwebPublicEnquiryRule::getStatus, 0);
+                updateWrapper.eq(AdwebPublicEnquiryRule::getUseStatus, 0);
+                updateWrapper.set(AdwebPublicEnquiryRule::getTranslateWord, adwebEnquiryRule.getTranslateWord());
                 adwebEnquiryRuleService.update(updateWrapper);
             }
 

+ 2 - 2
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebSiteBlackEmailController.java

@@ -1,7 +1,7 @@
 package org.jeecg.modules.adweb.enquiry.controller;
 
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import io.swagger.v3.oas.annotations.Operation;
@@ -434,7 +434,7 @@ public class AdwebSiteBlackEmailController extends JeecgController<AdwebSiteBlac
             return Result.error("未找到对应数据");
         }
 
-        boolean update = enquirySiteBlackEmailService.update(new UpdateWrapper<AdwebSiteBlackEmail>().in("id", idList).set("status", 0));
+        boolean update = enquirySiteBlackEmailService.update(new LambdaUpdateWrapper<AdwebSiteBlackEmail>().in(AdwebSiteBlackEmail::getId, idList).set(AdwebSiteBlackEmail::getStatus, 0));
 
         HashSet<Integer> siteList = new HashSet<>();
         //删除redis中的数据

+ 4 - 4
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebSiteBlackIpController.java

@@ -1,7 +1,7 @@
 package org.jeecg.modules.adweb.enquiry.controller;
 
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import io.swagger.v3.oas.annotations.Operation;
@@ -289,9 +289,9 @@ public class AdwebSiteBlackIpController extends JeecgController<AdwebSiteBlackIp
             return Result.error("该IP不存在");
         }
 
-        UpdateWrapper<AdwebSiteBlackIp> adwebSiteBlackIpUpdateWrapper = new UpdateWrapper<>();
-        adwebSiteBlackIpUpdateWrapper.in("id", idList);
-        adwebSiteBlackIpUpdateWrapper.set("status", 0);
+        LambdaUpdateWrapper<AdwebSiteBlackIp> adwebSiteBlackIpUpdateWrapper = new LambdaUpdateWrapper<>();
+        adwebSiteBlackIpUpdateWrapper.in(AdwebSiteBlackIp::getId, idList);
+        adwebSiteBlackIpUpdateWrapper.set(AdwebSiteBlackIp::getStatus, 0);
         adwebSiteBlackIpService.update(adwebSiteBlackIpUpdateWrapper);
 
         HashSet<Integer> siteIdHashSet = new HashSet<Integer>();

+ 13 - 13
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/service/impl/AdwebEnquiryServiceImpl.java

@@ -4,7 +4,7 @@ import com.alibaba.fastjson.JSON;
 import com.alibaba.fastjson.JSONObject;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.fasterxml.jackson.core.JsonProcessingException;
 import com.fasterxml.jackson.databind.ObjectMapper;
@@ -1876,37 +1876,37 @@ public class AdwebEnquiryServiceImpl extends ServiceImpl<AdwebEnquiryMapper, Adw
             return false;
         }
 
-        UpdateWrapper<AdwebEnquiry> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.in("id", idList);
+        LambdaUpdateWrapper<AdwebEnquiry> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.in(AdwebEnquiry::getId, idList);
         // 用户有效性  0:无效 1:有效   2 : 待定 取自字典表
-        updateWrapper.set("user_effective", userEffective);
+        updateWrapper.set(AdwebEnquiry::getUserEffective, userEffective);
         // 0:不是;1:是
         if (userEffective.equals(0)) {  // 垃圾询盘
             String wasteEnquiryType = effectiveEnquiryParamDto.getWasteEnquiryType();
             String wasteEnquirySeason = effectiveEnquiryParamDto.getWasteEnquirySeason();
-            updateWrapper.set("waste_enquiry", 1);
-            updateWrapper.set("waste_enquiry_type", wasteEnquiryType);
+            updateWrapper.set(AdwebEnquiry::getWasteEnquiry, 1);
+            updateWrapper.set(AdwebEnquiry::getWasteEnquiryType, wasteEnquiryType);
 
             //特殊处理垃圾询盘是邮箱或者ip
             if (wasteEnquiryType.equals("ip")) {
-                updateWrapper.set("effective_reason", "人工操作-ip-" + wasteEnquirySeason);
+                updateWrapper.set(AdwebEnquiry::getEffectiveReason, "人工操作-ip-" + wasteEnquirySeason);
                 adwebSiteBlackIpService.addBlackIpByContent(effectiveEnquiryParamDto);
             }
             if (wasteEnquiryType.equals("email")) {
-                updateWrapper.set("effective_reason", "人工操作-邮箱-" + wasteEnquirySeason);
+                updateWrapper.set(AdwebEnquiry::getEffectiveReason, "人工操作-邮箱-" + wasteEnquirySeason);
                 enquirySiteBlackEmailService.addBlackEmailByContent(effectiveEnquiryParamDto);
             }
             if (wasteEnquiryType.equals("keyword")) {
-                updateWrapper.set("effective_reason", "人工操作-关键词-" + wasteEnquirySeason);
+                updateWrapper.set(AdwebEnquiry::getEffectiveReason, "人工操作-关键词-" + wasteEnquirySeason);
                 adwebSiteEnquiryRuleService.addBlackKeywordByContent(effectiveEnquiryParamDto);
             }
             if (wasteEnquiryType.equals("other")) {
-                updateWrapper.set("effective_reason", "人工操作-其他-" + wasteEnquirySeason);
+                updateWrapper.set(AdwebEnquiry::getEffectiveReason, "人工操作-其他-" + wasteEnquirySeason);
             }
         } else {  // 有效询盘
-            updateWrapper.set("waste_enquiry", 0);
-            updateWrapper.set("effective_reason", "人工操作");
-            updateWrapper.set("waste_enquiry_type", "");
+            updateWrapper.set(AdwebEnquiry::getWasteEnquiry, 0);
+            updateWrapper.set(AdwebEnquiry::getEffectiveReason, "人工操作");
+            updateWrapper.set(AdwebEnquiry::getWasteEnquiryType, "");
         }
         this.update(updateWrapper);
 

+ 9 - 5
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/service/impl/EnquiryEmailMessageServiceImpl.java

@@ -1,13 +1,17 @@
 package org.jeecg.modules.adweb.enquiry.service.impl;
 
 import cn.hutool.core.collection.CollUtil;
+
 import com.alibaba.fastjson.JSONObject;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.google.common.io.Resources;
+
 import jakarta.annotation.Resource;
+
 import lombok.Data;
+
 import org.apache.commons.collections4.CollectionUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.jeecg.common.api.vo.Result;
@@ -94,10 +98,10 @@ public class EnquiryEmailMessageServiceImpl extends ServiceImpl<EnquiryEmailMess
         queryWrapper.eq("send_status", EnquirySendStatus.WAIT_SEND);
         List<EnquiryEmailMessage> messageList = list(queryWrapper);
         if (CollUtil.isNotEmpty(messageList)) {
-            UpdateWrapper<EnquiryEmailMessage> updateWrapper = new UpdateWrapper<>();
-            updateWrapper.in("id", messageList.stream().map(EnquiryEmailMessage::getId).collect(Collectors.toList()));
-            updateWrapper.set("send_status", EnquirySendStatus.SENDING);
-            updateWrapper.set("send_start_time", new Date());
+            LambdaUpdateWrapper<EnquiryEmailMessage> updateWrapper = new LambdaUpdateWrapper<>();
+            updateWrapper.in(EnquiryEmailMessage::getId, messageList.stream().map(EnquiryEmailMessage::getId).collect(Collectors.toList()));
+            updateWrapper.set(EnquiryEmailMessage::getSendStatus, EnquirySendStatus.SENDING);
+            updateWrapper.set(EnquiryEmailMessage::getSendStartTime, new Date());
             this.update(updateWrapper);
             for (EnquiryEmailMessage message : messageList) {
                 sendEmailByMessage(message);

+ 7 - 7
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/product/service/impl/AdwebProductServiceImpl.java

@@ -6,7 +6,7 @@ import cn.hutool.http.HttpRequest;
 import cn.hutool.http.HttpResponse;
 import com.alibaba.fastjson.JSONObject;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import lombok.extern.slf4j.Slf4j;
 import org.jeecg.modules.adweb.common.constant.AdwebConstant;
@@ -70,12 +70,12 @@ public class AdwebProductServiceImpl extends ServiceImpl<AdwebProductMapper, Adw
     }
 
     private void handleDelete(ProductDTO productDTO, AdwebSite adwebSites) {
-        UpdateWrapper<AdwebProduct> productQuery = new UpdateWrapper<>();
-        productQuery.eq("product_id", productDTO.getProductId());
-        productQuery.eq("site_code", adwebSites.getCode());
-        productQuery.set("action_type", "delete");
-        productQuery.set("request_time", productDTO.getRequestTime());
-        productQuery.set("author_name", productDTO.getAuthorName());
+        LambdaUpdateWrapper<AdwebProduct> productQuery = new LambdaUpdateWrapper<>();
+        productQuery.eq(AdwebProduct::getProductId, productDTO.getProductId());
+        productQuery.eq(AdwebProduct::getSiteCode, adwebSites.getCode());
+        productQuery.set(AdwebProduct::getActionType, "delete");
+        productQuery.set(AdwebProduct::getRequestTime, productDTO.getRequestTime());
+        productQuery.set(AdwebProduct::getAuthorName, productDTO.getAuthorName());
 
         try {
             boolean isUpdated = this.update(productQuery);

+ 4 - 5
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/site/controller/AdwebSiteController.java

@@ -2,7 +2,7 @@ package org.jeecg.modules.adweb.site.controller;
 
 import com.alibaba.fastjson.JSONObject;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import io.netty.util.internal.StringUtil;
@@ -293,12 +293,11 @@ public class AdwebSiteController extends JeecgController<AdwebSite, IAdwebSiteSe
 
 
         // 更新流程步骤和状态
-        UpdateWrapper<AdwebSite> siteUpdateWrapper = new UpdateWrapper<>();
-        siteUpdateWrapper.eq("code", siteStepDTO.getSiteCode());
+        LambdaUpdateWrapper<AdwebSite> siteUpdateWrapper = new LambdaUpdateWrapper<>();
+        siteUpdateWrapper.eq(AdwebSite::getCode, siteStepDTO.getSiteCode());
 
         //建站流程
-
-        siteUpdateWrapper.set("site_current_step", siteStepDTO.getCurrentStep()).set("site_flow_status", siteStepDTO.getStepFlowId());
+        siteUpdateWrapper.set(AdwebSite::getSiteCurrentStep, siteStepDTO.getCurrentStep()).set(AdwebSite::getSiteFlowStatus, siteStepDTO.getStepFlowId());
 
         adwebSiteService.update(siteUpdateWrapper);
         return Result.OK();

+ 5 - 5
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/site/controller/AdwebSiteManageController.java

@@ -4,7 +4,7 @@ package org.jeecg.modules.adweb.site.controller;
 import cn.hutool.core.bean.BeanUtil;
 import com.alibaba.fastjson.JSON;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import io.swagger.v3.oas.annotations.tags.Tag;
 import jakarta.annotation.Resource;
 import lombok.extern.slf4j.Slf4j;
@@ -165,10 +165,10 @@ public class AdwebSiteManageController extends JeecgController<AdwebSite, IAdweb
 
         log.info("设置站点询盘邮箱列表,站点code:{},邮箱列表:{}", siteCode, emailList);
 
-        boolean update = adwebSiteManageService.update(new UpdateWrapper<AdwebSite>()
-                .set("company_name", companyName)
-                .set("enquiry_email_list", CollectionUtils.isEmpty(emailList) ? null : JSON.toJSONString(emailList))
-                .eq("code", siteCode));
+        boolean update = adwebSiteManageService.update(new LambdaUpdateWrapper<AdwebSite>()
+                .set(AdwebSite::getCompanyName, companyName)
+                .set(AdwebSite::getEnquiryEmailList, CollectionUtils.isEmpty(emailList) ? null : JSON.toJSONString(emailList))
+                .eq(AdwebSite::getCode, siteCode));
 
         return update ? Result.OK("设置成功") : Result.error("设置失败");
     }

+ 5 - 5
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/site/service/impl/AdwebSiteServiceImpl.java

@@ -2,7 +2,7 @@ package org.jeecg.modules.adweb.site.service.impl;
 
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.xkcoding.http.util.StringUtil;
 import jakarta.annotation.Resource;
@@ -270,10 +270,10 @@ public class AdwebSiteServiceImpl extends ServiceImpl<AdwebSiteMapper, AdwebSite
         DictModel currentDictModel = dictModels.stream().filter(dictModel -> dictModel.getValue().equals("1")).toList().get(0);
 
 
-        UpdateWrapper<AdwebSite> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.eq("code", siteCode);
-        updateWrapper.set("site_flow_status", 1);
-        updateWrapper.set("site_current_step", currentDictModel.getText());
+        LambdaUpdateWrapper<AdwebSite> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.eq(AdwebSite::getCode, siteCode);
+        updateWrapper.set(AdwebSite::getSiteFlowStatus, 1);
+        updateWrapper.set(AdwebSite::getSiteCurrentStep, currentDictModel.getText());
         return this.update(updateWrapper);
     }
 

+ 30 - 29
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/userCountry/controller/AdwebUserCountryController.java

@@ -2,7 +2,7 @@ package org.jeecg.modules.adweb.userCountry.controller;
 
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@@ -11,6 +11,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
 import jakarta.annotation.Resource;
 import jakarta.servlet.http.HttpServletRequest;
 import jakarta.servlet.http.HttpServletResponse;
+import kotlin.jvm.internal.Lambda;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.shiro.SecurityUtils;
@@ -331,11 +332,11 @@ public class AdwebUserCountryController extends JeecgController<AdwebUserCountry
         List<String> countryCodes = countries.stream().map(AdwebCountry::getCountryIsoCode).collect(Collectors.toList());
 
         List<Integer> siteIds = adwebSiteService.getAllSiteIdByParentId(param.getSiteId());
-        UpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new UpdateWrapper<>();
-        enquiryUpdateWrapper.in("country_code", countryCodes);
-        enquiryUpdateWrapper.in("site_id", siteIds);
-        enquiryUpdateWrapper.ne("principal_type", 1);
-        enquiryUpdateWrapper.set("principal_uid", param.getUid());
+        LambdaUpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new LambdaUpdateWrapper<>();
+        enquiryUpdateWrapper.in(AdwebEnquiry::getCountryCode, countryCodes);
+        enquiryUpdateWrapper.in(AdwebEnquiry::getSiteId, siteIds);
+        enquiryUpdateWrapper.ne(AdwebEnquiry::getPrincipalType, 1);
+        enquiryUpdateWrapper.set(AdwebEnquiry::getPrincipalUid, param.getUid());
         adwebEnquiryService.update(enquiryUpdateWrapper);
 
         return Result.OK();
@@ -364,28 +365,28 @@ public class AdwebUserCountryController extends JeecgController<AdwebUserCountry
             Collections.addAll(countryIdList, countryIds.split(","));
         }
         countryIdList.removeIf(this::notNum);
-        UpdateWrapper<AdwebUserCountry> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.eq("uid", uid);
-        updateWrapper.eq("site_id", param.getSiteId());
+        LambdaUpdateWrapper<AdwebUserCountry> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.eq(AdwebUserCountry::getUid, uid);
+        updateWrapper.eq(AdwebUserCountry::getSiteId, param.getSiteId());
         if (CollectionUtils.isNotEmpty(countryIdList)) {
-            updateWrapper.notIn("country_id", countryIdList);
+            updateWrapper.notIn(AdwebUserCountry::getCountryId, countryIdList);
         }
-        updateWrapper.set("status", 0);
+        updateWrapper.set(AdwebUserCountry::getStatus, 0);
         adwebUserCountryService.update(updateWrapper);
 
         // 更改相关询盘的负责人
         List<Integer> siteIds = adwebSiteService.getAllSiteIdByParentId(param.getSiteId());
-        UpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new UpdateWrapper<>();
+        LambdaUpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new LambdaUpdateWrapper<>();
         if (CollectionUtils.isNotEmpty(countryIdList)) {
-            QueryWrapper<AdwebCountry> countryQueryWrapper = new QueryWrapper<>();
-            countryQueryWrapper.in("geoname_id", countryIdList);
+            LambdaQueryWrapper<AdwebCountry> countryQueryWrapper = new LambdaQueryWrapper<>();
+            countryQueryWrapper.in(AdwebCountry::getGeonameId, countryIdList);
             List<AdwebCountry> countries = admpCountryService.list(countryQueryWrapper);
             List<String> countryCodes = countries.stream().map(AdwebCountry::getCountryIsoCode).collect(Collectors.toList());
-            enquiryUpdateWrapper.notIn("country_code", countryCodes);
+            enquiryUpdateWrapper.notIn(AdwebEnquiry::getCountryCode, countryCodes);
         }
-        enquiryUpdateWrapper.in("site_id", siteIds);
-        enquiryUpdateWrapper.eq("principal_uid", param.getUid());
-        enquiryUpdateWrapper.ne("principal_type", 1);
+        enquiryUpdateWrapper.in(AdwebEnquiry::getSiteId, siteIds);
+        enquiryUpdateWrapper.eq(AdwebEnquiry::getPrincipalUid, param.getUid());
+        enquiryUpdateWrapper.ne(AdwebEnquiry::getPrincipalType, 1);
         enquiryUpdateWrapper.setSql("principal_uid = uid");
         adwebEnquiryService.update(enquiryUpdateWrapper);
         return Result.OK();
@@ -401,21 +402,21 @@ public class AdwebUserCountryController extends JeecgController<AdwebUserCountry
 //        if(sysUser.isPerform()){
 //            return Result.FORBIDDEN("\"演示版\"没有操作权限,如果需要操作,请切换到\"正式版\"再操作!");
 //        }
-        UpdateWrapper<AdwebSite> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.eq("id", siteId);
-        updateWrapper.set("enquiry_distribute_type", distributeType);
+        LambdaUpdateWrapper<AdwebSite> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.eq(AdwebSite::getId, siteId);
+        updateWrapper.set(AdwebSite::getEnquiryDistributeType, distributeType);
         adwebSiteService.update(updateWrapper);
 
         // 修改询盘的跟进人
         if (EnquiryDistributeTypeConstant.MASTER.equals(distributeType)) {
-            UpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new UpdateWrapper<>();
-            enquiryUpdateWrapper.ne("principal_type", 1);
+            LambdaUpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new LambdaUpdateWrapper<>();
+            enquiryUpdateWrapper.ne(AdwebEnquiry::getPrincipalType, 1);
             enquiryUpdateWrapper.setSql("principal_uid = uid");
             adwebEnquiryService.update(enquiryUpdateWrapper);
         } else if (EnquiryDistributeTypeConstant.ALL.equals(distributeType)) {
-            UpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new UpdateWrapper<>();
-            enquiryUpdateWrapper.ne("principal_type", 1);
-            enquiryUpdateWrapper.set("principal_uid", "ALL");
+            LambdaUpdateWrapper<AdwebEnquiry> enquiryUpdateWrapper = new LambdaUpdateWrapper<>();
+            enquiryUpdateWrapper.ne(AdwebEnquiry::getPrincipalType, 1);
+            enquiryUpdateWrapper.set(AdwebEnquiry::getPrincipalUid, "ALL");
             adwebEnquiryService.update(enquiryUpdateWrapper);
         } else if (EnquiryDistributeTypeConstant.REGION.equals(distributeType)) {
             adwebEnquiryService.updatePrincipalUidByRegion(siteId);
@@ -433,9 +434,9 @@ public class AdwebUserCountryController extends JeecgController<AdwebUserCountry
 //        if(sysUser.isPerform()){
 //            return Result.FORBIDDEN("\"演示版\"没有操作权限,如果需要操作,请切换到\"正式版\"再操作!");
 //        }
-        UpdateWrapper<AdwebSite> updateWrapper = new UpdateWrapper<>();
-        updateWrapper.eq("id", siteId);
-        updateWrapper.set("enquiry_send_email_type", sendEmailType);
+        LambdaUpdateWrapper<AdwebSite> updateWrapper = new LambdaUpdateWrapper<>();
+        updateWrapper.eq(AdwebSite::getId, siteId);
+        updateWrapper.set(AdwebSite::getEnquirySendEmailType, sendEmailType);
         adwebSiteService.update(updateWrapper);
 
         return Result.OK();