|
@@ -24,7 +24,7 @@
|
|
select parent_id from u_trial_classification_tree where id = #{parentId} and is_deleted = 0
|
|
select parent_id from u_trial_classification_tree where id = #{parentId} and is_deleted = 0
|
|
</select>
|
|
</select>
|
|
<select id="selectAllNode" resultType="org.springblade.business.vo.TrialClassificationTreeVO">
|
|
<select id="selectAllNode" resultType="org.springblade.business.vo.TrialClassificationTreeVO">
|
|
- select tree.id,tree.parent_id,tree.project_id,tree.classification_name,(
|
|
|
|
|
|
+ select tree.id,tree.parent_id,tree.project_id,tree.contract_id,tree.classification_name,(
|
|
SELECT
|
|
SELECT
|
|
CASE WHEN count(1) > 0 THEN 1 ELSE 0 END
|
|
CASE WHEN count(1) > 0 THEN 1 ELSE 0 END
|
|
FROM
|
|
FROM
|
|
@@ -33,7 +33,7 @@
|
|
parent_id = tree.id and is_deleted = 0
|
|
parent_id = tree.id and is_deleted = 0
|
|
) AS "has_children"
|
|
) AS "has_children"
|
|
from u_trial_classification_tree tree
|
|
from u_trial_classification_tree tree
|
|
- where tree.is_deleted = 0 and tree.project_id = #{projectId}
|
|
|
|
|
|
+ where tree.is_deleted = 0 and tree.project_id = #{projectId} and tree.contract_id = #{contractId}
|
|
<if test="id!=null and id!=''">
|
|
<if test="id!=null and id!=''">
|
|
and tree.parent_id = #{id}
|
|
and tree.parent_id = #{id}
|
|
</if>
|
|
</if>
|