Browse Source

fix:修改资料管理模块pom文件

Eternity 5 months ago
parent
commit
e84aecac7d

+ 83 - 22
ruoyi-modules/ruoyi-dataManagement/pom.xml

@@ -3,47 +3,108 @@
          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
     <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <groupId>org.dromara</groupId>
+        <artifactId>ruoyi-modules</artifactId>
+        <version>${revision}</version>
+    </parent>
+
 
-    <groupId>org.dromara</groupId>
     <artifactId>ruoyi-dataManagement</artifactId>
-    <version>5.3.0</version>
 
-    <properties>
-        <maven.compiler.source>17</maven.compiler.source>
-        <maven.compiler.target>17</maven.compiler.target>
-        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
-    </properties>
+    <description>
+        demo模块
+    </description>
+
     <dependencies>
         <dependency>
-            <groupId>org.projectlombok</groupId>
-            <artifactId>lombok</artifactId>
-            <version>1.18.36</version>
-            <scope>provided</scope>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-core</artifactId>
         </dependency>
+
         <dependency>
-            <groupId>com.baomidou</groupId>
-            <artifactId>mybatis-plus-annotation</artifactId>
-            <version>3.5.10</version>
-            <scope>compile</scope>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-doc</artifactId>
         </dependency>
+
         <dependency>
             <groupId>org.dromara</groupId>
-            <artifactId>ruoyi-common-tenant</artifactId>
-            <version>${version}</version>
-            <scope>compile</scope>
+            <artifactId>ruoyi-common-sms</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-mail</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-redis</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-idempotent</artifactId>
         </dependency>
 
         <dependency>
             <groupId>org.dromara</groupId>
             <artifactId>ruoyi-common-mybatis</artifactId>
-            <version>5.3.0</version>
-            <scope>compile</scope>
         </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-log</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-excel</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-security</artifactId>
+        </dependency>
+
         <dependency>
             <groupId>org.dromara</groupId>
             <artifactId>ruoyi-common-web</artifactId>
-            <version>5.3.0</version>
-            <scope>compile</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-ratelimiter</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-translation</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-sensitive</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-encrypt</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-tenant</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.dromara</groupId>
+            <artifactId>ruoyi-common-websocket</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.projectlombok</groupId>
+            <artifactId>lombok</artifactId>
+            <scope>provided</scope>
         </dependency>
 
 

+ 12 - 0
ruoyi-modules/ruoyi-dataManagement/src/main/java/org/dromara/dataManagement/controller/SupplierController.java

@@ -3,7 +3,12 @@ package org.dromara.dataManagement.controller;
 
 import cn.dev33.satoken.annotation.SaIgnore;
 import lombok.RequiredArgsConstructor;
+import org.dromara.common.mybatis.core.page.PageQuery;
+import org.dromara.common.mybatis.core.page.TableDataInfo;
+import org.dromara.dataManagement.domain.bo.SupplierBo;
+import org.dromara.dataManagement.domain.vo.SupplierVo;
 import org.dromara.dataManagement.service.SupplierService;
+import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 
@@ -16,5 +21,12 @@ public class SupplierController {
 
     private final SupplierService supplierService;
 
+    /**
+     * 分页条件查询供应商信息
+     */
+    @GetMapping("/PageList")
+    public TableDataInfo<SupplierVo> selectPageSupplierList(SupplierBo supplierBo, PageQuery pageQuery) {
+        return supplierService.selectPageSupplierList(supplierBo, pageQuery);
+    }
 
 }

+ 58 - 1
ruoyi-modules/ruoyi-dataManagement/src/main/java/org/dromara/dataManagement/domain/Supplier.java

@@ -7,7 +7,64 @@ import org.dromara.common.tenant.core.TenantEntity;
 
 @Data
 @EqualsAndHashCode(callSuper = true)
