浏览代码

客户添加标签,跟进记录

yzc 2 年之前
父节点
当前提交
fc1dfa391a

+ 17 - 0
code/src/test/java/CustomerDataSource.java

@@ -0,0 +1,17 @@
+import fly.generator.GeneratorApplication;
+
+public class CustomerDataSource {
+
+    public static void main(String[] args) {
+        GeneratorApplication.builder()
+                .url("jdbc:mysql://36.134.91.96:17330/bytesailing_customer?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true")
+                .username("fjhx2012mysql")
+                .password("3PN-Mzn#vnP&q6d")
+                .port(9989)
+                .module("hx-customer")
+                .parent("com.fjhx.customer")
+                .superServiceClass("com.ruoyi.common.core.service.BaseService")
+                .build();
+    }
+
+}

+ 68 - 0
hx-customer/src/main/java/com/fjhx/customer/controller/customer/CustomerFollowRecordsController.java

@@ -0,0 +1,68 @@
+package com.fjhx.customer.controller.customer;
+
+import org.springframework.web.bind.annotation.*;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.fjhx.customer.entity.customer.vo.CustomerFollowRecordsVo;
+import com.fjhx.customer.entity.customer.dto.CustomerFollowRecordsSelectDto;
+import com.fjhx.customer.entity.customer.dto.CustomerFollowRecordsDto;
+import com.ruoyi.common.core.domain.BaseSelectDto;
+import com.fjhx.customer.service.customer.CustomerFollowRecordsService;
+import org.springframework.beans.factory.annotation.Autowired;
+
+
+/**
+ * <p>
+ * 客户跟进记录 前端控制器
+ * </p>
+ *
+ * @author 
+ * @since 2023-05-05
+ */
+@RestController
+@RequestMapping("/customerFollowRecords")
+public class CustomerFollowRecordsController {
+
+    @Autowired
+    private CustomerFollowRecordsService customerFollowRecordsService;
+
+    /**
+     * 客户跟进记录分页
+     */
+    @PostMapping("/page")
+    public Page<CustomerFollowRecordsVo> page(@RequestBody CustomerFollowRecordsSelectDto dto) {
+        return customerFollowRecordsService.getPage(dto);
+    }
+
+    /**
+     * 客户跟进记录明细
+     */
+    @PostMapping("/detail")
+    public CustomerFollowRecordsVo detail(@RequestBody BaseSelectDto dto) {
+        return customerFollowRecordsService.detail(dto.getId());
+    }
+
+    /**
+     * 客户跟进记录新增
+     */
+    @PostMapping("/add")
+    public void add(@RequestBody CustomerFollowRecordsDto customerFollowRecordsDto) {
+        customerFollowRecordsService.add(customerFollowRecordsDto);
+    }
+
+    /**
+     * 客户跟进记录编辑
+     */
+    @PostMapping("/edit")
+    public void edit(@RequestBody CustomerFollowRecordsDto customerFollowRecordsDto) {
+        customerFollowRecordsService.edit(customerFollowRecordsDto);
+    }
+
+    /**
+     * 客户跟进记录删除
+     */
+    @PostMapping("/delete")
+    public void delete(@RequestBody BaseSelectDto dto) {
+        customerFollowRecordsService.delete(dto.getId());
+    }
+
+}

+ 17 - 0
hx-customer/src/main/java/com/fjhx/customer/entity/customer/dto/CustomerFollowRecordsDto.java

@@ -0,0 +1,17 @@
+package com.fjhx.customer.entity.customer.dto;
+
+import com.fjhx.customer.entity.customer.po.CustomerFollowRecords;
+import lombok.Getter;
+import lombok.Setter;
+
+/**
+ * 客户跟进记录新增编辑入参实体
+ *
+ * @author 
+ * @since 2023-05-05
+ */
+@Getter
+@Setter
+public class CustomerFollowRecordsDto extends CustomerFollowRecords {
+
+}

+ 17 - 0
hx-customer/src/main/java/com/fjhx/customer/entity/customer/dto/CustomerFollowRecordsSelectDto.java

