| | |
| | | FROM |
| | | mdm_nc_node |
| | | WHERE |
| | | parent_id = n.id and is_deleted = 0 |
| | | parent_id = n.id and is_last_edition=1 and is_deleted = 0 |
| | | ) AS "has_children" from mdm_nc_node n left join blade_user u on n.create_user=u.id |
| | | left join blade_dict_biz dt on n.node_type=dt.dict_key and dt.code='nc_node_type' and dt.is_deleted=0 |
| | | where n.is_deleted=0 and n.parent_id=#{parentId} |
| | | where n.is_deleted=0 and n.is_last_edition=1 and n.parent_id=#{parentId} |
| | | </select> |
| | | |
| | | |
| | |
| | | </if> |
| | | </where> |
| | | </select> |
| | | |
| | | <select id="historyByParentIdAndName" resultType="org.springblade.mdm.program.vo.NcNodeVO"> |
| | | select n.id,n.name,n.create_time,n.update_time,u.name create_user_name,n.process_no |
| | | from mdm_nc_node n left join blade_user u on n.create_user=u.id and u.is_deleted=0 |
| | | |
| | | where n.is_deleted=0 and n.parent_id=#{parentId} and n.name=#{name} |
| | | where n.is_deleted=0 and n.parent_id in (select id from mdm_nc_node where parent_id=#{parentNode.parentId}) and n.name=#{name} |
| | | |
| | | </select> |
| | | |