操作权限

This commit is contained in:
jiangs 2025-12-26 17:49:42 +08:00
parent 45683f8296
commit e3d58e5660
8 changed files with 31 additions and 44 deletions

View File

@ -1,7 +1,14 @@
package com.czlis.interfaceCommon.mapper;
import com.czlis.interfaceCommon.pojo.dto.ComUsrpowerDTO;
import org.apache.ibatis.annotations.Param;
import java.util.List;
public interface ComUsrpowerMapper {
String getUserPower(@Param("yq")String yq,@Param("yhdh")String yhdh);
List<ComUsrpowerDTO> query(ComUsrpowerDTO comUsrpowerDTO);
void insert(ComUsrpowerDTO comUsrpowerDTO);
void update(ComUsrpowerDTO comUsrpowerDTO);
void delete(ComUsrpowerDTO comUsrpowerDTO);
}

View File

@ -1,4 +1,4 @@
package com.czlis.liswork.pojo.DTO;
package com.czlis.interfaceCommon.pojo.dto;
import lombok.AllArgsConstructor;
import lombok.Data;

View File

@ -7,6 +7,25 @@
select yhqx from com_usrpower where yhdh = #{yhdh} and yq = #{yq} and xtdh = 'LIS'
</select>
<select id="query" resultType="com.czlis.interfaceCommon.pojo.dto.ComUsrpowerDTO">
select b.*,a.yq as instr_yq,a.yqmc,(case when isnull(b.yhdh,'') = '' then '0' else '1' end) as syqx,a.useflag from lab_instr a left join com_usrpower b on (a.yq = b.yq and b.yhdh = #{yhdh} and b.xtdh = 'LIS')
<where>
<if test="yq != null and yq = ''"> and yq = #{yq}</if>
</where>
</select>
<insert id ="insert">
insert into com_usrpower (yhdh, yq, xtdh, yhqx)
values ( #{yhdh},#{yq},#{xtdh},#{yhqx})
</insert>
<update id="update">
update com_usrpower set yhqx = #{yhqx} where yhdh = #{yhdh} and yq = #{yq} and xtdh = #{xtdh}
</update>
<delete id="delete">
delete from com_usrpower where yhdh = #{yhdh} and yq = #{yq} and xtdh = #{xtdh}
</delete>

View File

@ -2,7 +2,7 @@ package com.czlis.liswork.controller.xtwh;
import com.czlis.common.core.domain.Result;
import com.czlis.liswork.pojo.DTO.ComUsrpowerDTO;
import com.czlis.interfaceCommon.pojo.dto.ComUsrpowerDTO;
import com.czlis.liswork.service.ComUsrpowerService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;

View File

@ -1,13 +0,0 @@
package com.czlis.liswork.mapper.xtwh;
import com.czlis.liswork.pojo.DTO.ComUsrpowerDTO;
import java.util.List;
import java.util.Map;
public interface ComUsrpowerMapper {
List<ComUsrpowerDTO> query(ComUsrpowerDTO comUsrpowerDTO);
void insert(ComUsrpowerDTO comUsrpowerDTO);
void update(ComUsrpowerDTO comUsrpowerDTO);
void delete(ComUsrpowerDTO comUsrpowerDTO);
}

View File

@ -1,7 +1,7 @@
package com.czlis.liswork.service;
import com.czlis.common.core.domain.Result;
import com.czlis.liswork.pojo.DTO.ComUsrpowerDTO;
import com.czlis.interfaceCommon.pojo.dto.ComUsrpowerDTO;
import java.util.List;

View File

@ -1,14 +1,13 @@
package com.czlis.liswork.service.impl.xtwh;
import com.czlis.common.core.domain.Result;
import com.czlis.liswork.mapper.xtwh.ComUsrpowerMapper;
import com.czlis.liswork.pojo.DTO.ComUsrpowerDTO;
import com.czlis.interfaceCommon.mapper.ComUsrpowerMapper;
import com.czlis.interfaceCommon.pojo.dto.ComUsrpowerDTO;
import com.czlis.liswork.service.ComUsrpowerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Map;
@Service
public class ComUsrpowerServiceImpl implements ComUsrpowerService {

View File

@ -1,25 +0,0 @@
<?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.czlis.liswork.mapper.xtwh.ComUsrpowerMapper">
<select id="query" resultType="com.czlis.liswork.pojo.DTO.ComUsrpowerDTO">
select b.*,a.yq as instr_yq,a.yqmc,(case when isnull(b.yhdh,'') = '' then '0' else '1' end) as syqx,a.useflag from lab_instr a left join com_usrpower b on (a.yq = b.yq and b.yhdh = #{yhdh} and b.xtdh = 'LIS')
<where>
<if test="yq != null and yq = ''"> and yq = #{yq}</if>
</where>
</select>
<insert id ="insert">
insert into com_usrpower (yhdh, yq, xtdh, yhqx)
values ( #{yhdh},#{yq},#{xtdh},#{yhqx})
</insert>
<update id="update">
update com_usrpower set yhqx = #{yhqx} where yhdh = #{yhdh} and yq = #{yq} and xtdh = #{xtdh}
</update>
<delete id="delete">
delete from com_usrpower where yhdh = #{yhdh} and yq = #{yq} and xtdh = #{xtdh}
</delete>
</mapper>