Browse Source

Merge branch 'cpq-dev' of wangfan/adweb3-server into master

chenpeiqing 2 weeks ago
parent
commit
19e5ab9c20
16 changed files with 715 additions and 331 deletions
  1. 33 27
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/common/constant/NumConstant.java
  2. 14 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/controller/AdwebEnquiryController.java
  3. 25 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/dto/matomo/MatomoActionDetailEnquiryIpDto.java
  4. 23 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/dto/matomo/MatomoBrowsingBehaviorDto.java
  5. 39 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/dto/matomo/MatomoBrowsingEnquiryIdDto.java
  6. 20 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/dto/matomo/MatomoWebHistoryDto.java
  7. 62 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/entity/AdwebMatomo.java
  8. 9 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/mapper/AdwebMatomoMapper.java
  9. 29 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/service/IAdwebMatomoService.java
  10. 151 0
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/service/impl/AdwebMatomoServiceImpl.java
  11. 2 24
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/product/service/impl/AdwebProductServiceImpl.java
  12. 268 278
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/site/controller/AdwebSiteController.java
  13. 5 2
      jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/mq/ProductReceiver.java
  14. 13 0
      jeecg-module-system/jeecg-system-start/src/main/resources/application-dev.yml
  15. 11 0
      jeecg-module-system/jeecg-system-start/src/main/resources/application-prod.yml
  16. 11 0
      jeecg-module-system/jeecg-system-start/src/main/resources/application-test.yml

+ 33 - 27
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/common/constant/NumConstant.java

@@ -2,57 +2,63 @@ package org.jeecg.modules.adweb.common.constant;
 
 public class NumConstant {
 
-    public static final Integer MINUS_ONE = -1;
+  public static final Integer MINUS_ONE = -1;
 
-    public static final Integer ZERO = 0;
+  public static final Integer ZERO = 0;
 
-    public static final Integer ONE = 1;
+  public static final Integer ONE = 1;
 
-    public static final Integer TWO = 2;
+  public static final Integer TWO = 2;
 
-    public static final Integer THREE = 3;
+  public static final Integer THREE = 3;
 
-    public static final Integer FOUR = 4;
+  public static final Integer FOUR = 4;
 
-    public static final Integer FIVE = 5;
+  public static final Integer FIVE = 5;
 
-    public static final Integer SIX = 6;
+  public static final Integer SIX = 6;
 
-    public static final Integer SEVEN = 7;
+  public static final Integer SEVEN = 7;
 
-    public static final Integer EIGHT = 8;
+  public static final Integer EIGHT = 8;
 
-    public static final Integer NINE = 9;
+  public static final Integer NINE = 9;
 
-    public static final Integer TEN = 10;
+  public static final Integer TEN = 10;
 
-    public static final Integer ELEVEN = 11;
+  public static final Integer ELEVEN = 11;
 
-    public static final Integer TWELVE = 12;
+  public static final Integer TWELVE = 12;
 
-    public static final Integer THIRTEEN = 13;
+  public static final Integer THIRTEEN = 13;
 
-    public static final Integer FOURTEEN = 14;
+  public static final Integer FOURTEEN = 14;
 
-    public static final Integer FIFTEEN = 15;
+  public static final Integer FIFTEEN = 15;
 
-    public static final Integer EIGHTEEN = 18;
+  public static final Integer EIGHTEEN = 18;
 
-    public static final Integer TWENTY = 20;
+  public static final Integer TWENTY = 20;
 
-    public static final Integer THIRTY = 30;
+  public static final Integer THIRTY = 30;
 
-    public static final Integer FIFTY = 50;
+  public static final Integer FIFTY = 50;
 
-    public static final Integer EIGHTY = 80;
+  public static final Integer EIGHTY = 80;
 
-    public static final Integer ONE_HUNDRED = 100;
+  public static final Integer ONE_HUNDRED = 100;
 
-    public static final Integer SIXTY = 60;
+  public static final Integer SIXTY = 60;
 
-    public static final Integer ONE_HUNDRED_TWENTY = 120;
+  public static final Integer ONE_HUNDRED_TWENTY = 120;
 
-    public static final Integer ONE_THOUSAND = 1_000;
+  public static final Integer ONE_THOUSAND = 1_000;
 
-    public static final Integer ONE_MILLION = 1_000_000;
+  public static final Integer ONE_MILLION = 1_000_000;
+
+  public static final Integer ONEHUNDREDTWENTY = 120;
+
+  public static final Integer HUGE = 99999;
+
+  public static final Integer MILLION = 1000000;
 }

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

@@ -46,6 +46,7 @@ import org.jeecg.modules.adweb.enquiry.entity.AdwebEnquiry;
 import org.jeecg.modules.adweb.enquiry.entity.EnquiryEmailMessage;
 import org.jeecg.modules.adweb.enquiry.mapper.AdwebEnquiryMapper;
 import org.jeecg.modules.adweb.enquiry.service.IAdwebEnquiryService;
+import org.jeecg.modules.adweb.enquiry.service.IAdwebMatomoService;
 import org.jeecg.modules.adweb.enquiry.service.IEnquiryEmailMessageService;
 import org.jeecg.modules.adweb.site.entity.AdwebSite;
 import org.jeecg.modules.adweb.site.service.IAdwebSiteService;
@@ -93,6 +94,8 @@ public class AdwebEnquiryController extends JeecgController<AdwebEnquiry, IAdweb
 
   @Resource private IEnquiryEmailMessageService enquiryEmailMessageService;
 