@@ -0,0 +1,17 @@
+package com.fjhx.customer.entity.customer.dto;
+
+import com.ruoyi.common.core.domain.BaseSelectDto;
+import lombok.Getter;
+import lombok.Setter;
+
+/**
+ * 客户跟进记录列表查询入参实体
+ *
+ * @author 
+ * @since 2023-05-05
+ */
+@Getter
+@Setter
+public class CustomerFollowRecordsSelectDto extends BaseSelectDto {
+
+}

+ 5 - 1
hx-customer/src/main/java/com/fjhx/customer/entity/customer/po/Customer.java

@@ -2,7 +2,6 @@ package com.fjhx.customer.entity.customer.po;
 
 import com.baomidou.mybatisplus.annotation.TableName;
 import com.ruoyi.common.core.domain.BasePo;
-import java.util.Date;
 import lombok.Getter;
 import lombok.Setter;
 
@@ -74,4 +73,9 @@ public class Customer extends BasePo {
      */
     private String userId;
 
+    /**
+     * 客户标签
+     */
+    private String tag;
+
 }

+ 37 - 0
hx-customer/src/main/java/com/fjhx/customer/entity/customer/po/CustomerFollowRecords.java

@@ -0,0 +1,37 @@
+package com.fjhx.customer.entity.customer.po;
+
+import com.ruoyi.common.core.domain.BasePo;
+import com.baomidou.mybatisplus.annotation.TableName;
+import java.util.Date;
+import lombok.Getter;
+import lombok.Setter;
+
+/**
+ * <p>
+ * 客户跟进记录
+ * </p>
+ *
+ * @author 
+ * @since 2023-05-05
+ */
+@Getter
+@Setter
+@TableName("customer_follow_records")
+public class CustomerFollowRecords extends BasePo {
+
+    /**
+     * 客户id
+     */
+    private Long customerId;
+
+    /**
+     * 跟进日期
+     */
+    private Date date;
+
+    /**
+     * 跟进内容
+     */
+    private String content;
+
+}

+ 17 - 0
hx-customer/src/main/java/com/fjhx/customer/entity/customer/vo/CustomerFollowRecordsVo.java

@@ -0,0 +1,17 @@
+package com.fjhx.customer.entity.customer.vo;
+
+import com.fjhx.customer.entity.customer.po.CustomerFollowRecords;
+import lombok.Getter;
+import lombok.Setter;
+
+/**
+ * 客户跟进记录列表查询返回值实体
+ *
+ * @author 
+ * @since 2023-05-05
+ */
+@Getter
+@Setter
+public class CustomerFollowRecordsVo extends CustomerFollowRecords {
+
+}

+ 6 - 0
hx-customer/src/main/java/com/fjhx/customer/entity/customer/vo/CustomerVo.java

@@ -2,6 +2,7 @@ package com.fjhx.customer.entity.customer.vo;
 
 import com.fjhx.area.service.ISetAreaName;
 import com.fjhx.customer.entity.customer.po.Customer;
+import com.fjhx.customer.entity.customer.po.CustomerFollowRecords;
 import com.fjhx.customer.entity.customer.po.CustomerUser;
 import lombok.Getter;
 import lombok.Setter;
@@ -42,5 +43,10 @@ public class CustomerVo extends Customer implements ISetAreaName {
      */
     private String time;
 
+    /**
+     * 客户跟进记录
+     */
+    private List<CustomerFollowRecords> customerFollowRecordsList;
+
 
 }

+ 26 - 0
hx-customer/src/main/java/com/fjhx/customer/mapper/customer/CustomerFollowRecordsMapper.java

@@ -0,0 +1,26 @@
+package com.fjhx.customer.mapper.customer;
+
+import com.fjhx.customer.entity.customer.po.CustomerFollowRecords;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.fjhx.customer.entity.customer.vo.CustomerFollowRecordsVo;
+import com.ruoyi.common.utils.wrapper.IWrapper;
+import org.apache.ibatis.annotations.Param;
+
+
+/**
+ * <p>
+ * 客户跟进记录 Mapper 接口
+ * </p>
+ *
+ * @author 
+ * @since 2023-05-05
+ */
+public interface CustomerFollowRecordsMapper extends BaseMapper<CustomerFollowRecords> {
+
+    /**
+     * 客户跟进记录分页
+     */
+    Page<CustomerFollowRecordsVo> getPage(@Param("page") Page<Object> page, @Param("ew") IWrapper<CustomerFollowRecords> wrapper);
+
+}

