Lius
2025-01-15 aed7113be920129211fd7cd63c963301bbf40581
lxzn-module-mdc/src/main/java/org/jeecg/modules/mdc/mapper/xml/MdcEquipmentMapper.xml
@@ -107,6 +107,7 @@
        <foreach collection="equipmentIds" index="index" item="id" open="(" separator="," close=")">
            #{id}
        </foreach>
        ORDER BY t1.equipment_id
    </select>
    <!--根据部门id查询设备id集合-->
@@ -142,6 +143,7 @@
            <foreach collection="equipmentIdList" index="index" item="id" open="(" separator="," close=")">
                #{id}
            </foreach>
            AND me.equipment_status = 0
        </where>
        ORDER BY sd.depart_order
    </select>
@@ -165,6 +167,7 @@
            <foreach collection="equipmentIdList" index="index" item="id" open="(" separator="," close=")">
                #{id}
            </foreach>
            AND me.equipment_status = 0
        </where>
        ORDER BY mp.production_order
    </select>
@@ -263,4 +266,17 @@
        select top 1 spindlespeed, actualspindlespeed from [${tableName}] order by CollectTime  desc
    </select>
    <!--根据id获取设备信息-->
    <select id="findById" resultType="org.jeecg.modules.mdc.dto.MdcEquipmentDetailedDto">
        SELECT
            t1.*,
            t2.MaxAxis maxAxis,
            t2.ValidAxis validAxis
        FROM
            mdc_equipment t1
                LEFT JOIN EquipmentBaseInfo t2 ON t1.equipment_id = t2.EquipmentID
        WHERE
            t1.id = #{ id }
    </select>
</mapper>