+  @Resource private IAdwebMatomoService adwebMatomoService;
+
   /**
    * 分页列表查询
    *
@@ -809,6 +812,17 @@ public class AdwebEnquiryController extends JeecgController<AdwebEnquiry, IAdweb
     return Result.OK(wasterEnquiries);
   }
 
+  /**
+   * 根据询盘id获取询盘发送人的网站浏览记录
+   *
+   * @param id
+   * @return
+   */
+  @GetMapping("/getMatomoWebTrackFromEnquiryId")
+  public Result<?> getMatomoWebTrackFromEnquiryId(String id) {
+    return Result.OK(adwebMatomoService.getMatomoWebTrackFromEnquiryId(id));
+  }
+
   // 本地开发环境测试询盘同步,从远程站点拉取询盘到开发数据库
   @IgnoreAuth
   @GetMapping("local_test_enquiryNotify")

+ 25 - 0
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/dto/matomo/MatomoActionDetailEnquiryIpDto.java

@@ -0,0 +1,25 @@
+package org.jeecg.modules.adweb.enquiry.dto.matomo;
+
+import lombok.Data;
+
+/**
+ * 网页浏览行为
+ *
+ * @author cyan
+ */
+@Data
+public class MatomoActionDetailEnquiryIpDto {
+  private String type;
+
+  private String url;
+
+  private String pageTitle;
+
+  private String serverTimePretty;
+
+  private String generationTime;
+
+  private Integer timeSpent;
+
+  private String timeSpentPretty;
+}

+ 23 - 0
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/dto/matomo/MatomoBrowsingBehaviorDto.java

@@ -0,0 +1,23 @@
+package org.jeecg.modules.adweb.enquiry.dto.matomo;
+
+import java.util.ArrayList;
+import java.util.List;
+import lombok.Data;
+
+/**
+ * 询盘浏览行为
+ *
+ * @author cyan
+ */
+@Data
+public class MatomoBrowsingBehaviorDto {
+  private Long firstTime;
+
+  private Long lastTime;
+
+  private String firstVisit;
+
+  private String lastVisit;
+
+  private List<MatomoWebHistoryDto> list = new ArrayList<>();
+}

+ 39 - 0
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/dto/matomo/MatomoBrowsingEnquiryIdDto.java

@@ -0,0 +1,39 @@
+package org.jeecg.modules.adweb.enquiry.dto.matomo;
+
+import java.util.ArrayList;
+import java.util.List;
+import lombok.Data;
+
+/**
+ * 网页浏览行为
+ *
+ * @author cyan
+ */
+@Data
+public class MatomoBrowsingEnquiryIdDto {
+  private String visitIp;
+
+  private String visitorId;
+
+  private String referrerTypeName;
+
+  private String referrerType;
+
+  private String operatingSystemCode;
+
+  private String deviceType;
+
+  private String browserName;
+
+  private String continent;
+
+  private String country;
+
+  private String serverDatePrettyFirstAction;
+
+  private String serverTimePrettyFirstAction;
+
+  private String visitDurationPretty;
+
+  private List<MatomoActionDetailEnquiryIpDto> actionDetails = new ArrayList<>();
+}

+ 20 - 0
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/dto/matomo/MatomoWebHistoryDto.java

@@ -0,0 +1,20 @@
+package org.jeecg.modules.adweb.enquiry.dto.matomo;
+
+import lombok.Data;
+
+/**
+ * 网站浏览记录dto
+ *
+ * @author cyan
+ */
+@Data
+public class MatomoWebHistoryDto {
+  // 浏览网站网址
+  private String url;
+  // 浏览次数
+  private Integer count;
+
+  private String page;
+
+  private Integer second = 0;
+}

+ 62 - 0
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/entity/AdwebMatomo.java

@@ -0,0 +1,62 @@
+package org.jeecg.modules.adweb.enquiry.entity;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import io.swagger.v3.oas.annotations.media.Schema;
+import java.io.Serializable;
+import java.util.Date;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import lombok.experimental.Accessors;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.springframework.format.annotation.DateTimeFormat;
+
+/**
+ * @Description: matoto @Author: jeecg-boot @Date: 2022-02-22 @Version: V1.0
+ */
+@Data
+@TableName("adweb_matomo")
+@Accessors(chain = true)
+@EqualsAndHashCode(callSuper = false)
+@Schema(description = "matoto")
+public class AdwebMatomo implements Serializable {
+  private static final long serialVersionUID = 1L;
+
+  /** 主键 */
+  @TableId(type = IdType.AUTO)
+  @Schema(description = "主键")
+  private Integer id;
+
+  /** 创建日期 */
+  @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
+  @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+  @Schema(description = "创建日期")
+  private Date createTime;
+
+  /** 用户id */
+  @Excel(name = "用户id", width = 15)
+  @Schema(description = "用户id")
+  private String uid;
+
+  /** 系统站点id */
+  @Excel(name = "系统站点id", width = 15)
+  @Schema(description = "系统站点id")
+  private Integer siteId;
+
+  /** matomo站点id */
+  @Excel(name = "matomo站点id", width = 15)
+  @Schema(description = "matomo站点id")
+  private Integer mmSiteId;
+
+  /** matotoCode */
+  @Excel(name = "matotoCode", width = 15)
+  @Schema(description = "matotoCode")
+  private String mmCode;
+
+  /** 删除状态(0:删除;1:正常) */
+  @Excel(name = "删除状态(0:删除;1:正常)", width = 15)
+  @Schema(description = "删除状态(0:删除;1:正常)")
+  private Integer isDel;
+}

+ 9 - 0
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/mapper/AdwebMatomoMapper.java

@@ -0,0 +1,9 @@
+package org.jeecg.modules.adweb.enquiry.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.jeecg.modules.adweb.enquiry.entity.AdwebMatomo;
+
+/**
+ * @Description: matoto @Author: jeecg-boot @Date: 2022-02-22 @Version: V1.0
+ */
+public interface AdwebMatomoMapper extends BaseMapper<AdwebMatomo> {}

+ 29 - 0
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/service/IAdwebMatomoService.java