+ 46 - 0
hx-customer/src/main/java/com/fjhx/customer/service/customer/CustomerFollowRecordsService.java

@@ -0,0 +1,46 @@
+package com.fjhx.customer.service.customer;
+
+import com.fjhx.customer.entity.customer.po.CustomerFollowRecords;
+import com.ruoyi.common.core.service.BaseService;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.fjhx.customer.entity.customer.vo.CustomerFollowRecordsVo;
+import com.fjhx.customer.entity.customer.dto.CustomerFollowRecordsSelectDto;
+import com.fjhx.customer.entity.customer.dto.CustomerFollowRecordsDto;
+
+
+/**
+ * <p>
+ * 客户跟进记录 服务类
+ * </p>
+ *
+ * @author 
+ * @since 2023-05-05
+ */
+public interface CustomerFollowRecordsService extends BaseService<CustomerFollowRecords> {
+
+    /**
+     * 客户跟进记录分页
+     */
+    Page<CustomerFollowRecordsVo> getPage(CustomerFollowRecordsSelectDto dto);
+
+    /**
+     * 客户跟进记录明细
+     */
+    CustomerFollowRecordsVo detail(Long id);
+
+    /**
+     * 客户跟进记录新增
+     */
+    void add(CustomerFollowRecordsDto customerFollowRecordsDto);
+
+    /**
+     * 客户跟进记录编辑
+     */
+    void edit(CustomerFollowRecordsDto customerFollowRecordsDto);
+
+    /**
+     * 客户跟进记录删除
+     */
+    void delete(Long id);
+
+}

+ 57 - 0
hx-customer/src/main/java/com/fjhx/customer/service/customer/impl/CustomerFollowRecordsServiceImpl.java

@@ -0,0 +1,57 @@
+package com.fjhx.customer.service.customer.impl;
+
+import com.fjhx.customer.entity.customer.po.CustomerFollowRecords;
+import com.fjhx.customer.mapper.customer.CustomerFollowRecordsMapper;
+import com.fjhx.customer.service.customer.CustomerFollowRecordsService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.fjhx.customer.entity.customer.vo.CustomerFollowRecordsVo;
+import com.fjhx.customer.entity.customer.dto.CustomerFollowRecordsSelectDto;
+import com.ruoyi.common.utils.wrapper.IWrapper;
+import com.fjhx.customer.entity.customer.dto.CustomerFollowRecordsDto;
+import cn.hutool.core.bean.BeanUtil;
+
+
+/**
+ * <p>
+ * 客户跟进记录 服务实现类
+ * </p>
+ *
+ * @author 
+ * @since 2023-05-05
+ */
+@Service
+public class CustomerFollowRecordsServiceImpl extends ServiceImpl<CustomerFollowRecordsMapper, CustomerFollowRecords> implements CustomerFollowRecordsService {
+
+    @Override
+    public Page<CustomerFollowRecordsVo> getPage(CustomerFollowRecordsSelectDto dto) {
+        IWrapper<CustomerFollowRecords> wrapper = getWrapper();
+        wrapper.orderByDesc("cfr", CustomerFollowRecords::getId);
+        Page<CustomerFollowRecordsVo> page = this.baseMapper.getPage(dto.getPage(), wrapper);
+        return page;
+    }
+
+    @Override
+    public CustomerFollowRecordsVo detail(Long id) {
+        CustomerFollowRecords CustomerFollowRecords = this.getById(id);
+        CustomerFollowRecordsVo result = BeanUtil.toBean(CustomerFollowRecords, CustomerFollowRecordsVo.class);
+        return result;
+    }
+
+    @Override
+    public void add(CustomerFollowRecordsDto customerFollowRecordsDto) {
+        this.save(customerFollowRecordsDto);
+    }
+
+    @Override
+    public void edit(CustomerFollowRecordsDto customerFollowRecordsDto) {
+        this.updateById(customerFollowRecordsDto);
+    }
+
+    @Override
+    public void delete(Long id) {
+        this.removeById(id);
+    }
+
+}

