调整
This commit is contained in:
parent
38422ce5c2
commit
e5e48c7f2c
@ -1,14 +1,12 @@
|
||||
package cn.iocoder.yudao.module.custom.vo;
|
||||
|
||||
import cn.iocoder.yudao.module.custom.entity.CarMain;
|
||||
import cn.iocoder.yudao.module.custom.entity.CustomerItem;
|
||||
import cn.iocoder.yudao.module.custom.entity.CustomerMain;
|
||||
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.*;
|
||||
import java.util.*;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
import java.time.LocalDateTime;
|
||||
import com.alibaba.excel.annotation.*;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Schema(description = "管理后台 - 客户管理 Response VO")
|
||||
@Data
|
||||
@ -23,5 +21,7 @@ public class CustomerMainRespVO extends CustomerMain {
|
||||
List<CustomerItem> itemList;
|
||||
/**客户绑定车辆信息*/
|
||||
List<CarMainRespVO> carList;
|
||||
/**经办人信息集合*/
|
||||
List<CustomerMain> attnList;
|
||||
|
||||
}
|
@ -9,7 +9,14 @@
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
<select id="selectListPage" resultType="cn.iocoder.yudao.module.custom.vo.CustomerMainRespVO">
|
||||
<resultMap id="CustomerMainMap" type="cn.iocoder.yudao.module.custom.vo.CustomerMainRespVO">
|
||||
<id column="id" property="id"/>
|
||||
<collection select="getAttn" property="attnList" javaType="list"
|
||||
column="deptCode"
|
||||
ofType="cn.iocoder.yudao.module.custom.entity.CustomerMain">
|
||||
</collection>
|
||||
</resultMap>
|
||||
<select id="selectListPage" resultMap="CustomerMainMap">
|
||||
SELECT
|
||||
main.id AS id,
|
||||
main.user_id AS userId,
|
||||
@ -47,4 +54,28 @@
|
||||
GROUP BY main.id
|
||||
ORDER BY main.create_time DESC
|
||||
</select>
|
||||
<select id="getAttn" resultType="cn.iocoder.yudao.module.custom.entity.CustomerMain">
|
||||
SELECT
|
||||
main.id AS id,
|
||||
main.user_id AS userId,
|
||||
main.type_code AS typeCode,
|
||||
main.dept_code AS deptCode,
|
||||
main.cus_name AS cusName,
|
||||
main.phone_number AS phoneNumber,
|
||||
main.birthday AS birthday,
|
||||
main.address AS address,
|
||||
main.sex AS sex,
|
||||
main.id_card AS idCard,
|
||||
main.id_card_image AS idCardImage,
|
||||
main.data_from AS dataFrom,
|
||||
main.near_do_time AS nearDoTime,
|
||||
main.near_do_content AS nearDoContent,
|
||||
main.inviter AS inviter,
|
||||
main.inviter_type AS inviterType,
|
||||
main.status AS status
|
||||
FROM
|
||||
base_customer_main main
|
||||
where main.dept_code = #{deptCode} and main.deleted = 0 and main.type_code = '04'
|
||||
ORDER BY main.create_time DESC
|
||||
</select>
|
||||
</mapper>
|
Loading…
Reference in New Issue
Block a user