diff --git a/src/main/java/org/springblade/modules/jinchao/controller/RelCatalogProductController.java b/src/main/java/org/springblade/modules/jinchao/controller/RelCatalogProductController.java new file mode 100644 index 0000000..afe68c4 --- /dev/null +++ b/src/main/java/org/springblade/modules/jinchao/controller/RelCatalogProductController.java @@ -0,0 +1,161 @@ +/** + * BladeX Commercial License Agreement + * Copyright (c) 2018-2099, https://bladex.cn. All rights reserved. + *
+ * Use of this software is governed by the Commercial License Agreement + * obtained after purchasing a license from BladeX. + *
+ * 1. This software is for development use only under a valid license + * from BladeX. + *
+ * 2. Redistribution of this software's source code to any third party + * without a commercial license is strictly prohibited. + *
+ * 3. Licensees may copyright their own code but cannot use segments + * from this software for such purposes. Copyright of this software + * remains with BladeX. + *
+ * Using this software signifies agreement to this License, and the software + * must not be used for illegal purposes. + *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is + * not liable for any claims arising from secondary or illegal development. + *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.controller;
+
+import io.swagger.v3.oas.annotations.tags.Tag;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.Parameter;
+import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
+import lombok.AllArgsConstructor;
+import jakarta.validation.Valid;
+
+import org.springblade.core.secure.BladeUser;
+import org.springblade.core.secure.annotation.IsAdmin;
+import org.springblade.core.mp.support.Condition;
+import org.springblade.core.mp.support.Query;
+import org.springblade.core.tool.api.R;
+import org.springblade.core.tool.utils.Func;
+import org.springframework.web.bind.annotation.*;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springblade.modules.jinchao.pojo.entity.RelCatalogProductEntity;
+import org.springblade.modules.jinchao.pojo.vo.RelCatalogProductVO;
+import org.springblade.modules.jinchao.excel.RelCatalogProductExcel;
+import org.springblade.modules.jinchao.wrapper.RelCatalogProductWrapper;
+import org.springblade.modules.jinchao.service.IRelCatalogProductService;
+import org.springblade.core.boot.ctrl.BladeController;
+import org.springblade.core.tool.utils.DateUtil;
+import org.springblade.core.excel.util.ExcelUtil;
+import org.springblade.core.tool.constant.BladeConstant;
+import java.util.Map;
+import java.util.List;
+import jakarta.servlet.http.HttpServletResponse;
+
+/**
+ * [产品目录][产品]关联表 控制器
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+@RestController
+@AllArgsConstructor
+@RequestMapping("jinchao/relCatalogProduct")
+@Tag(name = "[产品目录][产品]关联表", description = "[产品目录][产品]关联表接口")
+public class RelCatalogProductController extends BladeController {
+
+ private final IRelCatalogProductService relCatalogProductService;
+
+ /**
+ * [产品目录][产品]关联表 详情
+ */
+ @GetMapping("/detail")
+ @ApiOperationSupport(order = 1)
+ @Operation(summary = "详情", description = "传入relCatalogProduct")
+ public R
+ * Use of this software is governed by the Commercial License Agreement
+ * obtained after purchasing a license from BladeX.
+ *
+ * 1. This software is for development use only under a valid license
+ * from BladeX.
+ *
+ * 2. Redistribution of this software's source code to any third party
+ * without a commercial license is strictly prohibited.
+ *
+ * 3. Licensees may copyright their own code but cannot use segments
+ * from this software for such purposes. Copyright of this software
+ * remains with BladeX.
+ *
+ * Using this software signifies agreement to this License, and the software
+ * must not be used for illegal purposes.
+ *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
+ * not liable for any claims arising from secondary or illegal development.
+ *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.excel;
+
+
+import lombok.Data;
+
+import cn.idev.excel.annotation.ExcelProperty;
+import cn.idev.excel.annotation.write.style.ColumnWidth;
+import cn.idev.excel.annotation.write.style.ContentRowHeight;
+import cn.idev.excel.annotation.write.style.HeadRowHeight;
+import java.io.Serializable;
+import java.io.Serial;
+
+
+/**
+ * [产品目录][产品]关联表 Excel实体类
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+@Data
+@ColumnWidth(25)
+@HeadRowHeight(20)
+@ContentRowHeight(18)
+public class RelCatalogProductExcel implements Serializable {
+
+ @Serial
+ private static final long serialVersionUID = 1L;
+
+ /**
+ * 主键
+ */
+ @ColumnWidth(20)
+ @ExcelProperty("主键")
+ private Long id;
+ /**
+ * 租户ID
+ */
+ @ColumnWidth(20)
+ @ExcelProperty("租户ID")
+ private String tenantId;
+ /**
+ * 小类[产品目录]id
+ */
+ @ColumnWidth(20)
+ @ExcelProperty("小类[产品目录]id")
+ private Long catalogId;
+ /**
+ * [产品]id
+ */
+ @ColumnWidth(20)
+ @ExcelProperty("[产品]id")
+ private Long productId;
+ /**
+ * 是否已删除
+ */
+ @ColumnWidth(20)
+ @ExcelProperty("是否已删除")
+ private Integer isDeleted;
+
+}
diff --git a/src/main/java/org/springblade/modules/jinchao/mapper/RelCatalogProductMapper.java b/src/main/java/org/springblade/modules/jinchao/mapper/RelCatalogProductMapper.java
new file mode 100644
index 0000000..d882c58
--- /dev/null
+++ b/src/main/java/org/springblade/modules/jinchao/mapper/RelCatalogProductMapper.java
@@ -0,0 +1,62 @@
+/**
+ * BladeX Commercial License Agreement
+ * Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
+ *
+ * Use of this software is governed by the Commercial License Agreement
+ * obtained after purchasing a license from BladeX.
+ *
+ * 1. This software is for development use only under a valid license
+ * from BladeX.
+ *
+ * 2. Redistribution of this software's source code to any third party
+ * without a commercial license is strictly prohibited.
+ *
+ * 3. Licensees may copyright their own code but cannot use segments
+ * from this software for such purposes. Copyright of this software
+ * remains with BladeX.
+ *
+ * Using this software signifies agreement to this License, and the software
+ * must not be used for illegal purposes.
+ *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
+ * not liable for any claims arising from secondary or illegal development.
+ *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.mapper;
+
+import org.springblade.modules.jinchao.pojo.entity.RelCatalogProductEntity;
+import org.springblade.modules.jinchao.pojo.vo.RelCatalogProductVO;
+import org.springblade.modules.jinchao.excel.RelCatalogProductExcel;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.core.conditions.Wrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.apache.ibatis.annotations.Param;
+import java.util.List;
+
+/**
+ * [产品目录][产品]关联表 Mapper 接口
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+public interface RelCatalogProductMapper extends BaseMapper
+ * Use of this software is governed by the Commercial License Agreement
+ * obtained after purchasing a license from BladeX.
+ *
+ * 1. This software is for development use only under a valid license
+ * from BladeX.
+ *
+ * 2. Redistribution of this software's source code to any third party
+ * without a commercial license is strictly prohibited.
+ *
+ * 3. Licensees may copyright their own code but cannot use segments
+ * from this software for such purposes. Copyright of this software
+ * remains with BladeX.
+ *
+ * Using this software signifies agreement to this License, and the software
+ * must not be used for illegal purposes.
+ *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
+ * not liable for any claims arising from secondary or illegal development.
+ *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.pojo.dto;
+
+import org.springblade.modules.jinchao.pojo.entity.RelCatalogProductEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import java.io.Serial;
+
+/**
+ * [产品目录][产品]关联表 数据传输对象实体类
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class RelCatalogProductDTO extends RelCatalogProductEntity {
+ @Serial
+ private static final long serialVersionUID = 1L;
+
+}
diff --git a/src/main/java/org/springblade/modules/jinchao/pojo/entity/RelCatalogProductEntity.java b/src/main/java/org/springblade/modules/jinchao/pojo/entity/RelCatalogProductEntity.java
new file mode 100644
index 0000000..1b4ee74
--- /dev/null
+++ b/src/main/java/org/springblade/modules/jinchao/pojo/entity/RelCatalogProductEntity.java
@@ -0,0 +1,60 @@
+/**
+ * BladeX Commercial License Agreement
+ * Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
+ *
+ * Use of this software is governed by the Commercial License Agreement
+ * obtained after purchasing a license from BladeX.
+ *
+ * 1. This software is for development use only under a valid license
+ * from BladeX.
+ *
+ * 2. Redistribution of this software's source code to any third party
+ * without a commercial license is strictly prohibited.
+ *
+ * 3. Licensees may copyright their own code but cannot use segments
+ * from this software for such purposes. Copyright of this software
+ * remains with BladeX.
+ *
+ * Using this software signifies agreement to this License, and the software
+ * must not be used for illegal purposes.
+ *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
+ * not liable for any claims arising from secondary or illegal development.
+ *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.pojo.entity;
+
+import lombok.Data;
+import io.swagger.v3.oas.annotations.media.Schema;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.EqualsAndHashCode;
+import org.springblade.core.tenant.mp.TenantEntity;
+import java.io.Serial;
+
+/**
+ * [产品目录][产品]关联表 实体类
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+@Data
+@TableName("jc_rel_catalog_product")
+@Schema(description = "RelCatalogProduct对象")
+@EqualsAndHashCode(callSuper = true)
+public class RelCatalogProductEntity extends TenantEntity {
+
+ @Serial
+ private static final long serialVersionUID = 1L;
+
+ /**
+ * 小类[产品目录]id
+ */
+ @Schema(description = "小类[产品目录]id")
+ private Long catalogId;
+ /**
+ * [产品]id
+ */
+ @Schema(description = "[产品]id")
+ private Long productId;
+}
diff --git a/src/main/java/org/springblade/modules/jinchao/pojo/vo/RelCatalogProductVO.java b/src/main/java/org/springblade/modules/jinchao/pojo/vo/RelCatalogProductVO.java
new file mode 100644
index 0000000..798ad49
--- /dev/null
+++ b/src/main/java/org/springblade/modules/jinchao/pojo/vo/RelCatalogProductVO.java
@@ -0,0 +1,45 @@
+/**
+ * BladeX Commercial License Agreement
+ * Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
+ *
+ * Use of this software is governed by the Commercial License Agreement
+ * obtained after purchasing a license from BladeX.
+ *
+ * 1. This software is for development use only under a valid license
+ * from BladeX.
+ *
+ * 2. Redistribution of this software's source code to any third party
+ * without a commercial license is strictly prohibited.
+ *
+ * 3. Licensees may copyright their own code but cannot use segments
+ * from this software for such purposes. Copyright of this software
+ * remains with BladeX.
+ *
+ * Using this software signifies agreement to this License, and the software
+ * must not be used for illegal purposes.
+ *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
+ * not liable for any claims arising from secondary or illegal development.
+ *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.pojo.vo;
+
+import org.springblade.modules.jinchao.pojo.entity.RelCatalogProductEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import java.io.Serial;
+
+/**
+ * [产品目录][产品]关联表 视图实体类
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class RelCatalogProductVO extends RelCatalogProductEntity {
+ @Serial
+ private static final long serialVersionUID = 1L;
+
+}
diff --git a/src/main/java/org/springblade/modules/jinchao/service/IRelCatalogProductService.java b/src/main/java/org/springblade/modules/jinchao/service/IRelCatalogProductService.java
new file mode 100644
index 0000000..645818d
--- /dev/null
+++ b/src/main/java/org/springblade/modules/jinchao/service/IRelCatalogProductService.java
@@ -0,0 +1,61 @@
+/**
+ * BladeX Commercial License Agreement
+ * Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
+ *
+ * Use of this software is governed by the Commercial License Agreement
+ * obtained after purchasing a license from BladeX.
+ *
+ * 1. This software is for development use only under a valid license
+ * from BladeX.
+ *
+ * 2. Redistribution of this software's source code to any third party
+ * without a commercial license is strictly prohibited.
+ *
+ * 3. Licensees may copyright their own code but cannot use segments
+ * from this software for such purposes. Copyright of this software
+ * remains with BladeX.
+ *
+ * Using this software signifies agreement to this License, and the software
+ * must not be used for illegal purposes.
+ *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
+ * not liable for any claims arising from secondary or illegal development.
+ *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.service;
+
+import com.baomidou.mybatisplus.core.conditions.Wrapper;
+import org.springblade.modules.jinchao.pojo.entity.RelCatalogProductEntity;
+import org.springblade.modules.jinchao.pojo.vo.RelCatalogProductVO;
+import org.springblade.modules.jinchao.excel.RelCatalogProductExcel;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springblade.core.mp.base.BaseService;
+import java.util.List;
+
+/**
+ * [产品目录][产品]关联表 服务类
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+public interface IRelCatalogProductService extends BaseService
+ * Use of this software is governed by the Commercial License Agreement
+ * obtained after purchasing a license from BladeX.
+ *
+ * 1. This software is for development use only under a valid license
+ * from BladeX.
+ *
+ * 2. Redistribution of this software's source code to any third party
+ * without a commercial license is strictly prohibited.
+ *
+ * 3. Licensees may copyright their own code but cannot use segments
+ * from this software for such purposes. Copyright of this software
+ * remains with BladeX.
+ *
+ * Using this software signifies agreement to this License, and the software
+ * must not be used for illegal purposes.
+ *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
+ * not liable for any claims arising from secondary or illegal development.
+ *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.service.impl;
+
+import org.springblade.modules.jinchao.pojo.entity.RelCatalogProductEntity;
+import org.springblade.modules.jinchao.pojo.vo.RelCatalogProductVO;
+import org.springblade.modules.jinchao.excel.RelCatalogProductExcel;
+import org.springblade.modules.jinchao.mapper.RelCatalogProductMapper;
+import org.springblade.modules.jinchao.service.IRelCatalogProductService;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.core.conditions.Wrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springblade.core.mp.base.BaseServiceImpl;
+import java.util.List;
+
+/**
+ * [产品目录][产品]关联表 服务实现类
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+@Service
+public class RelCatalogProductServiceImpl extends BaseServiceImpl
+ * Use of this software is governed by the Commercial License Agreement
+ * obtained after purchasing a license from BladeX.
+ *
+ * 1. This software is for development use only under a valid license
+ * from BladeX.
+ *
+ * 2. Redistribution of this software's source code to any third party
+ * without a commercial license is strictly prohibited.
+ *
+ * 3. Licensees may copyright their own code but cannot use segments
+ * from this software for such purposes. Copyright of this software
+ * remains with BladeX.
+ *
+ * Using this software signifies agreement to this License, and the software
+ * must not be used for illegal purposes.
+ *
+ * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
+ * not liable for any claims arising from secondary or illegal development.
+ *
+ * Author: Chill Zhuang (bladejava@qq.com)
+ */
+package org.springblade.modules.jinchao.wrapper;
+
+import org.springblade.core.mp.support.BaseEntityWrapper;
+import org.springblade.core.tool.utils.BeanUtil;
+import org.springblade.modules.jinchao.pojo.entity.RelCatalogProductEntity;
+import org.springblade.modules.jinchao.pojo.vo.RelCatalogProductVO;
+import java.util.Objects;
+
+/**
+ * [产品目录][产品]关联表 包装类,返回视图层所需的字段
+ *
+ * @author BladeX
+ * @since 2025-12-03
+ */
+public class RelCatalogProductWrapper extends BaseEntityWrapper