+ 54 - 34
hx-customer/src/main/java/com/fjhx/customer/service/customer/impl/CustomerServiceImpl.java

@@ -1,38 +1,32 @@
 package com.fjhx.customer.service.customer.impl;
 
-import cn.hutool.core.date.DateUtil;
-import cn.hutool.core.util.ArrayUtil;
+import cn.hutool.core.bean.BeanUtil;
 import cn.hutool.core.util.ObjectUtil;
-import com.baomidou.dynamic.datasource.toolkit.DynamicDataSourceContextHolder;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.fjhx.area.utils.AreaUtil;
-import com.fjhx.common.constant.SourceConstant;
-import com.fjhx.customer.entity.customer.dto.CustomerUserDto;
+import com.fjhx.customer.entity.customer.dto.CustomerDto;
+import com.fjhx.customer.entity.customer.dto.CustomerSelectDto;
 import com.fjhx.customer.entity.customer.po.Customer;
+import com.fjhx.customer.entity.customer.po.CustomerFollowRecords;
 import com.fjhx.customer.entity.customer.po.CustomerUser;
+import com.fjhx.customer.entity.customer.vo.CustomerVo;
 import com.fjhx.customer.mapper.customer.CustomerMapper;
+import com.fjhx.customer.service.customer.CustomerFollowRecordsService;
 import com.fjhx.customer.service.customer.CustomerService;
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.fjhx.customer.service.customer.CustomerUserService;
 import com.fjhx.customer.utils.code.CodeEnum;
 import com.obs.services.internal.ServiceException;
 import com.ruoyi.common.utils.SecurityUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
-import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
-import com.fjhx.customer.entity.customer.vo.CustomerVo;
-import com.fjhx.customer.entity.customer.dto.CustomerSelectDto;
-import com.ruoyi.common.utils.wrapper.IWrapper;
-import com.fjhx.customer.entity.customer.dto.CustomerDto;
-import cn.hutool.core.bean.BeanUtil;
 import org.springframework.transaction.annotation.Transactional;
 