@@ -0,0 +1,29 @@
+package org.jeecg.modules.adweb.enquiry.service;
+
+import com.baomidou.mybatisplus.extension.service.IService;
+import java.util.List;
+import org.jeecg.modules.adweb.enquiry.dto.matomo.MatomoBrowsingEnquiryIdDto;
+import org.jeecg.modules.adweb.enquiry.entity.AdwebMatomo;
+
+/**
+ * @Description: matoto @Author: Cyan @Date: 2022-07-27 @Version: V1.0
+ */
+public interface IAdwebMatomoService extends IService<AdwebMatomo> {
+
+  /**
+   * 根据询盘Id获取网站浏览记录
+   *
+   * @param enquiryId
+   * @return
+   */
+  List<MatomoBrowsingEnquiryIdDto> getMatomoWebTrackFromEnquiryId(String enquiryId);
+
+  /**
+   * 根据网站id获取Matomo网站浏览记录
+   *
+   * @param siteId
+   * @return
+   * @throws
+   */
+  List<MatomoBrowsingEnquiryIdDto> getMatomoSiteTrackFromSiteId(String siteId);
+}

+ 151 - 0
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/adweb/enquiry/service/impl/AdwebMatomoServiceImpl.java

@@ -0,0 +1,151 @@
+package org.jeecg.modules.adweb.enquiry.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.commons.collections4.CollectionUtils;
+import org.apache.commons.lang3.StringUtils;
+import org.jeecg.common.constant.CommonConstant;
+import org.jeecg.common.exception.JeecgBootException;
+import org.jeecg.common.util.FastJsonUtil;
+import org.jeecg.modules.adweb.common.constant.NumConstant;
+import org.jeecg.modules.adweb.enquiry.dto.matomo.MatomoBrowsingEnquiryIdDto;
+import org.jeecg.modules.adweb.enquiry.entity.AdwebEnquiry;
+import org.jeecg.modules.adweb.enquiry.entity.AdwebMatomo;
+import org.jeecg.modules.adweb.enquiry.mapper.AdwebMatomoMapper;
+import org.jeecg.modules.adweb.enquiry.service.IAdwebEnquiryService;
+import org.jeecg.modules.adweb.enquiry.service.IAdwebMatomoService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.beans.factory.annotation.Value;
+import org.springframework.http.client.SimpleClientHttpRequestFactory;
+import org.springframework.stereotype.Service;
+import org.springframework.web.client.RestTemplate;
+
+/**
+ * @Description: matoto @Author: Cyan @Date: 2022-07-27 @Version: V1.0
+ */
+@Service
+public class AdwebMatomoServiceImpl extends ServiceImpl<AdwebMatomoMapper, AdwebMatomo>
+    implements IAdwebMatomoService {
+
+  @Value("${admp.matomo.token}")
+  private String matomoToken;
+
+  @Value("${admp.matomo.url}")
+  private String matomoUrl;
+
+  @Value("${admp.matomocn.token}")
+  private String matomoCnToken;
+
+  @Value("${admp.matomocn.url}")
+  private String matomoCnUrl;
+
+  @Autowired private IAdwebEnquiryService adwebEnquiryService;
+
+  /**
+   * 根据询盘Id获取网站访问记录
+   *
+   * @param enquiryId
+   * @return9yue
+   */
+  @Override
+  public List<MatomoBrowsingEnquiryIdDto> getMatomoWebTrackFromEnquiryId(String enquiryId) {
+    List<MatomoBrowsingEnquiryIdDto> matomoBrowsingEnquiryIpDtos = new ArrayList<>();
+    AdwebEnquiry adwebEnquiry = adwebEnquiryService.getById(enquiryId);
+    if (adwebEnquiry == null) {
+      throw new JeecgBootException("询盘不存在");
+    }
+
+    QueryWrapper<AdwebMatomo> admpMatomoQueryWrapper = new QueryWrapper<>();
+    admpMatomoQueryWrapper.eq("site_id", adwebEnquiry.getSiteId());
+    admpMatomoQueryWrapper.eq("is_del", CommonConstant.DEL_FLAG_1);
+    List<AdwebMatomo> admpMatomos = this.list(admpMatomoQueryWrapper);
+    if (CollectionUtils.isNotEmpty(admpMatomos)) {
+      RestTemplate restTemplate = getRestTemplate(NumConstant.ONEHUNDREDTWENTY);
+      try {
+        if (StringUtils.isNotBlank(adwebEnquiry.getVisitId())) {
+          String code = null;
+          String url =
+              matomoCnUrl
+                  + "/index.php?module=API&method=Live.getLastVisitsDetails&idSite="
+                  + admpMatomos.get(NumConstant.ZERO).getMmSiteId()
+                  + "&format=JSON&token_auth="
+                  + matomoCnToken
+                  + "&segment=visitorId=="
+                  + adwebEnquiry.getVisitId()
+                  + "&language=zh-cn";
+          log.warn("getMatomoWebTrackFromEnquiryId - url:{}" + url);
+          code = restTemplate.getForObject(url, String.class);
+          log.warn("code:" + code);
+          if (StringUtils.isNotBlank(code) && !"[]".equals(code)) {
+            //                            Map<String, Object> map = FastJsonUtil.parseObject(code,
+            // Map.class);
+            matomoBrowsingEnquiryIpDtos =
+                FastJsonUtil.parseList(code, MatomoBrowsingEnquiryIdDto.class);
+          }
+        }
+      } catch (Exception e) {
+        e.printStackTrace();
+        log.error("请求超时");
+        throw new JeecgBootException("请求超时,请重试!");
+      }
+    }
+
+    return matomoBrowsingEnquiryIpDtos;
+  }
+
+  /**
+   * 根据网站id获取Matomo网站浏览记录
+   *
+   * @param siteId
+   * @return
+   */
+  @Override
+  public List<MatomoBrowsingEnquiryIdDto> getMatomoSiteTrackFromSiteId(String siteId) {
+    List<MatomoBrowsingEnquiryIdDto> matomoBrowsingEnquiryIpDtos = new ArrayList<>();
+    QueryWrapper<AdwebMatomo> admpMatomoQueryWrapper = new QueryWrapper<>();
+    admpMatomoQueryWrapper.eq("site_id", siteId);
+    admpMatomoQueryWrapper.eq("is_del", CommonConstant.DEL_FLAG_1);
+    List<AdwebMatomo> admpMatomos = this.list(admpMatomoQueryWrapper);
+    if (CollectionUtils.isNotEmpty(admpMatomos)) {
+      // 获取自定义restTemplate
+      RestTemplate restTemplate = getRestTemplate(NumConstant.ONEHUNDREDTWENTY);
+      try {
+        String code = null;
+        String url =
+            matomoCnUrl
+                + "/index.php?module=API&method=Live.getLastVisitsDetails&idSite="
+                + admpMatomos.get(NumConstant.ZERO).getMmSiteId()
+                + "&format=JSON&token_auth="
+                + matomoCnToken
+                + "&language=zh-cn&period=day&date=today";
+        log.warn("getMatomoSiteTrackFromSiteId url:{}" + url);
+        code = restTemplate.getForObject(url, String.class);
+        log.warn("code:" + code);
+        if (StringUtils.isNotBlank(code) && !"[]".equals(code)) {
+          matomoBrowsingEnquiryIpDtos =
+              FastJsonUtil.parseList(code, MatomoBrowsingEnquiryIdDto.class);
+        }
+      } catch (Exception e) {
+        e.printStackTrace();
+        log.error("请求超时");
+        throw new JeecgBootException("请求超时,请重试!");
+      }
+    }
+    return matomoBrowsingEnquiryIpDtos;
+  }
+
+  /**
+   * 创建restTemplate对象
+   *
+   * @param second
+   * @return
+   */
+  private RestTemplate getRestTemplate(Integer second) {
+    SimpleClientHttpRequestFactory factory = new SimpleClientHttpRequestFactory();
+    factory.setConnectTimeout(second * 1000);
+    factory.setReadTimeout(second * 1000);
+    return new RestTemplate(factory);
+  }
+}

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

