From 14943f4a30e027dcf8956272192666524a851eff Mon Sep 17 00:00:00 2001 From: Houjie <714924425@qq.com> Date: 星期一, 18 八月 2025 20:31:00 +0800 Subject: [PATCH] 安灯发起、安灯处理 安灯响应 --- src/main/java/org/jeecg/modules/base/mapper/xml/FactoryMapper.xml | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/src/main/java/org/jeecg/modules/base/mapper/xml/FactoryMapper.xml b/src/main/java/org/jeecg/modules/base/mapper/xml/FactoryMapper.xml index 0832f10..b818615 100644 --- a/src/main/java/org/jeecg/modules/base/mapper/xml/FactoryMapper.xml +++ b/src/main/java/org/jeecg/modules/base/mapper/xml/FactoryMapper.xml @@ -2,4 +2,22 @@ <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <mapper namespace="org.jeecg.modules.base.mapper.FactoryMapper"> + <select id="recursionChildren" resultType="java.lang.String"> + WITH temp ( id ) AS ( + SELECT + id + FROM + base_factory + WHERE + id = #{ factoryId } UNION ALL + SELECT + a.id + FROM + base_factory a + INNER JOIN temp ON a.parent_id = temp.id + ) SELECT + * + FROM + temp + </select> </mapper> \ No newline at end of file -- Gitblit v1.9.3