-import java.math.BigDecimal;
-import java.rmi.ServerException;
-import java.security.Security;
-import java.util.*;
+import java.util.List;
+import java.util.Map;
 import java.util.stream.Collectors;
 
 /**
@@ -47,31 +41,33 @@ import java.util.stream.Collectors;
 public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> implements CustomerService {
     @Autowired
     private CustomerUserService customerUserService;
-
+    @Autowired
+    private CustomerFollowRecordsService customerFollowRecordsService;
 
 
     /**
      * 查询客户的列表
+     *
      * @param dto
      * @return
      */
     @Override
     public Page<CustomerVo> getPage(CustomerSelectDto dto) {
         LambdaQueryWrapper<Customer> wrapper = Wrappers.<Customer>lambdaQuery();
-        wrapper.eq(ObjectUtil.isNotEmpty(dto.getSource()),Customer::getSource,dto.getSource());
-        wrapper.eq(ObjectUtil.isNotEmpty(dto.getStatus()),Customer::getStatus,dto.getStatus());
+        wrapper.eq(ObjectUtil.isNotEmpty(dto.getSource()), Customer::getSource, dto.getSource());
+        wrapper.eq(ObjectUtil.isNotEmpty(dto.getStatus()), Customer::getStatus, dto.getStatus());
         //客户状态(0:公海客户  1:私海客户)(业务员ID为null为公海客户,业务员ID不为null为私海客户)
-        if (ObjectUtil.isNotEmpty(dto.getType())){
+        if (ObjectUtil.isNotEmpty(dto.getType())) {
             //私海客户查询
-            if (dto.getType().equals("1")){
+            if (dto.getType().equals("1")) {
                 wrapper.isNotNull(Customer::getUserId);
-            }else if (dto.getType().equals("0")){
-                wrapper.and(wrapper1 -> wrapper1.isNull(Customer::getUserId).or().eq(Customer::getUserId,""));
+            } else if (dto.getType().equals("0")) {
+                wrapper.and(wrapper1 -> wrapper1.isNull(Customer::getUserId).or().eq(Customer::getUserId, ""));
             }
         }
-        if (ObjectUtil.isNotEmpty(dto.getKeyword())){
+        if (ObjectUtil.isNotEmpty(dto.getKeyword())) {
             //查询客户名称或者客户编码
-            wrapper.and(wrapper1 -> wrapper1.like(Customer::getName,dto.getKeyword()).or().eq(Customer::getCode,dto.getKeyword()));
+            wrapper.and(wrapper1 -> wrapper1.like(Customer::getName, dto.getKeyword()).or().eq(Customer::getCode, dto.getKeyword()));
         }
         wrapper.orderByDesc(Customer::getCreateTime);
         Page<CustomerVo> page = this.baseMapper.getPage(dto.getPage(), wrapper);
@@ -79,11 +75,21 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
         //复制城市信息
         List<CustomerVo> records = page.getRecords();
         AreaUtil.setAreaName(records);
+        //赋值客户跟进记录
+        List<Long> customerIds = records.stream().map(Customer::getId).collect(Collectors.toList());
+        if (ObjectUtil.isNotEmpty(customerIds)) {
+            Map<Long, List<CustomerFollowRecords>> longListMap = customerFollowRecordsService.mapKGroup(CustomerFollowRecords::getCustomerId,
+                    q -> q.in(CustomerFollowRecords::getCustomerId, customerIds));
+            for (CustomerVo record : records) {
+                record.setCustomerFollowRecordsList(longListMap.get(record.getId()));
+            }
+        }
         return page;
     }
 
     /**
      * 查询客户的详情
+     *
      * @param id
      * @return
      */
@@ -92,7 +98,7 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
         //查询客户表的信息
         Customer Customer = this.getById(id);
         CustomerVo result = BeanUtil.toBean(Customer, CustomerVo.class);
-        if (ObjectUtil.isEmpty(result)){
+        if (ObjectUtil.isEmpty(result)) {
             throw new ServiceException("没有找到该用户信息");
         }
         //查询客户-联系人表的信息
@@ -105,6 +111,7 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
 
     /**
      * 添加客户表的数据
+     *
      * @param customerDto
      */
     @Override
@@ -118,6 +125,7 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
 
     /**
      * 修改客户表的数据
+     *
      * @param customerDto
      */
     @Transactional(rollbackFor = {Exception.class})
@@ -126,13 +134,14 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
         //修改客户表的信息
         this.updateById(customerDto);
         //删除客户-用户表的信息
-        customerUserService.remove(Wrappers.<CustomerUser>lambdaQuery().eq(CustomerUser::getCustomerId,customerDto.getId()));
+        customerUserService.remove(Wrappers.<CustomerUser>lambdaQuery().eq(CustomerUser::getCustomerId, customerDto.getId()));
         //添加客户-联系人表的信息
         saveCustomerUse(customerDto);
     }
 
     /**
      * 删除客户表的数据
+     *
      * @param
      */
     @Override
@@ -141,7 +150,7 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
         //删除客户表的数据
         this.removeById(id);
         //删除客户-联系人表的数据
-        customerUserService.remove(Wrappers.<CustomerUser>lambdaQuery().eq(CustomerUser::getCustomerId,id));
+        customerUserService.remove(Wrappers.<CustomerUser>lambdaQuery().eq(CustomerUser::getCustomerId, id));
     }
 
     /**
@@ -150,24 +159,34 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
     @Override
     public Page<CustomerVo> privateSeaPage(CustomerSelectDto dto) {
         LambdaQueryWrapper<Customer> wrapper = Wrappers.<Customer>lambdaQuery();
-        wrapper.eq(ObjectUtil.isNotEmpty(dto.getSource()),Customer::getSource,dto.getSource());
-        wrapper.eq(ObjectUtil.isNotEmpty(dto.getStatus()),Customer::getStatus,dto.getStatus());
-        if (ObjectUtil.isNotEmpty(dto.getKeyword())){
+        wrapper.eq(ObjectUtil.isNotEmpty(dto.getSource()), Customer::getSource, dto.getSource());
+        wrapper.eq(ObjectUtil.isNotEmpty(dto.getStatus()), Customer::getStatus, dto.getStatus());
+        if (ObjectUtil.isNotEmpty(dto.getKeyword())) {
             //查询客户名称或者客户编码
-            wrapper.and(wrapper1 -> wrapper1.like(Customer::getName,dto.getKeyword()).or().eq(Customer::getCode,dto.getKeyword()));
+            wrapper.and(wrapper1 -> wrapper1.like(Customer::getName, dto.getKeyword()).or().eq(Customer::getCode, dto.getKeyword()));
         }
         //添加权限(自己看自己)
         wrapper.eq(Customer::getUserId, SecurityUtils.getUserId());
         wrapper.orderByDesc(Customer::getCreateTime);
-        Page<CustomerVo> page =baseMapper.getPage(dto.getPage(), wrapper);
+        Page<CustomerVo> page = baseMapper.getPage(dto.getPage(), wrapper);
         //复制城市信息
         List<CustomerVo> records = page.getRecords();
         AreaUtil.setAreaName(records);
+        //赋值客户跟进记录
+        List<Long> customerIds = records.stream().map(Customer::getId).collect(Collectors.toList());
+        if (ObjectUtil.isNotEmpty(customerIds)) {
+            Map<Long, List<CustomerFollowRecords>> longListMap = customerFollowRecordsService.mapKGroup(CustomerFollowRecords::getCustomerId,
+                    q -> q.in(CustomerFollowRecords::getCustomerId, customerIds));
+            for (CustomerVo record : records) {
+                record.setCustomerFollowRecordsList(longListMap.get(record.getId()));
+            }
+        }
         return page;
     }
 
     /**
      * 来源存量(客户分析)
+     *
      * @param query
      * @return
      */
@@ -178,6 +197,7 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
 
     /**
      * 来源增量(客户分析)
+     *
      * @param query
      * @return
      */
@@ -188,7 +208,7 @@ public class CustomerServiceImpl extends ServiceImpl<CustomerMapper, Customer> i
 
 
     //添加客户用户表的信息
-    private void  saveCustomerUse(CustomerDto customerDto){
+    private void saveCustomerUse(CustomerDto customerDto) {
         List<CustomerUser> customerUserDtoList = customerDto.getCustomerUserList();
         customerUserDtoList.forEach(customerUserDto -> customerUserDto.setCustomerId(customerDto.getId()));
         customerUserService.saveBatch(customerUserDtoList);

+ 18 - 0
hx-customer/src/main/resources/mapper/customer/CustomerFollowRecordsMapper.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.fjhx.customer.mapper.customer.CustomerFollowRecordsMapper">
+    <select id="getPage" resultType="com.fjhx.customer.entity.customer.vo.CustomerFollowRecordsVo">
+        select
+            cfr.id,
+            cfr.customer_id,
+            cfr.date,
+            cfr.content,
+            cfr.create_user,
+            cfr.create_time,
+            cfr.update_user,
+            cfr.update_time
+        from customer_follow_records cfr
+            ${ew.customSqlSegment}
+    </select>
+
+</mapper>

+ 4 - 2
hx-customer/src/main/resources/mapper/customer/CustomerMapper.xml

@@ -18,7 +18,8 @@
             c.create_user,
             c.create_time,
             c.update_user,
-            c.update_time
+            c.update_time,
+            c.tag
         from customer c
             ${ew.customSqlSegment}
     </select>
@@ -40,7 +41,8 @@
             c.create_user,
             c.create_time,
             c.update_user,
-            c.update_time
+            c.update_time,
+            c.tag
         from customer c
             ${ew.customSqlSegment}
     </select>

+ 1 - 0
hx-wms/src/main/resources/mapper/stock/StockJournalMapper.xml

@@ -32,6 +32,7 @@
         SELECT
             sj.id,
             sj.type,
+            sj.warehouse_id,
             w.`name` warehouseName,
             sjd.id stockJournalDetailsId,
             sjd.product_id,