cuijian
2025-06-06 35d9446131124e12616c7b6b9dfd79e23d20e1c9
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?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="org.jeecg.modules.tms.mapper.InStoreDetailMapper">
 
    <select id="findPageList" resultType="map" parameterType="String">
        SELECT
            t.id,
            t.tool_id onlyCode,
            t.in_storehouse_type inStorehouseType,
            t10.location_code locationCode,
            t.in_number inNumber,
            t.in_storehouse_id inStorehouseId,
            t.inbound_time inboundTime,
            t.create_by createBy,
            t.create_time createTime,
            t.update_by updateBy,
            t.update_time updateTime,
            t1.tool_code toolCode,
            t1.chinese_name chineseName,
            t1.tool_model toolModel,
            t2.classify_id classifyNum,
            t3.inbound_num inboundNum,
            t3.application_reason applicationReason,
            t3.approval_date approvalDate,
            t3.approval_opinion approvalOpinion,
            t4.item_text operateType,
            t5.realname handler,
            t6.realname reviewer,
            t7.item_text inStatus,
            t8.item_text orderStatus,
            t9.item_text inStorehouseTypeName
        FROM tms_in_store_detail t
                 LEFT JOIN tms_base_tools t1 on t.tool_code = t1.id
                 LEFT JOIN tms_tools_classify t2 on t2.id = t1.classify_id
                 LEFT JOIN tms_inbound_order t3 on t3.id = t.in_storehouse_id
                 LEFT JOIN (select * from v_sys_dict where dict_code='inbound_operate_type') t4 on t4.item_value = t.operate_type
                 LEFT JOIN sys_user t5 on t5.username = t3.handler
                 LEFT JOIN sys_user t6 on t6.username = t3.reviewer
                 LEFT JOIN (select * from v_sys_dict where dict_code='in_status') t7 on t7.item_value = t3.in_status
                 LEFT JOIN (select * from v_sys_dict where dict_code='in_bill_status') t8 on t8.item_value = t3.order_status
                 left join (select * from v_sys_dict where dict_code='in_storehouse_type') t9 on t9.item_value = t.in_storehouse_type
                left join tms_goods_shelves t10 on t10.id = t.goods_shelves_id
            ${ew.customSqlSegment}
    </select>
</mapper>