You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
JinJiHuJava/ruoyi-admin/src/main/resources/mapper/jjh/ent/JProjectMapper.xml

61 lines
2.4 KiB

1 year ago
<?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.ruoyi.jjh.ent.mapper.JProjectMapper">
<select id="page" resultType="com.ruoyi.jjh.ent.entity.JProject">
select * from j_project
<where>
11 months ago
<if test="req.creditCode != null and req.creditCode != '' ">
and credit_code = #{req.creditCode}
</if>
1 year ago
<if test="req.projectName != null and req.projectName != '' ">
and project_name like concat('%',#{req.projectName},'%')
</if>
<if test="req.projectClassify != null and req.projectClassify != '' ">
and project_classify = #{req.projectClassify}
</if>
<if test="req.declareUnit != null and req.declareUnit != '' ">
and declare_unit like concat('%',#{req.declareUnit},'%')
</if>
<if test="req.status != null and req.status != '' ">
and status = #{req.status}
</if>
<if test="req.projectYear != null">
and project_year = #{req.projectYear}
</if>
</where>
1 year ago
order by create_time desc ,project_year desc
1 year ago
</select>
<select id="getApprovalInfoList" resultType="com.ruoyi.jjh.declaration.entity.vo.BmsApprovalInfoQueryVo">
select
c.id,
c.approval_by_id,
d.nick_name AS approvalByName,
c.approval_status,
c.approval_opinions,
c.approval_attachment,
c.approval_time,
c.is_before_data,
c.sort
from j_project a
left join bms_declaration_records b on a.id = b.jjh_project_id
left join bms_approval_info c on b.id = c.declaration_records_id
left join sys_user d on c.approval_by_id = d.user_id
where a.id=#{id}
order by c.sort asc
</select>
11 months ago
<select id="selectAll" resultType="com.ruoyi.jjh.ent.entity.JProject">
select * from j_project
<where>
<if test="name != null and name != '' ">
and credit_code like concat('%',#{name},'%')
or project_name like concat('%',#{name},'%')
or declare_unit like concat('%',#{name},'%')
</if>
</where>
order by create_time desc ,project_year desc
</select>
1 year ago
</mapper>