指标库代码

This commit is contained in:
huangzj
2023-06-14 15:15:22 +08:00
parent 94cca2e250
commit f9d9162b28
9 changed files with 435 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
package com.njcn.system.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.github.jeffreyning.mybatisplus.base.MppBaseMapper;
import com.njcn.system.pojo.po.CsStatisticalSetPO;
/**
*
* Description:
* Date: 2023/6/9 16:17【需求编号】
*
* @author clam
* @version V1.0.0
*/
public interface CsStatisticalSetPOMapper extends MppBaseMapper<CsStatisticalSetPO> {
}

View File

@@ -0,0 +1,20 @@
package com.njcn.system.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.njcn.system.pojo.po.SysDicTreePO;
import com.njcn.system.pojo.vo.DictTreeVO;
import org.apache.ibatis.annotations.Param;
import java.util.List;
/**
*
* Description:
* Date: 2023/6/9 14:00【需求编号】
*
* @author clam
* @version V1.0.0
*/
public interface SysDicTreePOMapper extends BaseMapper<SysDicTreePO> {
List<DictTreeVO> queryByid(@Param("id") String id);
}

View File

@@ -0,0 +1,42 @@
<?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="com.njcn.system.mapper.SysDicTreePOMapper">
<resultMap id="BaseResultMap" type="com.njcn.system.pojo.po.SysDicTreePO">
<!--@mbg.generated-->
<!--@Table sys_dic_tree-->
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="pid" jdbcType="VARCHAR" property="pid" />
<result column="pids" jdbcType="LONGVARCHAR" property="pids" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="code" jdbcType="VARCHAR" property="code" />
<result column="sort" jdbcType="INTEGER" property="sort" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="status" jdbcType="TINYINT" property="status" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
</resultMap>
<sql id="Base_Column_List">
<!--@mbg.generated-->
id, pid, pids, `name`, code, sort, remark, `status`, create_time, create_by, update_time,
update_by
</sql>
<select id="queryByid" resultType="com.njcn.system.pojo.vo.DictTreeVO">
SELECT
*
FROM
sys_dic_tree a
WHERE
a.pids LIKE concat('%',#{id},'%')
AND NOT EXISTS (
SELECT
1
FROM
sys_dic_tree b
WHERE
b.pids LIKE concat('%',#{id},'%') and a.id = b.pid)
</select>
</mapper>