增加数据权限控制
This commit is contained in:
parent
ce5f4557f4
commit
59ca6ccc9f
|
@ -1,6 +1,7 @@
|
||||||
package com.szr.zdryztpg.service.impl;
|
package com.szr.zdryztpg.service.impl;
|
||||||
|
|
||||||
import com.szr.common.model.PageUtil;
|
import com.szr.common.model.PageUtil;
|
||||||
|
import com.szr.data.scope.annotation.DataScope;
|
||||||
import com.szr.zdryztpg.entity.ZdryJcjdztpgInfo;
|
import com.szr.zdryztpg.entity.ZdryJcjdztpgInfo;
|
||||||
import com.szr.zdryztpg.mapper.ZdryJcjdztpgInfoMapper;
|
import com.szr.zdryztpg.mapper.ZdryJcjdztpgInfoMapper;
|
||||||
import com.szr.zdryztpg.model.ZtpgPageListDTO;
|
import com.szr.zdryztpg.model.ZtpgPageListDTO;
|
||||||
|
@ -25,6 +26,7 @@ public class ZdryJcjdztpgServiceImpl implements ZdryJcjdztpgInfoService {
|
||||||
private ZdryJcjdztpgInfoMapper zdryJcjdztpgInfoMapper;
|
private ZdryJcjdztpgInfoMapper zdryJcjdztpgInfoMapper;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@DataScope(mainAlias = "zji")
|
||||||
public PageUtil<ZtpgPageListVO> queryPageList(ZtpgPageListDTO params) {
|
public PageUtil<ZtpgPageListVO> queryPageList(ZtpgPageListDTO params) {
|
||||||
int beginIndex = (params.getPage() - 1) * params.getPageSize() + 1;
|
int beginIndex = (params.getPage() - 1) * params.getPageSize() + 1;
|
||||||
int endIndex = params.getPage() * params.getPageSize();
|
int endIndex = params.getPage() * params.getPageSize();
|
||||||
|
|
|
@ -597,6 +597,9 @@
|
||||||
<if test="jcjssj!=null and jcjssj!=''">
|
<if test="jcjssj!=null and jcjssj!=''">
|
||||||
and to_char(zji.jcsj,'yyyy-MM-dd HH:mm:ss') <![CDATA[<=]]> #{jcjssj,jdbcType=VARCHAR}
|
and to_char(zji.jcsj,'yyyy-MM-dd HH:mm:ss') <![CDATA[<=]]> #{jcjssj,jdbcType=VARCHAR}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="params!=null and params!=''">
|
||||||
|
${params.dataScope}
|
||||||
|
</if>
|
||||||
</where>
|
</where>
|
||||||
order by zji.jcsj desc
|
order by zji.jcsj desc
|
||||||
limit #{pageSize} offset (#{pageSize} * (#{page}-1))
|
limit #{pageSize} offset (#{pageSize} * (#{page}-1))
|
||||||
|
@ -631,6 +634,9 @@
|
||||||
<if test="jcjssj!=null and jcjssj!=''">
|
<if test="jcjssj!=null and jcjssj!=''">
|
||||||
and to_char(zji.jcsj,'yyyy-MM-dd HH:mm:ss') <![CDATA[<=]]> #{jcjssj,jdbcType=VARCHAR}
|
and to_char(zji.jcsj,'yyyy-MM-dd HH:mm:ss') <![CDATA[<=]]> #{jcjssj,jdbcType=VARCHAR}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="params!=null and params!=''">
|
||||||
|
${params.dataScope}
|
||||||
|
</if>
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
</mapper>
|
</mapper>
|
Loading…
Reference in New Issue