-@TableName("")
+@TableName("fa_kuyou_suppliers")
 public class Supplier extends TenantEntity {
 
+    private Integer id;
+
+    /**
+     * 供应商类别
+     */
+    private int supplyertypeId;
+
+    /**
+     * 供应商编号
+     */
+    private String supplyerCode;
+
+    /**
+     * 供应商名称
+     */
+    private String supplyerName;
+
+    /**
+     * 首要联系人
+     */
+    private String firstConnectName;
+
+    /**
+     * 首要联系人手机号
+     */
+    private String firstConnectMobile;
+
+    /**
+     * 首要联系人座机号
+     */
+    private String firstConnectPhone;
+
+    /**
+     * 首要联系人QQ/微信/Email
+     */
+    private String qqWxEmail;
+
+    /**
+     * 联系地址
+     */
+    private String connectAddress;
+
+    /**
+     * 备注
+     */
+    private String note;
+
+    /**
+     * 应付余额
+     */
+    private double needGiveAccount;
+
+    /**
+     * 状态
+     */
+    private String status;
+
 }

+ 56 - 0
ruoyi-modules/ruoyi-dataManagement/src/main/java/org/dromara/dataManagement/domain/bo/SupplierBo.java

@@ -11,4 +11,60 @@ import org.dromara.dataManagement.domain.Supplier;
 @EqualsAndHashCode(callSuper = true)
 @AutoMapper(target = Supplier.class, reverseConvertGenerate = false)
 public class SupplierBo extends BaseEntity {
+
+    /**
+     * 供应商类别
+     */
+    private int supplyertypeId;
+
+    /**
+     * 供应商编号
+     */
+    private String supplyerCode;
+
+    /**
+     * 供应商名称
+     */
+    private String supplyerName;
+
+    /**
+     * 首要联系人
+     */
+    private String firstConnectName;
+
+    /**
+     * 首要联系人手机号
+     */
+    private String firstConnectMobile;
+
+    /**
+     * 首要联系人座机号
+     */
+    private String firstConnectPhone;
+
+    /**
+     * 首要联系人QQ/微信/Email
+     */
+    private String qqWxEmail;
+
+    /**
+     * 联系地址
+     */
+    private String connectAddress;
+
+    /**
+     * 备注
+     */
+    private String note;
+
+    /**
+     * 应付余额
+     */
+    private double needGiveAccount;
+
+    /**
+     * 状态
+     */
+    private String status;
+
 }

+ 58 - 0
ruoyi-modules/ruoyi-dataManagement/src/main/java/org/dromara/dataManagement/domain/vo/SupplierVo.java

@@ -11,4 +11,62 @@ import org.dromara.dataManagement.domain.Supplier;
 @EqualsAndHashCode(callSuper = true)
 @AutoMapper(target = Supplier.class)
 public class SupplierVo extends BaseEntity {
+
+    private Integer id;
+
+    /**
+     * 供应商类别
+     */
+    private int supplyertypeId;
+
+    /**
+     * 供应商编号
+     */
+    private String supplyerCode;
+
+    /**
+     * 供应商名称
+     */
+    private String supplyerName;
+
+    /**
+     * 首要联系人
+     */
+    private String firstConnectName;
+
+    /**
+     * 首要联系人手机号
+     */
+    private String firstConnectMobile;
+
+    /**
+     * 首要联系人座机号
+     */
+    private String firstConnectPhone;
+
+    /**
+     * 首要联系人QQ/微信/Email
+     */
+    private String qqWxEmail;
+
+    /**
+     * 联系地址
+     */
+    private String connectAddress;
+
+    /**
+     * 备注
+     */
+    private String note;
+
+    /**
+     * 应付余额
+     */
+    private double needGiveAccount;
+
+    /**
+     * 状态
+     */
+    private String status;
+
 }

+ 4 - 1
ruoyi-modules/ruoyi-dataManagement/src/main/java/org/dromara/dataManagement/mapper/SupplierMapper.java