@@ -6,7 +6,6 @@ import cn.hutool.http.HttpRequest;
 import cn.hutool.http.HttpResponse;
 import com.alibaba.fastjson.JSONObject;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
-import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import java.io.ByteArrayOutputStream;
 import java.io.IOException;
@@ -46,10 +45,9 @@ public class AdwebProductServiceImpl extends ServiceImpl<AdwebProductMapper, Adw
   @Override
   public void addOrUpdateProduct(ProductDTO productDTO, AdwebSite adwebSites) {
     // 产品同步时,update 有可能是新增或者更新,根据数据库中记录进行再次判断
-    if ("update".equals(productDTO.getActionType())) {
+    if ("update".equals(productDTO.getActionType())
+        || "delete".equals(productDTO.getActionType())) {
       handleUpdate(productDTO, adwebSites);
-    } else if ("delete".equals(productDTO.getActionType())) {
-      handleDelete(productDTO, adwebSites);
     } else {
       handleAdd(productDTO, adwebSites);
     }
@@ -76,26 +74,6 @@ public class AdwebProductServiceImpl extends ServiceImpl<AdwebProductMapper, Adw
     }
   }
 
-  private void handleDelete(ProductDTO productDTO, AdwebSite adwebSites) {
-    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);
-      log.info(
-          "MQ消息删除产品成功, 网站:{}, 产品ID:{}, 是否更新成功:{}",
-          adwebSites.getCode(),
-          productDTO.getProductId(),
-          isUpdated);
-    } catch (Exception e) {
-      log.error("MQ消息删除产品失败:{}", e.getMessage(), e);
-    }
-  }
-
   private void handleAdd(ProductDTO productDTO, AdwebSite adwebSites) {
     AdwebProduct product = new AdwebProduct();
     BeanUtil.copyProperties(productDTO, product);

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

@@ -6,17 +6,16 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 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;
 import io.swagger.v3.oas.annotations.Operation;
 import io.swagger.v3.oas.annotations.tags.Tag;
-
 import jakarta.annotation.Resource;
 import jakarta.servlet.http.HttpServletRequest;
 import jakarta.servlet.http.HttpServletResponse;
-
+import java.util.Arrays;
+import java.util.List;
+import java.util.Map;
 import lombok.extern.slf4j.Slf4j;
-
 import org.apache.commons.collections4.CollectionUtils;
 import org.apache.commons.lang.StringUtils;
 import org.apache.shiro.SecurityUtils;
@@ -41,15 +40,8 @@ import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.web.bind.annotation.*;
 import org.springframework.web.servlet.ModelAndView;
 
-import java.util.Arrays;
-import java.util.List;
-import java.util.Map;
-
 /**
- * @Description: adweb站点配置表单
- * @Author: jeecg-boot
- * @Date: 2024-09-29
- * @Version: V1.0
+ * @Description: adweb站点配置表单 @Author: jeecg-boot @Date: 2024-09-29 @Version: V1.0
  */
 @Tag(name = "adweb站点配置表单")
 @RestController
@@ -57,278 +49,276 @@ import java.util.Map;
 @Slf4j
 public class AdwebSiteController extends JeecgController<AdwebSite, IAdwebSiteService> {
 
-    @Resource private IAdwebSiteService adwebSiteService;
-
-    @Resource private SysAdwebApi sysAdwebApi;
-
-    @Resource private ISiteUserPermissionService siteUserPermissionService;
-
-    @Resource private ISitePermissionService sitePermissionService;
-
-    @Resource private UserPlanSubscriptionMapper userPlanSubscriptionMapper;
-
-    @Resource private SelfWebSiteService selfWebSiteService;
-
-    @Resource private BaseCommonService baseCommonService;
-
-    @Resource private Sohoeb2bOrderService sohoeb2bOrderService;
-
-    /**
-     * 分页列表查询
-     *
-     * @param adwebSite
-     * @param pageNo
-     * @param pageSize
-     * @param req
-     * @return
-     */
-    // @AutoLog(value = "adweb站点配置表单-分页列表查询")
-    @Operation(summary = "adweb站点配置表单-分页列表查询")
-    @GetMapping(value = "/list")
-    public Result<IPage<AdwebSite>> queryPageList(
-            AdwebSite adwebSite,
-            @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
-            @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
-            HttpServletRequest req) {
-        QueryWrapper<AdwebSite> queryWrapper =
-                QueryGenerator.initQueryWrapper(adwebSite, req.getParameterMap());
-
-        Page<AdwebSite> page = new Page<AdwebSite>(pageNo, pageSize);
-
-        // 处理多租户过滤站点列表
-        processTenantFilter(queryWrapper.lambda());
-
-        IPage<AdwebSite> pageList = adwebSiteService.page(page, queryWrapper);
-
-        // 给站点增加营销计划信息
-        List<AdwebSite> siteList = pageList.getRecords();
-        for (AdwebSite site : siteList) {
-            Map<String, String> subscribePlan =
-                    userPlanSubscriptionMapper.getSubscribePlanBySiteId(site.getId());
-            JSONObject object =
-                    FastJsonUtil.parseObject(
-                            FastJsonUtil.toJSONString(subscribePlan), JSONObject.class);
-            site.setSubscribePlan(object);
-
-            // 设置建站进度
-            if (site.getSiteFlowStatus() == null) {
-                site.setCompleteProcess(0);
-            } else {
-                site.setCompleteProcess(site.getSiteFlowStatus() * 100 / 6);
-            }
-
-            // 处理域名,全部改为绝对路径
-            String domain = site.getDomain();
-            if (StringUtils.isNotBlank(domain) && !domain.startsWith("http")) {
-                site.setDomain("https://" + domain);
-            }
-
-            // TODO权限验证
-            Sohoeb2bOrder sohoeb2bOrder = sohoeb2bOrderService.getBySiteCode(adwebSite.getCode());
-            if (sohoeb2bOrder != null) {
-                adwebSite.setOrderUrl(sohoeb2bOrder.getOrderUrl());
-                adwebSite.setOrderUrlID(String.valueOf(sohoeb2bOrder.getId()));
-            }
-        }
-
-        return Result.OK(pageList);
-    }
-
-    /**
-     * 添加
-     *
-     * @param adwebSite
-     * @return
-     */
-    @AutoLog(value = "adweb站点配置表单-添加")
-    @Operation(summary = "adweb站点配置表单-添加")
-    @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:add')")
-    @PostMapping(value = "/add")
-    public Result<String> add(@RequestBody AdwebSite adwebSite) {
-        adwebSiteService.save(adwebSite);
-        return Result.OK("添加成功!");
+  @Resource private IAdwebSiteService adwebSiteService;
+
+  @Resource private SysAdwebApi sysAdwebApi;
+
+  @Resource private ISiteUserPermissionService siteUserPermissionService;
+
+  @Resource private ISitePermissionService sitePermissionService;
+
+  @Resource private UserPlanSubscriptionMapper userPlanSubscriptionMapper;
+
+  @Resource private SelfWebSiteService selfWebSiteService;
+
+  @Resource private BaseCommonService baseCommonService;
+
+  @Resource private Sohoeb2bOrderService sohoeb2bOrderService;
+
+  /**
+   * 分页列表查询
+   *
+   * @param adwebSite
+   * @param pageNo
+   * @param pageSize
+   * @param req
+   * @return
+   */
+  // @AutoLog(value = "adweb站点配置表单-分页列表查询")
+  @Operation(summary = "adweb站点配置表单-分页列表查询")
+  @GetMapping(value = "/list")
+  public Result<IPage<AdwebSite>> queryPageList(
+      AdwebSite adwebSite,
+      @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
+      @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
+      HttpServletRequest req) {
+    QueryWrapper<AdwebSite> queryWrapper =
+        QueryGenerator.initQueryWrapper(adwebSite, req.getParameterMap());
+
+    Page<AdwebSite> page = new Page<AdwebSite>(pageNo, pageSize);
+
+    // 处理多租户过滤站点列表
+    processTenantFilter(queryWrapper.lambda());
+
+    IPage<AdwebSite> pageList = adwebSiteService.page(page, queryWrapper);
+
+    // 给站点增加营销计划信息
+    List<AdwebSite> siteList = pageList.getRecords();
+    for (AdwebSite site : siteList) {
+      Map<String, String> subscribePlan =
+          userPlanSubscriptionMapper.getSubscribePlanBySiteId(site.getId());
+      JSONObject object =
+          FastJsonUtil.parseObject(FastJsonUtil.toJSONString(subscribePlan), JSONObject.class);
+      site.setSubscribePlan(object);
+
+      // 设置建站进度
+      if (site.getSiteFlowStatus() == null) {
+        site.setCompleteProcess(0);
+      } else {
+        site.setCompleteProcess(site.getSiteFlowStatus() * 100 / 6);
+      }
+
+      // 处理域名,全部改为绝对路径
+      String domain = site.getDomain();
+      if (StringUtils.isNotBlank(domain) && !domain.startsWith("http")) {
+        site.setDomain("https://" + domain);
+      }
+
+      // TODO权限验证
+      Sohoeb2bOrder sohoeb2bOrder = sohoeb2bOrderService.getBySiteCode(adwebSite.getCode());
+      if (sohoeb2bOrder != null) {
+        adwebSite.setOrderUrl(sohoeb2bOrder.getOrderUrl());
+        adwebSite.setOrderUrlID(String.valueOf(sohoeb2bOrder.getId()));
+      }
     }
 
-    /**
-     * 编辑
-     *
-     * @param adwebSite
-     * @return
-     */
-    @AutoLog(value = "adweb站点配置表单-编辑")
-    @Operation(summary = "adweb站点配置表单-编辑")
-    @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:edit')")
-    @RequestMapping(
-            value = "/edit",
-            method = {RequestMethod.PUT, RequestMethod.POST})
-    public Result<String> edit(@RequestBody AdwebSite adwebSite) {
-        adwebSiteService.updateById(adwebSite);
-        return Result.OK("编辑成功!");
+    return Result.OK(pageList);
+  }
+
+  /**
+   * 添加
+   *
+   * @param adwebSite
+   * @return
+   */
+  @AutoLog(value = "adweb站点配置表单-添加")
+  @Operation(summary = "adweb站点配置表单-添加")
+  @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:add')")
+  @PostMapping(value = "/add")
+  public Result<String> add(@RequestBody AdwebSite adwebSite) {
+    adwebSiteService.save(adwebSite);
+    return Result.OK("添加成功!");
+  }
+
+  /**
+   * 编辑
+   *
+   * @param adwebSite
+   * @return
+   */
+  @AutoLog(value = "adweb站点配置表单-编辑")
+  @Operation(summary = "adweb站点配置表单-编辑")
+  @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:edit')")
+  @RequestMapping(
+      value = "/edit",
+      method = {RequestMethod.PUT, RequestMethod.POST})
+  public Result<String> edit(@RequestBody AdwebSite adwebSite) {
+    adwebSiteService.updateById(adwebSite);
+    return Result.OK("编辑成功!");
+  }
+
+  /**
+   * 通过id删除
+   *
+   * @param id
+   * @return
+   */
+  @AutoLog(value = "adweb站点配置表单-通过id删除")
+  @Operation(summary = "adweb站点配置表单-通过id删除")
+  @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:delete')")
+  @DeleteMapping(value = "/delete")
+  public Result<String> delete(@RequestParam(name = "id", required = true) String id) {
+    AdwebSite adwebSite = adwebSiteService.getById(id);
+
+    // 删除站点权限
+    LambdaQueryWrapper<AdwebSitePermission> queryWrapper =
+        new LambdaQueryWrapper<AdwebSitePermission>();
+    queryWrapper.eq(AdwebSitePermission::getSiteCode, adwebSite.getCode());
+    sitePermissionService.remove(queryWrapper);
+
+    // 远程删除并备份站点资源
+    LoginUser user = SecureUtil.currentUser();
+    selfWebSiteService.removeSite(user, adwebSite);
+
+    // 删除该站点数据
+    adwebSiteService.removeById(id);
+
+    // 记录删除站点操作日志
+    baseCommonService.addLog(
+        "站点" + adwebSite.getDomain() + "资源已被删除,将在服务器自动备份15天,之后将自动清空:",
+        CommonConstant.LOG_TYPE_2,
+        3);
+
+    return Result.ok("该站点资源已经不存在, 站点信息将从系统中删除!");
+  }
+
+  /**
+   * 批量删除
+   *
+   * @param ids
+   * @return
+   */
+  @AutoLog(value = "adweb站点配置表单-批量删除")
+  @Operation(summary = "adweb站点配置表单-批量删除")
+  @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:deleteBatch')")
+  @DeleteMapping(value = "/deleteBatch")
+  public Result<String> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
+    this.adwebSiteService.removeByIds(Arrays.asList(ids.split(",")));
+    return Result.OK("批量删除成功!");
+  }
+
+  /**
+   * 通过id查询
+   *
+   * @param id
+   * @return
+   */
+  // @AutoLog(value = "adweb站点配置表单-通过id查询")
+  @Operation(summary = "adweb站点配置表单-通过id查询")
+  @GetMapping(value = "/queryById")
+  public Result<AdwebSite> queryById(@RequestParam(name = "id", required = true) String id) {
+    AdwebSite adwebSite = adwebSiteService.getById(id);
+    if (adwebSite == null) {
+      return Result.error("未找到对应数据");
     }
-
-    /**
-     * 通过id删除
-     *
-     * @param id
-     * @return
-     */
-    @AutoLog(value = "adweb站点配置表单-通过id删除")
-    @Operation(summary = "adweb站点配置表单-通过id删除")
-    @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:delete')")
-    @DeleteMapping(value = "/delete")
-    public Result<String> delete(@RequestParam(name = "id", required = true) String id) {
-        AdwebSite adwebSite = adwebSiteService.getById(id);
-
-        // 删除站点权限
-        LambdaQueryWrapper<AdwebSitePermission> queryWrapper =
-                new LambdaQueryWrapper<AdwebSitePermission>();
-        queryWrapper.eq(AdwebSitePermission::getSiteCode, adwebSite.getCode());
-        sitePermissionService.remove(queryWrapper);
-
-        // 远程删除并备份站点资源
-        LoginUser user = SecureUtil.currentUser();
-        selfWebSiteService.removeSite(user, adwebSite);
-
-        // 删除该站点数据
-        adwebSiteService.removeById(id);
-
-        // 记录删除站点操作日志
-        baseCommonService.addLog(
-                "站点" + adwebSite.getDomain() + "资源已被删除,将在服务器自动备份15天,之后将自动清空:",
-                CommonConstant.LOG_TYPE_2,
-                3);
-
-        return Result.ok("该站点资源已经不存在, 站点信息将从系统中删除!");
-    }
-
-    /**
-     * 批量删除
-     *
-     * @param ids
-     * @return
-     */
-    @AutoLog(value = "adweb站点配置表单-批量删除")
-    @Operation(summary = "adweb站点配置表单-批量删除")
-    @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:deleteBatch')")
-    @DeleteMapping(value = "/deleteBatch")
-    public Result<String> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
-        this.adwebSiteService.removeByIds(Arrays.asList(ids.split(",")));
-        return Result.OK("批量删除成功!");
-    }
-
-    /**
-     * 通过id查询
-     *
-     * @param id
-     * @return
-     */
-    // @AutoLog(value = "adweb站点配置表单-通过id查询")
-    @Operation(summary = "adweb站点配置表单-通过id查询")
-    @GetMapping(value = "/queryById")
-    public Result<AdwebSite> queryById(@RequestParam(name = "id", required = true) String id) {
-        AdwebSite adwebSite = adwebSiteService.getById(id);
-        if (adwebSite == null) {
-            return Result.error("未找到对应数据");
+    return Result.OK(adwebSite);
+  }
+
+  /**
+   * 导出excel
+   *
+   * @param request
+   * @param adwebSite
+   */
+  @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:exportXls')")
+  @RequestMapping(value = "/exportXls")
+  public ModelAndView exportXls(HttpServletRequest request, AdwebSite adwebSite) {
+    return super.exportXls(request, adwebSite, AdwebSite.class, "adweb站点配置表单");
+  }
+
+  /**
+   * 通过excel导入数据
+   *
+   * @param request
+   * @param response
+   * @return
+   */
+  @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:importExcel')")
+  @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
+  public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
+    return super.importExcel(request, response, AdwebSite.class);
+  }
+
+  /** 根据uid获取所属一级站点信息 "id", "name", "code", "domain","domain_dev","status" */
+  @GetMapping("/getSiteListByUid")
+  public Result<?> getAllSites() {
+    LambdaQueryWrapper<AdwebSite> queryWrapper = new LambdaQueryWrapper<>();
+    // 处理多租户过滤站点列表
+    processTenantFilter(queryWrapper);
+
+    queryWrapper
+        .ne(AdwebSite::getStatus, AdwebConstant.SITE_DEL)
+        .isNull(AdwebSite::getParentGroupCode)
+        .orderByDesc(AdwebSite::getUtime);
+    queryWrapper.select(
+        AdwebSite::getId,
+        AdwebSite::getName,
+        AdwebSite::getCode,
+        AdwebSite::getDomain,
+        AdwebSite::getDomainDev,
+        AdwebSite::getStatus,
+        AdwebSite::getIsDemo);
+    List<AdwebSite> siteList = adwebSiteService.list(queryWrapper);
+
+    // 处理域名,全部改为绝对路径
+    if (CollectionUtils.isNotEmpty(siteList)) {
+      for (AdwebSite site : siteList) {
+        String domain = site.getDomain();
+        if (StringUtil.isNullOrEmpty(domain)) {
+          continue;
         }
-        return Result.OK(adwebSite);
-    }
-
-    /**
-     * 导出excel
-     *
-     * @param request
-     * @param adwebSite
-     */
-    @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:exportXls')")
-    @RequestMapping(value = "/exportXls")
-    public ModelAndView exportXls(HttpServletRequest request, AdwebSite adwebSite) {
-        return super.exportXls(request, adwebSite, AdwebSite.class, "adweb站点配置表单");
-    }
-
-    /**
-     * 通过excel导入数据
-     *
-     * @param request
-     * @param response
-     * @return
-     */
-    @PreAuthorize("@jps.requiresPermissions('adweb:adweb_site:importExcel')")
-    @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
-    public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
-        return super.importExcel(request, response, AdwebSite.class);
-    }
-
-    /** 根据uid获取所属一级站点信息 "id", "name", "code", "domain","domain_dev","status" */
-    @GetMapping("/getSiteListByUid")
-    public Result<?> getAllSites() {
-        LambdaQueryWrapper<AdwebSite> queryWrapper = new LambdaQueryWrapper<>();
-        // 处理多租户过滤站点列表
-        processTenantFilter(queryWrapper);
-
-        queryWrapper
-                .ne(AdwebSite::getStatus, AdwebConstant.SITE_DEL)
-                .isNull(AdwebSite::getParentGroupCode);
-        queryWrapper.select(
-                AdwebSite::getId,
-                AdwebSite::getName,
-                AdwebSite::getCode,
-                AdwebSite::getDomain,
-                AdwebSite::getDomainDev,
-                AdwebSite::getStatus,
-                AdwebSite::getIsDemo
-        );
-        List<AdwebSite> siteList = adwebSiteService.list(queryWrapper);
-
-        // 处理域名,全部改为绝对路径
-        if (CollectionUtils.isNotEmpty(siteList)) {
-            for (AdwebSite site : siteList) {
-                String domain = site.getDomain();
-                if (StringUtil.isNullOrEmpty(domain)) {
-                    continue;
-                }
-                if (!domain.startsWith("http")) {
-                    site.setDomain("https://" + domain);
-                }
-            }
+        if (!domain.startsWith("http")) {
+          site.setDomain("https://" + domain);
         }
-
-        return Result.ok(siteList);
+      }
     }
 
-    /**
-     * 更新site表现阶段
-     *
-     * @param siteStepDTO @Author: 陈培庆 @Date: 2024/11/26
-     */
-    @RequestMapping(value = "/finishOrRollbackStep")
-    public Result<?> finishOrRollbackStep(SiteStepDTO siteStepDTO) {
-
-        // 更新流程步骤和状态
-        LambdaUpdateWrapper<AdwebSite> siteUpdateWrapper = new LambdaUpdateWrapper<>();
-        siteUpdateWrapper.eq(AdwebSite::getCode, siteStepDTO.getSiteCode());
-
-        // 建站流程
-        siteUpdateWrapper
-                .set(AdwebSite::getSiteCurrentStep, siteStepDTO.getCurrentStep())
-                .set(AdwebSite::getSiteFlowStatus, siteStepDTO.getStepFlowId());
-
-        adwebSiteService.update(siteUpdateWrapper);
-        return Result.OK();
-    }
-
-    private void processTenantFilter(LambdaQueryWrapper<AdwebSite> queryWrapper) {
-        LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
-        // 对于非管理员进行租户隔离
-        if (sysAdwebApi.isAdmin()) {
-
-        } else if (sysAdwebApi.isChannelAdmin()) {
-            List<String> channelGroupUids = sysAdwebApi.getChannelGroupUids();
-            List<String> codeList =
-                    siteUserPermissionService.getSiteCodeListByUids(channelGroupUids);
-            queryWrapper.in(AdwebSite::getCode, codeList);
-        } else {
-            List<String> codeList = siteUserPermissionService.getSiteCodeList(sysUser.getId());
-            queryWrapper.in(AdwebSite::getCode, codeList);
-        }
+    return Result.ok(siteList);
+  }
+
+  /**
+   * 更新site表现阶段
+   *
+   * @param siteStepDTO @Author: 陈培庆 @Date: 2024/11/26
+   */
+  @RequestMapping(value = "/finishOrRollbackStep")
+  public Result<?> finishOrRollbackStep(SiteStepDTO siteStepDTO) {
+
+    // 更新流程步骤和状态
+    LambdaUpdateWrapper<AdwebSite> siteUpdateWrapper = new LambdaUpdateWrapper<>();
+    siteUpdateWrapper.eq(AdwebSite::getCode, siteStepDTO.getSiteCode());
+
+    // 建站流程
+    siteUpdateWrapper
+        .set(AdwebSite::getSiteCurrentStep, siteStepDTO.getCurrentStep())
+        .set(AdwebSite::getSiteFlowStatus, siteStepDTO.getStepFlowId());
+
+    adwebSiteService.update(siteUpdateWrapper);
+    return Result.OK();
+  }
+
+  private void processTenantFilter(LambdaQueryWrapper<AdwebSite> queryWrapper) {
+    LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
+    // 对于非管理员进行租户隔离
+    if (sysAdwebApi.isAdmin()) {
+
+    } else if (sysAdwebApi.isChannelAdmin()) {
+      List<String> channelGroupUids = sysAdwebApi.getChannelGroupUids();
+      List<String> codeList = siteUserPermissionService.getSiteCodeListByUids(channelGroupUids);
+      queryWrapper.in(AdwebSite::getCode, codeList);
+    } else {
+      List<String> codeList = siteUserPermissionService.getSiteCodeList(sysUser.getId());
+      queryWrapper.in(AdwebSite::getCode, codeList);
     }
+  }
 }

+ 5 - 2
jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/mq/ProductReceiver.java

@@ -11,7 +11,6 @@ import org.jeecg.modules.adweb.product.dto.ProductDTO;
 import org.jeecg.modules.adweb.product.service.IAdwebProductService;
 import org.jeecg.modules.adweb.site.entity.AdwebSite;
 import org.jeecg.modules.adweb.site.service.IAdwebSiteService;
-import org.jeecg.modules.adweb.site.service.Sohoeb2bOrderService;
 import org.springframework.amqp.rabbit.annotation.RabbitHandler;
 import org.springframework.amqp.rabbit.annotation.RabbitListener;
 import org.springframework.amqp.support.AmqpHeaders;
@@ -62,7 +61,11 @@ public class ProductReceiver extends BaseRabbiMqHandler<List<ProductDTO>> {
               }
 
               // 产品入库
-              adwebProductService.addOrUpdateProduct(product, adwebSites.get(0));
+              try {
+                adwebProductService.addOrUpdateProduct(product, adwebSites.get(0));
+              } catch (Exception e) {
+                log.error("产品入库失败:{}", e.getMessage());
+              }
             }
           }
         });

