Przeglądaj źródła

配置类跟配置详情

yangyb 1 miesiąc temu
rodzic
commit
13cbd0f8a1
24 zmienionych plików z 761 dodań i 450 usunięć
  1. 3 161
      mall-api/src/main/java/com/txz/mall/dto/StoreProductAttrResultDTO.java
  2. 12 9
      mall-api/src/main/java/com/txz/mall/dto/StoreProductDTO.java
  3. 4 139
      mall-api/src/main/java/com/txz/mall/dto/StoreProductRuleDTO.java
  4. 58 0
      mall-api/src/main/java/com/txz/mall/dto/SystemGroupDTO.java
  5. 62 0
      mall-api/src/main/java/com/txz/mall/dto/SystemGroupDataDTO.java
  6. 3 138
      mall-api/src/main/java/com/txz/mall/dto/UserSignDTO.java
  7. 27 0
      mall-interface/src/main/java/com/txz/mall/service/SystemGroupDataServiceClient.java
  8. 27 0
      mall-interface/src/main/java/com/txz/mall/service/SystemGroupServiceClient.java
  9. 1 1
      mall-service/src/main/java/com/txz/mall/controller/StoreProductRuleController.java
  10. 137 0
      mall-service/src/main/java/com/txz/mall/controller/SystemGroupController.java
  11. 137 0
      mall-service/src/main/java/com/txz/mall/controller/SystemGroupDataController.java
  12. 7 0
      mall-service/src/main/java/com/txz/mall/dao/SystemGroupDataMapper.java
  13. 7 0
      mall-service/src/main/java/com/txz/mall/dao/SystemGroupMapper.java
  14. 65 0
      mall-service/src/main/java/com/txz/mall/model/SystemGroup.java
  15. 68 0
      mall-service/src/main/java/com/txz/mall/model/SystemGroupData.java
  16. 6 0
      mall-service/src/main/java/com/txz/mall/service/StoreProductRuleService.java
  17. 12 0
      mall-service/src/main/java/com/txz/mall/service/SystemGroupDataService.java
  18. 12 0
      mall-service/src/main/java/com/txz/mall/service/SystemGroupService.java
  19. 1 1
      mall-service/src/main/java/com/txz/mall/service/impl/StoreProductAttrResultServiceImpl.java
  20. 31 1
      mall-service/src/main/java/com/txz/mall/service/impl/StoreProductRuleServiceImpl.java
  21. 22 0
      mall-service/src/main/java/com/txz/mall/service/impl/SystemGroupDataServiceImpl.java
  22. 22 0
      mall-service/src/main/java/com/txz/mall/service/impl/SystemGroupServiceImpl.java
  23. 19 0
      mall-service/src/main/resources/mapper/SystemGroupDataMapper.xml
  24. 18 0
      mall-service/src/main/resources/mapper/SystemGroupMapper.xml

+ 3 - 161
mall-api/src/main/java/com/txz/mall/dto/StoreProductAttrResultDTO.java

@@ -6,9 +6,12 @@
  */
 package com.txz.mall.dto;
 
+import lombok.Data;
+
 import java.io.Serializable;
 import java.util.Date;
 
+@Data
 public class StoreProductAttrResultDTO implements Serializable {
     /**
      * m_store_product_attr_result
@@ -51,165 +54,4 @@ public class StoreProductAttrResultDTO implements Serializable {
      */
     private String result;
 
-    /**
-     * 主键
-     *
-     * @return id 主键
-     */
-    public Long getId() {
-        return id;
-    }
-
-    /**
-     * 主键
-     *
-     * @param id 主键
-     */
-    public void setId(Long id) {
-        this.id = id;
-    }
-
-    /**
-     * 商品ID
-     *
-     * @return product_id 商品ID
-     */
-    public Long getProductId() {
-        return productId;
-    }
-
-    /**
-     * 商品ID
-     *
-     * @param productId 商品ID
-     */
-    public void setProductId(Long productId) {
-        this.productId = productId;
-    }
-
-    /**
-     * 活动类型 0=商品,1=秒杀,2=砍价,3=拼团
-     *
-     * @return type 活动类型 0=商品,1=秒杀,2=砍价,3=拼团
-     */
-    public Boolean getType() {
-        return type;
-    }
-
-    /**
-     * 活动类型 0=商品,1=秒杀,2=砍价,3=拼团
-     *
-     * @param type 活动类型 0=商品,1=秒杀,2=砍价,3=拼团
-     */
-    public void setType(Boolean type) {
-        this.type = type;
-    }
-
-    /**
-     * 创建时间
-     *
-     * @return create_time 创建时间
-     */
-    public Date getCreateTime() {
-        return createTime;
-    }
-
-    /**
-     * 创建时间
-     *
-     * @param createTime 创建时间
-     */
-    public void setCreateTime(Date createTime) {
-        this.createTime = createTime;
-    }
-
-    /**
-     * 更新时间
-     *
-     * @return update_time 更新时间
-     */
-    public Date getUpdateTime() {
-        return updateTime;
-    }
-
-    /**
-     * 更新时间
-     *
-     * @param updateTime 更新时间
-     */
-    public void setUpdateTime(Date updateTime) {
-        this.updateTime = updateTime;
-    }
-
-    /**
-     * 创建人id
-     *
-     * @return create_user_id 创建人id
-     */
-    public Long getCreateUserId() {
-        return createUserId;
-    }
-
-    /**
-     * 创建人id
-     *
-     * @param createUserId 创建人id
-     */
-    public void setCreateUserId(Long createUserId) {
-        this.createUserId = createUserId;
-    }
-
-    /**
-     * 更新人id
-     *
-     * @return update_user_id 更新人id
-     */
-    public Long getUpdateUserId() {
-        return updateUserId;
-    }
-
-    /**
-     * 更新人id
-     *
-     * @param updateUserId 更新人id
-     */
-    public void setUpdateUserId(Long updateUserId) {
-        this.updateUserId = updateUserId;
-    }
-
-    /**
-     * 是否删除
-     *
-     * @return is_delete 是否删除
-     */
-    public Byte getIsDelete() {
-        return isDelete;
-    }
-
-    /**
-     * 是否删除
-     *
-     * @param isDelete 是否删除
-     */
-    public void setIsDelete(Byte isDelete) {
-        this.isDelete = isDelete;
-    }
-
-    /**
-     * 商品属性参数
-     *
-     * @return result 商品属性参数
-     */
-    public String getResult() {
-        return result;
-    }
-
-    /**
-     * 商品属性参数
-     *
-     * @param result 商品属性参数
-     */
-    public void setResult(String result) {
-        this.result = result;
-    }
 }