@@ -2,7 +2,10 @@ package org.dromara.dataManagement.mapper;
 
 
 import org.apache.ibatis.annotations.Mapper;
+import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
+import org.dromara.dataManagement.domain.Supplier;
+import org.dromara.dataManagement.domain.vo.SupplierVo;
 
 @Mapper
-public class SupplierMapper {
+public interface SupplierMapper extends BaseMapperPlus<Supplier, SupplierVo> {
 }

+ 1 - 1
ruoyi-modules/ruoyi-dataManagement/src/main/java/org/dromara/dataManagement/mapper/WorkShopMapper.java

@@ -1,9 +1,9 @@
 package org.dromara.dataManagement.mapper;
 
+import org.apache.ibatis.annotations.Mapper;
 import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
 import org.dromara.dataManagement.domain.WorkShop;
 import org.dromara.dataManagement.domain.vo.WorkShopVo;
-import org.mapstruct.Mapper;
 
 @Mapper
 public interface WorkShopMapper extends BaseMapperPlus<WorkShop, WorkShopVo> {

+ 8 - 0
ruoyi-modules/ruoyi-dataManagement/src/main/java/org/dromara/dataManagement/service/SupplierService.java

@@ -1,5 +1,13 @@
 package org.dromara.dataManagement.service;
 
 
+import org.dromara.common.mybatis.core.page.PageQuery;
+import org.dromara.common.mybatis.core.page.TableDataInfo;
+import org.dromara.dataManagement.domain.bo.SupplierBo;
+import org.dromara.dataManagement.domain.vo.SupplierVo;
+
 public interface SupplierService {
+
+    TableDataInfo<SupplierVo> selectPageSupplierList(SupplierBo supplierBo, PageQuery pageQuery);
+
 }

+ 26 - 0
ruoyi-modules/ruoyi-dataManagement/src/main/java/org/dromara/dataManagement/service/impl/SupplierServiceImpl.java

@@ -1,11 +1,37 @@
 package org.dromara.dataManagement.service.impl;
 
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.toolkit.StringUtils;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import lombok.RequiredArgsConstructor;
+import org.dromara.common.core.utils.MapstructUtils;
+import org.dromara.common.mybatis.core.page.PageQuery;
+import org.dromara.common.mybatis.core.page.TableDataInfo;
+import org.dromara.dataManagement.domain.Supplier;
+import org.dromara.dataManagement.domain.bo.SupplierBo;
+import org.dromara.dataManagement.domain.vo.SupplierVo;
+import org.dromara.dataManagement.mapper.SupplierMapper;
 import org.dromara.dataManagement.service.SupplierService;
 import org.springframework.stereotype.Service;
 
+import java.util.List;
+
 
 @Service
 @RequiredArgsConstructor
 public class SupplierServiceImpl implements SupplierService {
+
+    private final SupplierMapper supplierMapper;
+
+    @Override
+    public TableDataInfo<SupplierVo> selectPageSupplierList(SupplierBo supplierBo, PageQuery pageQuery) {
+        QueryWrapper<Supplier> qw = new QueryWrapper<>();
+        qw.eq(StringUtils.isNotBlank(supplierBo.getSupplyerCode()), "supplyer_code", supplierBo.getSupplyerCode());
+        qw.eq(StringUtils.isNotBlank(supplierBo.getSupplyerName()), "supplyer_name", supplierBo.getSupplyerName());
+        qw.eq(StringUtils.isNotBlank(supplierBo.getStatus()), "status", supplierBo.getStatus());
+//        Supplier supplier = MapstructUtils.convert(supplierBo, Supplier.class);
+        List<Supplier> page = supplierMapper.selectList(pageQuery.build(), qw);
+        List<SupplierVo> supplierVoList = MapstructUtils.convert(page, SupplierVo.class);
+        return TableDataInfo.build(supplierVoList);
+    }
 }