+ 13 - 0
jeecg-module-system/jeecg-system-start/src/main/resources/application-dev.yml

@@ -450,6 +450,19 @@ AdwebSiteConnect:
   password: adweb123@2024
   tempDomain: v3.sohoeb2b.com
 
+
+admp:
+  matomo:
+    #    url: https://analytics.whalecloudexport.com/
+    #    token: 72acc8c8185f535d3e17e861264487a3
+    url: https://matomous.adwebcloud.com/
+    token: e471b2b1caf82f5a72d6b1faab1f7fa1
+  #访客数据配置-国内
+  matomocn:
+    url: https://matomocn.adwebcloud.com/
+    token: 7906fd17454705501f9684a6acad9800
+
+
 ### WP临时服务器
 serverIp:
   test: 54.184.224.4

+ 11 - 0
jeecg-module-system/jeecg-system-start/src/main/resources/application-prod.yml

@@ -458,6 +458,17 @@ AdwebSiteConnect:
   password: adweb123@2024
   tempDomain: v3.sohoeb2b.com
 
+admp:
+  matomo:
+    #    url: https://analytics.whalecloudexport.com/
+    #    token: 72acc8c8185f535d3e17e861264487a3
+    url: https://matomous.adwebcloud.com/
+    token: e471b2b1caf82f5a72d6b1faab1f7fa1
+  #访客数据配置-国内
+  matomocn:
+    url: https://matomocn.adwebcloud.com/
+    token: 7906fd17454705501f9684a6acad9800
+
 ### WP临时服务器
 serverIp:
   test: 54.184.224.4

+ 11 - 0
jeecg-module-system/jeecg-system-start/src/main/resources/application-test.yml

@@ -451,6 +451,17 @@ AdwebSiteConnect:
   password: adweb123@2024
   tempDomain: v3.sohoeb2b.com
 
+admp:
+  matomo:
+    #    url: https://analytics.whalecloudexport.com/
+    #    token: 72acc8c8185f535d3e17e861264487a3
+    url: https://matomous.adwebcloud.com/
+    token: e471b2b1caf82f5a72d6b1faab1f7fa1
+  #访客数据配置-国内
+  matomocn:
+    url: https://matomocn.adwebcloud.com/
+    token: 7906fd17454705501f9684a6acad9800
+
 ### WP临时服务器
 serverIp:
   test: 54.184.224.4