+ 12 - 9
mall-api/src/main/java/com/txz/mall/dto/StoreProductDTO.java

@@ -6,10 +6,13 @@
  */
 package com.txz.mall.dto;
 
+import lombok.Data;
+
 import java.io.Serializable;
 import java.math.BigDecimal;
 import java.util.Date;
 
+@Data
 public class StoreProductDTO implements Serializable {
     /**
      * 商品id
@@ -86,27 +89,27 @@ public class StoreProductDTO implements Serializable {
     /**
      * 状态(0:未上架,1:上架)
      */
-    private Boolean isShow;
+    private Integer isShow;
 
     /**
      * 是否热卖
      */
-    private Boolean isHot;
+    private Integer isHot;
 
     /**
      * 是否优惠
      */
-    private Boolean isBenefit;
+    private Integer isBenefit;
 
     /**
      * 是否精品
      */
-    private Boolean isBest;
+    private Integer isBest;
 
     /**
      * 是否新品
      */
-    private Boolean isNew;
+    private Integer isNew;
 
     /**
      * 添加时间
@@ -142,12 +145,12 @@ public class StoreProductDTO implements Serializable {
     /**
      * 是否优品推荐
      */
-    private Boolean isGood;
+    private Integer isGood;
 
     /**
      * 是否单独分佣
      */
-    private Boolean isSub;
+    private Integer isSub;
 
     /**
      * 虚拟销量
@@ -172,7 +175,7 @@ public class StoreProductDTO implements Serializable {
     /**
      * 规格 0单 1多
      */
-    private Boolean specType;
+    private Integer specType;
 
     /**
      * 活动显示排序0=默认, 1=秒杀,2=砍价,3=拼团
@@ -182,7 +185,7 @@ public class StoreProductDTO implements Serializable {
     /**
      * 是否回收站
      */
-    private Boolean isRecycle;
+    private Integer isRecycle;
 
     /**
      * 创建人id

+ 4 - 139
mall-api/src/main/java/com/txz/mall/dto/StoreProductRuleDTO.java

@@ -6,9 +6,12 @@
  */
 package com.txz.mall.dto;
 
+import lombok.Data;
+
 import java.io.Serializable;
 import java.util.Date;
 
+@Data
 public class StoreProductRuleDTO implements Serializable {
     /**
      * m_store_product_rule
@@ -41,149 +44,11 @@ public class StoreProductRuleDTO implements Serializable {
     /**
      * 是否删除
      */
-    private Byte isDelete;
+    private Integer isDelete;
     /**
      * 规格值
      */
     private String ruleValue;
 
-    /**
-     * @return id
-     */
-    public Long getId() {
-        return id;
-    }
-
-    /**
-     * @param id
-     */
-    public void setId(Long id) {
-        this.id = id;
-    }
-
-    /**
-     * 规格名称
-     *
-     * @return rule_name 规格名称
-     */
-    public String getRuleName() {
-        return ruleName;
-    }
-
-    /**
-     * 规格名称
-     *
-     * @param ruleName 规格名称
-     */
-    public void setRuleName(String ruleName) {
-        this.ruleName = ruleName;
-    }
-
-    /**
-     * 创建时间
-     *
-     * @return create_time 创建时间
-     */
-    public Date getCreateTime() {
-        return createTime;
-    }
-
-    /**
-     * 创建时间
-     *
-     * @param createTime 创建时间
-     */
-    public void setCreateTime(Date createTime) {
-        this.createTime = createTime;
-    }
 
-    /**
-     * 更新时间
-     *
-     * @return update_time 更新时间
-     */
-    public Date getUpdateTime() {
-        return updateTime;
-    }
-
-    /**
-     * 更新时间
-     *
-     * @param updateTime 更新时间
-     */
-    public void setUpdateTime(Date updateTime) {
-        this.updateTime = updateTime;
-    }
-
-    /**
-     * 创建人id
-     *
-     * @return create_user_id 创建人id
-     */
-    public Long getCreateUserId() {
-        return createUserId;
-    }
-
-    /**
-     * 创建人id
-     *
-     * @param createUserId 创建人id
-     */
-    public void setCreateUserId(Long createUserId) {
-        this.createUserId = createUserId;
-    }
-
-    /**
-     * 更新人id
-     *
-     * @return update_user_id 更新人id
-     */
-    public Long getUpdateUserId() {
-        return updateUserId;
-    }
-
-    /**
-     * 更新人id
-     *
-     * @param updateUserId 更新人id
-     */
-    public void setUpdateUserId(Long updateUserId) {
-        this.updateUserId = updateUserId;
-    }
-
-    /**
-     * 是否删除
-     *
-     * @return is_delete 是否删除
-     */
-    public Byte getIsDelete() {
-        return isDelete;
-    }
-
-    /**
-     * 是否删除
-     *
-     * @param isDelete 是否删除
-     */
-    public void setIsDelete(Byte isDelete) {
-        this.isDelete = isDelete;
-    }
-
-    /**
-     * 规格值
-     *
-     * @return rule_value 规格值
-     */
-    public String getRuleValue() {
-        return ruleValue;
-    }
-
-    /**
-     * 规格值
-     *
-     * @param ruleValue 规格值
-     */
-    public void setRuleValue(String ruleValue) {
-        this.ruleValue = ruleValue;
-    }
 }

+ 58 - 0
mall-api/src/main/java/com/txz/mall/dto/SystemGroupDTO.java

@@ -0,0 +1,58 @@
+/*
+ *
+ * SystemGroupDTO.java
+ * Copyright(C) 2017-2020 fendo公司
+ * @date 2025-07-11
+ */
+package com.txz.mall.dto;
+
+import lombok.Data;
+
+import java.io.Serializable;
+import java.util.Date;
+
+@Data
+public class SystemGroupDTO implements Serializable {
+    /**
+     * m_system_group
+     */
+    private static final long serialVersionUID = 1L;
+    /**
+     * 组合数据ID
+     */
+    private Long id;
+    /**
+     * 数据组名称
+     */
+    private String name;
+    /**
+     * 简介
+     */
+    private String info;
+    /**
+     * form 表单 id
+     */
+    private Integer formId;
+    /**
+     * 创建时间
+     */
+    private Date createTime;
+    /**
+     * 更新时间
+     */
+    private Date updateTime;
+    /**
+     * 创建人id
+     */
+    private Long createUserId;
+    /**
+     * 更新人id
+     */
+    private Long updateUserId;
+    /**
+     * 是否删除
+     */
+    private Integer isDelete;
+
+
+}

+ 62 - 0
mall-api/src/main/java/com/txz/mall/dto/SystemGroupDataDTO.java

@@ -0,0 +1,62 @@
+/*
+ *
+ * SystemGroupDataDTO.java
+ * Copyright(C) 2017-2020 fendo公司
+ * @date 2025-07-11
+ */
+package com.txz.mall.dto;
+
+import lombok.Data;
+
+import java.io.Serializable;
+import java.util.Date;
+
+@Data
+public class SystemGroupDataDTO implements Serializable {
+    /**
+     * m_system_group_data
+     */
+    private static final long serialVersionUID = 1L;
+    /**
+     * 组合数据详情ID
+     */
+    private Long id;
+    /**
+     * 对应的数据组id
+     */
+    private Long gid;
+    /**
+     * 数据排序
+     */
+    private Integer sort;
+    /**
+     * 状态(1:开启;0:关闭;)
+     */
+    private Integer status;
+    /**
+     * 创建时间
+     */
+    private Date createTime;
+    /**
+     * 更新时间
+     */
+    private Date updateTime;
+    /**
+     * 创建人id
+     */
+    private Long createUserId;
+    /**
+     * 更新人id
+     */
+    private Long updateUserId;
+    /**
+     * 是否删除
+     */
+    private Integer isDelete;
+    /**
+     * 数据组对应的数据值(json数据)
+     */
+    private String value;
+
+
+}

+ 3 - 138
mall-api/src/main/java/com/txz/mall/dto/UserSignDTO.java

@@ -6,9 +6,12 @@
  */
 package com.txz.mall.dto;
 
+import lombok.Data;
+
 import java.io.Serializable;
 import java.util.Date;
 
+@Data
 public class UserSignDTO implements Serializable {
     /**
      * m_user_sign
@@ -47,143 +50,5 @@ public class UserSignDTO implements Serializable {
      */
     private Date createTime;
 
-    /**
-     * @return id
-     */
-    public Long getId() {
-        return id;
-    }
-
-    /**
-     * @param id
-     */
-    public void setId(Long id) {
-        this.id = id;
-    }
-
-    /**
-     * 用户uid
-     *
-     * @return uid 用户uid
-     */
-    public Long getUid() {
-        return uid;
-    }
-
-    /**
-     * 用户uid
-     *
-     * @param uid 用户uid
-     */
-    public void setUid(Long uid) {
-        this.uid = uid;
-    }
-
-    /**
-     * 签到说明
-     *
-     * @return title 签到说明
-     */
-    public String getTitle() {
-        return title;
-    }
-
-    /**
-     * 签到说明
-     *
-     * @param title 签到说明
-     */
-    public void setTitle(String title) {
-        this.title = title;
-    }
 
-    /**
-     * 获得
-     *
-     * @return number 获得
-     */
-    public Integer getNumber() {
-        return number;
-    }
-
-    /**
-     * 获得
-     *
-     * @param number 获得
-     */
-    public void setNumber(Integer number) {
-        this.number = number;
-    }
-
-    /**
-     * 剩余
-     *
-     * @return balance 剩余
-     */
-    public Integer getBalance() {
-        return balance;
-    }
-
-    /**
-     * 剩余
-     *
-     * @param balance 剩余
-     */
-    public void setBalance(Integer balance) {
-        this.balance = balance;
-    }
-
-    /**
-     * 类型,1积分,2经验  3金币
-     *
-     * @return type 类型,1积分,2经验  3金币
-     */
-    public Boolean getType() {
-        return type;
-    }
-
-    /**
-     * 类型,1积分,2经验  3金币
-     *
-     * @param type 类型,1积分,2经验  3金币
-     */
-    public void setType(Boolean type) {
-        this.type = type;
-    }
-
-    /**
-     * 签到日期
-     *
-     * @return create_day 签到日期
-     */
-    public Date getCreateDay() {
-        return createDay;
-    }
-
-    /**
-     * 签到日期
-     *
-     * @param createDay 签到日期
-     */
-    public void setCreateDay(Date createDay) {
-        this.createDay = createDay;
-    }
-
-    /**
-     * 添加时间
-     *
-     * @return create_time 添加时间
-     */
-    public Date getCreateTime() {
-        return createTime;
-    }
-
-    /**
-     * 添加时间
-     *
-     * @param createTime 添加时间
-     */
-    public void setCreateTime(Date createTime) {
-        this.createTime = createTime;
-    }
 }

+ 27 - 0
mall-interface/src/main/java/com/txz/mall/service/SystemGroupDataServiceClient.java

@@ -0,0 +1,27 @@
+package com.txz.mall.service;
+
+
+import com.txz.mall.dto.*;
+import org.springframework.cloud.openfeign.FeignClient;
+import org.springframework.web.bind.annotation.*;
+import java.util.List;
+
+
+@FeignClient("mall")
+public interface SystemGroupDataServiceClient {
+
+	@RequestMapping( value = {"/system/group/data/add"}, method = {RequestMethod.POST} )
+    public Result add(@RequestBody SystemGroupDataDPO systemGroupData,@RequestParam("userId") Long userId);
+
+	@RequestMapping( value = {"/system/group/data/delete"}, method = {RequestMethod.POST} )
+	public Result delete(@RequestParam("id") Integer id,@RequestParam("userId") Long userId);
+
+	@RequestMapping( value = {"/system/group/data/update"}, method = {RequestMethod.POST} )
+	public Result update(@RequestBody SystemGroupDataDPO systemGroupData,@RequestParam("userId") Long userId);
+
+	@RequestMapping( value = {"/system/group/data/detail"}, method = {RequestMethod.POST} )
+	public Result<SystemGroupDataDPO> detail(@RequestParam("id") Integer id,@RequestParam("userId") Long userId);
+
+	@RequestMapping( value = {"/system/group/data/list"}, method = {RequestMethod.POST} )
+	public Result<List<SystemGroupDataDPO>> list(@RequestBody SystemGroupDataDPO systemGroupData, @RequestParam("page") Integer page, @RequestParam("size") Integer size,@RequestParam("userId") Long userId);
+}

+ 27 - 0
mall-interface/src/main/java/com/txz/mall/service/SystemGroupServiceClient.java

@@ -0,0 +1,27 @@
+package com.txz.mall.service;
+
+
+import com.txz.mall.dto.*;
+import org.springframework.cloud.openfeign.FeignClient;
+import org.springframework.web.bind.annotation.*;
+import java.util.List;
+
+
+@FeignClient("mall")
+public interface SystemGroupServiceClient {
+
+	@RequestMapping( value = {"/system/group/add"}, method = {RequestMethod.POST} )
+    public Result add(@RequestBody SystemGroupDPO systemGroup,@RequestParam("userId") Long userId);
+
+	@RequestMapping( value = {"/system/group/delete"}, method = {RequestMethod.POST} )
+	public Result delete(@RequestParam("id") Integer id,@RequestParam("userId") Long userId);
+
+	@RequestMapping( value = {"/system/group/update"}, method = {RequestMethod.POST} )
+	public Result update(@RequestBody SystemGroupDPO systemGroup,@RequestParam("userId") Long userId);
+
+	@RequestMapping( value = {"/system/group/detail"}, method = {RequestMethod.POST} )
+	public Result<SystemGroupDPO> detail(@RequestParam("id") Integer id,@RequestParam("userId") Long userId);
+
+	@RequestMapping( value = {"/system/group/list"}, method = {RequestMethod.POST} )
+	public Result<List<SystemGroupDPO>> list(@RequestBody SystemGroupDPO systemGroup, @RequestParam("page") Integer page, @RequestParam("size") Integer size,@RequestParam("userId") Long userId);
+}

+ 1 - 1
mall-service/src/main/java/com/txz/mall/controller/StoreProductRuleController.java

@@ -42,7 +42,7 @@ public class StoreProductRuleController {
         try {
             storeProductRule.setCreateTime(new Date());
             storeProductRule.setCreateUserId(userId);
-            storeProductRuleService.save(storeProductRule);
+            storeProductRuleService.saveRule(storeProductRule);
         } catch (Exception e) {
             log.error("新增对象操作异常e:{}", e);
             return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);

+ 137 - 0
mall-service/src/main/java/com/txz/mall/controller/SystemGroupController.java

@@ -0,0 +1,137 @@
+package com.txz.mall.controller;
+
+import com.github.pagehelper.PageHelper;
+import com.github.pagehelper.PageInfo;
+import com.txz.mall.core.Result;
+import com.txz.mall.core.ResultCode;
+import com.txz.mall.model.SystemGroup;
+import com.txz.mall.service.SystemGroupService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.web.bind.annotation.*;
+import tk.mybatis.mapper.entity.Condition;
+
+import javax.annotation.Resource;
+import java.util.Date;
+import java.util.List;
+
+/**
+ * Created by CodeGenerator on 2025/07/11.
+ */
+@Api(tags = "[后台]systemGroup管理")
+@RestController
+@RequestMapping("/system/group")
+public class SystemGroupController {
+
+    private static Logger log = LoggerFactory.getLogger(SystemGroupController.class);
+
+    @Resource
+    private SystemGroupService systemGroupService;
+
+    @PostMapping("/add")
+    @ApiOperation(value = "systemGroup新增", httpMethod = "POST")
+    public Result add(@RequestBody SystemGroup systemGroup, Long userId) {
+        if (systemGroup == null) {
+            return Result.fail(ResultCode.OBJECT_IS_NULL);
+        }
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        try {
+            systemGroup.setCreateTime(new Date());
+            systemGroup.setCreateUserId(userId);
+            systemGroupService.save(systemGroup);
+        } catch (Exception e) {
+            log.error("新增对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success();
+    }
+
+    @PostMapping("/delete")
+    @ApiOperation(value = "systemGroup删除", httpMethod = "POST")
+    public Result delete(@RequestParam Long id, Long userId) {
+        if (id == null) {
+            return Result.fail(ResultCode.ID_IS_NULL);
+        }
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        try {
+            SystemGroup systemGroup = new SystemGroup();
+            systemGroup.setId(id);
+            systemGroup.setIsDelete(1);
+            systemGroupService.update(systemGroup);
+        } catch (Exception e) {
+            log.error("删除对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success();
+    }
+
+    @PostMapping("/update")
+    @ApiOperation(value = "systemGroup更新", httpMethod = "POST")
+    public Result update(@RequestBody SystemGroup systemGroup, Long userId) {
+        if (systemGroup == null) {
+            return Result.fail(ResultCode.OBJECT_IS_NULL);
+        }
+        if (systemGroup.getId() == null) {
+            return Result.fail(ResultCode.ID_IS_NULL);
+        }
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        try {
+            systemGroup.setUpdateTime(new Date());
+            systemGroup.setUpdateUserId(userId);
+            systemGroupService.update(systemGroup);
+        } catch (Exception e) {
+            log.error("更新对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success();
+    }
+
+    @PostMapping("/detail")
+    @ApiOperation(value = "systemGroup获取详情", httpMethod = "POST")
+    public Result<SystemGroup> detail(@RequestParam Long id, Long userId) {
+        if (id == null) {
+            return Result.fail(ResultCode.ID_IS_NULL);
+        }
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        SystemGroup systemGroup = null;
+        try {
+            systemGroup = systemGroupService.findById(id);
+        } catch (Exception e) {
+            log.error("查询对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success(systemGroup);
+    }
+
+    @PostMapping("/list")
+    @ApiOperation(value = "systemGroup获取列表", httpMethod = "POST")
+    public Result<List<SystemGroup>> list(@RequestBody SystemGroup systemGroup, @RequestParam(defaultValue = "0") Integer page, @RequestParam(defaultValue = "0") Integer size, Long userId) {
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        PageHelper.startPage(page, size);
+
+        Condition condition = new Condition(systemGroup.getClass());
+//        Criteria criteria = condition.createCriteria();
+//        criteria.andEqualTo("name", city.getName());
+        PageInfo pageInfo = null;
+        try {
+            List<SystemGroup> list = systemGroupService.findByCondition(condition);
+            pageInfo = new PageInfo(list);
+        } catch (Exception e) {
+            log.error("查询对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success(pageInfo);
+    }
+}

+ 137 - 0
mall-service/src/main/java/com/txz/mall/controller/SystemGroupDataController.java

@@ -0,0 +1,137 @@
+package com.txz.mall.controller;
+
+import com.github.pagehelper.PageHelper;
+import com.github.pagehelper.PageInfo;
+import com.txz.mall.core.Result;
+import com.txz.mall.core.ResultCode;
+import com.txz.mall.model.SystemGroupData;
+import com.txz.mall.service.SystemGroupDataService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.web.bind.annotation.*;
+import tk.mybatis.mapper.entity.Condition;
+
+import javax.annotation.Resource;
+import java.util.Date;
+import java.util.List;
+
+/**
+ * Created by CodeGenerator on 2025/07/11.
+ */
+@Api(tags = "[后台]systemGroupData管理")
+@RestController
+@RequestMapping("/system/group/data")
+public class SystemGroupDataController {
+
+    private static Logger log = LoggerFactory.getLogger(SystemGroupDataController.class);
+
+    @Resource
+    private SystemGroupDataService systemGroupDataService;
+
+    @PostMapping("/add")
+    @ApiOperation(value = "systemGroupData新增", httpMethod = "POST")
+    public Result add(@RequestBody SystemGroupData systemGroupData, Long userId) {
+        if (systemGroupData == null) {
+            return Result.fail(ResultCode.OBJECT_IS_NULL);
+        }
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        try {
+            systemGroupData.setCreateTime(new Date());
+            systemGroupData.setCreateUserId(userId);
+            systemGroupDataService.save(systemGroupData);
+        } catch (Exception e) {
+            log.error("新增对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success();
+    }
+
+    @PostMapping("/delete")
+    @ApiOperation(value = "systemGroupData删除", httpMethod = "POST")
+    public Result delete(@RequestParam Long id, Long userId) {
+        if (id == null) {
+            return Result.fail(ResultCode.ID_IS_NULL);
+        }
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        try {
+            SystemGroupData systemGroupData = new SystemGroupData();
+            systemGroupData.setId(id);
+            systemGroupData.setIsDelete(1);
+            systemGroupDataService.update(systemGroupData);
+        } catch (Exception e) {
+            log.error("删除对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success();
+    }
+
+    @PostMapping("/update")
+    @ApiOperation(value = "systemGroupData更新", httpMethod = "POST")
+    public Result update(@RequestBody SystemGroupData systemGroupData, Long userId) {
+        if (systemGroupData == null) {
+            return Result.fail(ResultCode.OBJECT_IS_NULL);
+        }
+        if (systemGroupData.getId() == null) {
+            return Result.fail(ResultCode.ID_IS_NULL);
+        }
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        try {
+            systemGroupData.setUpdateTime(new Date());
+            systemGroupData.setUpdateUserId(userId);
+            systemGroupDataService.update(systemGroupData);
+        } catch (Exception e) {
+            log.error("更新对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success();
+    }
+
+    @PostMapping("/detail")
+    @ApiOperation(value = "systemGroupData获取详情", httpMethod = "POST")
+    public Result<SystemGroupData> detail(@RequestParam Long id, Long userId) {
+        if (id == null) {
+            return Result.fail(ResultCode.ID_IS_NULL);
+        }
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        SystemGroupData systemGroupData = null;
+        try {
+            systemGroupData = systemGroupDataService.findById(id);
+        } catch (Exception e) {
+            log.error("查询对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success(systemGroupData);
+    }
+
+    @PostMapping("/list")
+    @ApiOperation(value = "systemGroupData获取列表", httpMethod = "POST")
+    public Result<List<SystemGroupData>> list(@RequestBody SystemGroupData systemGroupData, @RequestParam(defaultValue = "0") Integer page, @RequestParam(defaultValue = "0") Integer size, Long userId) {
+        if (userId == null) {
+            return Result.fail(ResultCode.USERID_IS_NULL);
+        }
+        PageHelper.startPage(page, size);
+
+        Condition condition = new Condition(systemGroupData.getClass());
+//        Criteria criteria = condition.createCriteria();
+//        criteria.andEqualTo("name", city.getName());
+        PageInfo pageInfo = null;
+        try {
+            List<SystemGroupData> list = systemGroupDataService.findByCondition(condition);
+            pageInfo = new PageInfo(list);
+        } catch (Exception e) {
+            log.error("查询对象操作异常e:{}", e);
+            return Result.fail(ResultCode.INTERNAL_SERVER_ERROR);
+        }
+        return Result.success(pageInfo);
+    }
+}

+ 7 - 0
mall-service/src/main/java/com/txz/mall/dao/SystemGroupDataMapper.java

@@ -0,0 +1,7 @@
+package com.txz.mall.dao;
+
+import com.txz.mall.core.Mapper;
+import com.txz.mall.model.SystemGroupData;
+
+public interface SystemGroupDataMapper extends Mapper<SystemGroupData> {
+}

+ 7 - 0
mall-service/src/main/java/com/txz/mall/dao/SystemGroupMapper.java

@@ -0,0 +1,7 @@
+package com.txz.mall.dao;
+
+import com.txz.mall.core.Mapper;
+import com.txz.mall.model.SystemGroup;
+
+public interface SystemGroupMapper extends Mapper<SystemGroup> {
+}

+ 65 - 0
mall-service/src/main/java/com/txz/mall/model/SystemGroup.java

@@ -0,0 +1,65 @@
+package com.txz.mall.model;
+
+import lombok.Data;
+
+import javax.persistence.*;
+import java.util.Date;
+
+@Data
+@Table(name = "m_system_group")
+public class SystemGroup {
+    /**
+     * 组合数据ID
+     */
+    @Id
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    private Long id;
+
+    /**
+     * 数据组名称
+     */
+    private String name;
+
+    /**
+     * 简介
+     */
+    private String info;
+
+    /**
+     * form 表单 id
+     */
+    @Column(name = "form_id")
+    private Integer formId;
+
+    /**
+     * 创建时间
+     */
+    @Column(name = "create_time")
+    private Date createTime;
+
+    /**
+     * 更新时间
+     */
+    @Column(name = "update_time")
+    private Date updateTime;
+
+    /**
+     * 创建人id
+     */
+    @Column(name = "create_user_id")
+    private Long createUserId;
+
+    /**
+     * 更新人id
+     */
+    @Column(name = "update_user_id")
+    private Long updateUserId;
+
+    /**
+     * 是否删除
+     */
+    @Column(name = "is_delete")
+    private Integer isDelete;
+
+
+}

+ 68 - 0
mall-service/src/main/java/com/txz/mall/model/SystemGroupData.java

@@ -0,0 +1,68 @@
+package com.txz.mall.model;
+
+import lombok.Data;
+
+import javax.persistence.*;
+import java.util.Date;
+
+@Data
+@Table(name = "m_system_group_data")
+public class SystemGroupData {
+    /**
+     * 组合数据详情ID
+     */
+    @Id
+    @GeneratedValue(strategy = GenerationType.IDENTITY)
+    private Long id;
+
+    /**
+     * 对应的数据组id
+     */
+    private Long gid;
+
+    /**
+     * 数据排序
+     */
+    private Integer sort;
+
+    /**
+     * 状态(1:开启;0:关闭;)
+     */
+    private Integer status;
+
+    /**
+     * 创建时间
+     */
+    @Column(name = "create_time")
+    private Date createTime;
+
+    /**
+     * 更新时间
+     */
+    @Column(name = "update_time")
+    private Date updateTime;
+
+    /**
+     * 创建人id
+     */
+    @Column(name = "create_user_id")
+    private Long createUserId;
+
+    /**
+     * 更新人id
+     */
+    @Column(name = "update_user_id")
+    private Long updateUserId;
+
+    /**
+     * 是否删除
+     */
+    @Column(name = "is_delete")
+    private Integer isDelete;
+
+    /**
+     * 数据组对应的数据值(json数据)
+     */
+    private String value;
+
+}

+ 6 - 0
mall-service/src/main/java/com/txz/mall/service/StoreProductRuleService.java

@@ -9,4 +9,10 @@ import com.txz.mall.model.StoreProductRule;
  */
 public interface StoreProductRuleService extends Service<StoreProductRule> {
 
+    /**
+     * 保存规则
+     *
+     * @param storeProductRule
+     */
+    void saveRule(StoreProductRule storeProductRule);
 }

+ 12 - 0
mall-service/src/main/java/com/txz/mall/service/SystemGroupDataService.java

@@ -0,0 +1,12 @@
+package com.txz.mall.service;
+
+import com.txz.mall.core.Service;
+import com.txz.mall.model.SystemGroupData;
+
+
+/**
+ * Created by CodeGenerator on 2025/07/11.
+ */
+public interface SystemGroupDataService extends Service<SystemGroupData> {
+
+}

+ 12 - 0
mall-service/src/main/java/com/txz/mall/service/SystemGroupService.java

@@ -0,0 +1,12 @@
+package com.txz.mall.service;
+
+import com.txz.mall.core.Service;
+import com.txz.mall.model.SystemGroup;
+
+
+/**
+ * Created by CodeGenerator on 2025/07/11.
+ */
+public interface SystemGroupService extends Service<SystemGroup> {
+
+}

+ 1 - 1
mall-service/src/main/java/com/txz/mall/service/impl/StoreProductAttrResultServiceImpl.java

@@ -17,6 +17,6 @@ import javax.annotation.Resource;
 @Transactional
 public class StoreProductAttrResultServiceImpl extends AbstractService<StoreProductAttrResult> implements StoreProductAttrResultService {
     @Resource
-    private StoreProductAttrResultMapper mStoreProductAttrResultMapper;
+    private StoreProductAttrResultMapper productAttrResultMapper;
 
 }

+ 31 - 1
mall-service/src/main/java/com/txz/mall/service/impl/StoreProductRuleServiceImpl.java

@@ -1,13 +1,19 @@
 package com.txz.mall.service.impl;
 
 import com.txz.mall.core.AbstractService;
+import com.txz.mall.core.ServiceException;
 import com.txz.mall.dao.StoreProductRuleMapper;
 import com.txz.mall.model.StoreProductRule;
 import com.txz.mall.service.StoreProductRuleService;
+import org.apache.commons.lang3.StringUtils;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
+import tk.mybatis.mapper.entity.Condition;
+import tk.mybatis.mapper.entity.Example;
 
 import javax.annotation.Resource;
+import java.util.ArrayList;
+import java.util.List;
 
 
 /**
@@ -17,6 +23,30 @@ import javax.annotation.Resource;
 @Transactional
 public class StoreProductRuleServiceImpl extends AbstractService<StoreProductRule> implements StoreProductRuleService {
     @Resource
-    private StoreProductRuleMapper mStoreProductRuleMapper;
+    private StoreProductRuleMapper storeProductRuleMapper;
 
+    @Override
+    public void saveRule(StoreProductRule storeProductRule) {
+        // 格式  {"id":573,"ruleName":"衣服规格1","ruleValue":"[{\"value\":\"颜色\",\"detail\":[\"蓝色\",\"黄色\"],\"inputVisible\":false},{\"value\":\"尺码\",\"detail\":[\"s码\",\"m码\",\"l码\"],\"inputVisible\":false}]"}
+        if (getListByRuleName(storeProductRule.getRuleName()).size() > 0) {
+            throw new ServiceException("此规格值已经存在");
+        }
+        save(storeProductRule);
+    }
+
+    /**
+     * 根据规格名称查询同名规格
+     *
+     * @param ruleName 规格名称
+     * @return 查询到的数据
+     */
+    private List<StoreProductRule> getListByRuleName(String ruleName) {
+        if (StringUtils.isBlank(ruleName)) {
+            return new ArrayList<>();
+        }
+        Condition condition = new Condition(StoreProductRule.class);
+        Example.Criteria criteria = condition.createCriteria();
+        criteria.andEqualTo("ruleName", ruleName);
+        return findByCondition(condition);
+    }
 }

+ 22 - 0
mall-service/src/main/java/com/txz/mall/service/impl/SystemGroupDataServiceImpl.java

@@ -0,0 +1,22 @@
+package com.txz.mall.service.impl;
+
+import com.txz.mall.core.AbstractService;
+import com.txz.mall.dao.SystemGroupDataMapper;
+import com.txz.mall.model.SystemGroupData;
+import com.txz.mall.service.SystemGroupDataService;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import javax.annotation.Resource;
+
+
+/**
+ * Created by CodeGenerator on 2025/07/11.
+ */
+@Service
+@Transactional
+public class SystemGroupDataServiceImpl extends AbstractService<SystemGroupData> implements SystemGroupDataService {
+    @Resource
+    private SystemGroupDataMapper systemGroupDataMapper;
+
+}

+ 22 - 0
mall-service/src/main/java/com/txz/mall/service/impl/SystemGroupServiceImpl.java

@@ -0,0 +1,22 @@
+package com.txz.mall.service.impl;
+
+import com.txz.mall.core.AbstractService;
+import com.txz.mall.dao.SystemGroupMapper;
+import com.txz.mall.model.SystemGroup;
+import com.txz.mall.service.SystemGroupService;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import javax.annotation.Resource;
+
+
+/**
+ * Created by CodeGenerator on 2025/07/11.
+ */
+@Service
+@Transactional
+public class SystemGroupServiceImpl extends AbstractService<SystemGroup> implements SystemGroupService {
+    @Resource
+    private SystemGroupMapper systemGroupMapper;
+
+}

+ 19 - 0
mall-service/src/main/resources/mapper/SystemGroupDataMapper.xml

@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.txz.mall.dao.SystemGroupDataMapper">
+    <resultMap id="BaseResultMap" type="com.txz.mall.model.SystemGroupData">
+        <!--
+          WARNING - @mbg.generated
+        -->
+        <id column="id" jdbcType="BIGINT" property="id"/>
+        <result column="gid" jdbcType="BIGINT" property="gid"/>
+        <result column="sort" jdbcType="INTEGER" property="sort"/>
+        <result column="status" jdbcType="INTEGER" property="status"/>
+        <result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
+        <result column="update_time" jdbcType="TIMESTAMP" property="updateTime"/>
+        <result column="create_user_id" jdbcType="BIGINT" property="createUserId"/>
+        <result column="update_user_id" jdbcType="BIGINT" property="updateUserId"/>
+        <result column="is_delete" jdbcType="INTEGER" property="isDelete"/>
+        <result column="value" jdbcType="VARCHAR" property="value"/>
+    </resultMap>
+</mapper>

+ 18 - 0
mall-service/src/main/resources/mapper/SystemGroupMapper.xml

@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.txz.mall.dao.SystemGroupMapper">
+    <resultMap id="BaseResultMap" type="com.txz.mall.model.SystemGroup">
+        <!--
+          WARNING - @mbg.generated
+        -->
+        <id column="id" jdbcType="BIGINT" property="id"/>
+        <result column="name" jdbcType="VARCHAR" property="name"/>
+        <result column="info" jdbcType="VARCHAR" property="info"/>
+        <result column="form_id" jdbcType="INTEGER" property="formId"/>
+        <result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
+        <result column="update_time" jdbcType="TIMESTAMP" property="updateTime"/>
+        <result column="create_user_id" jdbcType="BIGINT" property="createUserId"/>
+        <result column="update_user_id" jdbcType="BIGINT" property="updateUserId"/>
+        <result column="is_delete" jdbcType="INTEGER" property="isDelete"/>
+    </resultMap>
+</mapper>