管道基础大数据平台系统开发-【后端】-Server
1
13693261870
2022-10-13 e8a5942bd0ac1188281cda29c882bb0e107896dc
1
已修改10个文件
122 ■■■■ 文件已修改
data/db_fn.sql 18 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
data/db_tab.sql 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
data/menu-执行.xls 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/lf/server/controller/sys/AuthController.java 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/lf/server/controller/sys/UserController.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/lf/server/mapper/sys/AuthMapper.java 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/lf/server/service/sys/AuthService.java 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/resources/mapper/sys/AuthMapper.xml 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/resources/mapper/sys/UserMapper.xml 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
说明.txt 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
data/db_fn.sql
@@ -150,25 +150,21 @@
----------------------------------------------------------------------------------------------------- 
select a.*,fn_uname(a.create_user) createUserName,fn_uname(a.update_user) updateUserName from lf.sys_blacklist a order by a.id;
select * from lf.sys_user a where uname like '%' and a.depid=ANY(fn_rec_array(1,'dep'));
select * from lf.sys_user a left join lf.sys_role_user b on a.id=b.userid
where exist
select * from lf.sys_user a where not exists (select id from lf.sys_role_user b where b.userid = a.id and b.roleid = 1)
select a.* from lf.sys_user a where not exists (select b.id from lf.sys_role_user b where b.userid = a.id and b.roleid = 1)
and uname like '%室%' and a.depid = ANY(fn_rec_array(1, 'dep'))
order by a.id limit 10 offset 0;
select a.*,fn_uname(a.userid) uname from lf.sys_role_user a order by a.id
select a.*,fn_uname(a.userid) uname from lf.sys_role_user a where a.id = 1
select a.*,fn_rec_query(a.depid, 'dep') depName,fn_rec_query(a.dirid, 'dir') dirName from lf.sys_style a;
select * from lf.sys_auth order by id;
------------------------------------------------------------
select * from lf.sys_auth;
select * from lf.sys_menu;
select * from lf.sys_menu_auth;
select * from lf.sys_args;
select * from lf.sys_auth a left join lf.sys_menu;
select a.* from lf.sys_auth a where not exists (select b.id from lf.sys_menu_auth b where b.authid=a.id and b.menuid=1);
-----------------------------------------------------------------------------------------------------
data/db_tab.sql
@@ -434,7 +434,7 @@
comment on column lf.sys_role.update_user is '更新人ID';
comment on column lf.sys_role.update_time is '更新时间';
comment on column lf.sys_role.bak is '备注';
--insert into lf.sys_role (depid,name,descr) values (1,'Admin','系统管理员');
--insert into lf.sys_role (id,depid,name,descr) values (1,1,'Admin','系统管理员');
select * from lf.sys_role;
select a.*,b.name depname from lf.sys_role a inner join lf.sys_dep b on a.depid = b.id order by a.id limit 10 offset 0;
data/menu-Ö´ÐÐ.xls
Binary files differ
src/main/java/com/lf/server/controller/sys/AuthController.java
@@ -96,6 +96,33 @@
    }
    @SysLog()
    @ApiOperation(value = "根据菜单分页查询并返回记录数")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "menuid", value = "菜单ID", dataType = "Integer", paramType = "query", example = "1"),
            @ApiImplicitParam(name = "pageSize", value = "每页条数", dataType = "Integer", paramType = "query", example = "10"),
            @ApiImplicitParam(name = "pageIndex", value = "分页数(从1开始)", dataType = "Integer", paramType = "query", example = "1")
    })
    @GetMapping(value = "/selectByPageForMenu")
    public ResponseMsg<List<AuthEntity>> selectByPageForMenu(Integer menuid, Integer pageSize, Integer pageIndex) {
        try {
            if (pageSize < 1 || pageIndex < 1) {
                return fail("每页页数或分页数小于1", null);
            }
            int count = authService.selectCountForMenu(menuid);
            if (count == 0) {
                return success(0, null);
            }
            List<AuthEntity> rs = authService.selectByPageForMenu(menuid, pageSize, pageSize * (pageIndex - 1));
            return success(count, rs);
        } catch (Exception ex) {
            return fail(ex.getMessage(), null);
        }
    }
    @SysLog()
    @ApiOperation(value = "插入一条")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "entity", value = "实体类", dataType = "com.lf.server.entity.sys.AuthEntity", paramType = "body", example = "")
src/main/java/com/lf/server/controller/sys/UserController.java
@@ -98,7 +98,7 @@
    }
    @SysLog()
    @ApiOperation(value = "根据角色+单位分页查询")
    @ApiOperation(value = "根据角色+单位分页查询并返回记录数")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "uname", value = "用户名", dataType = "String", paramType = "query", example = "室"),
            @ApiImplicitParam(name = "roleid", value = "角色ID", dataType = "Integer", paramType = "query", example = "1"),
src/main/java/com/lf/server/mapper/sys/AuthMapper.java
@@ -25,12 +25,30 @@
    /**
     * åˆ†é¡µæŸ¥è¯¢
     *
     * @param name åç§°
     * @param name   åç§°
     * @param limit  è®°å½•表
     * @param offset åç§»é‡
     * @return åˆ—表
     */
    public List<AuthEntity> selectByPage(String name, Integer limit, Integer offset);
    /**
     * æ ¹æ®èœå•查询记录数
     *
     * @param menuid
     * @return
     */
    public Integer selectCountForMenu(Integer menuid);
    /**
     * æ ¹æ®èœå•分页查询
     *
     * @param menuid
     * @param limit
     * @param offset
     * @return
     */
    public List<AuthEntity> selectByPageForMenu(Integer menuid, Integer limit, Integer offset);
    /**
     * æ’入一条
@@ -86,5 +104,4 @@
     * @return
     */
    public List<AuthEntity> selectAuthAll();
}
src/main/java/com/lf/server/service/sys/AuthService.java
@@ -17,7 +17,6 @@
    @Autowired
    AuthMapper authMapper;
    @Override
    public Integer selectCount(String name) {
        return authMapper.selectCount(name);
@@ -29,6 +28,16 @@
    }
    @Override
    public Integer selectCountForMenu(Integer menuid) {
        return authMapper.selectCountForMenu(menuid);
    }
    @Override
    public List<AuthEntity> selectByPageForMenu(Integer menuid, Integer limit, Integer offset) {
        return authMapper.selectByPageForMenu(menuid, limit, offset);
    }
    @Override
    public Integer insertAuth(AuthEntity authEntity) {
        return authMapper.insertAuth(authEntity);
    }
src/main/resources/mapper/sys/AuthMapper.xml
@@ -1,8 +1,6 @@
<?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.lf.server.mapper.sys.AuthMapper">
    <!-- ç»Ÿè®¡è¡Œæ•° -->
    <select id="selectCount" resultType="java.lang.Integer" parameterType="java.lang.String">
        select count(*) from lf.sys_auth
        <where>
@@ -12,7 +10,6 @@
        </where>
    </select>
    <!-- åˆ†é¡µæŸ¥è¯¢ -->
    <select id="selectByPage" resultType="com.lf.server.entity.sys.AuthEntity">
        select * from lf.sys_auth
        <where>
@@ -24,6 +21,29 @@
        limit #{limit} offset #{offset}
    </select>
    <select id="selectCountForMenu" resultType="java.lang.Integer" parameterType="java.lang.String">
        select count(a.*) from lf.sys_auth a where not exists (select b.id from lf.sys_menu_auth b
        <where>
            b.authid = a.id
            <if test="menuid != null">
                and b.menuid = #{menuid}
            </if>
        </where>
        )
    </select>
    <select id="selectByPageForMenu" resultType="com.lf.server.entity.sys.AuthEntity">
        select a.* from lf.sys_auth a where not exists (select b.id from lf.sys_menu_auth b
        <where>
            b.authid = a.id
            <if test="menuid != null">
                and b.menuid = #{menuid}
            </if>
        </where>
        )
        order by a.id
        limit #{limit} offset #{offset}
    </select>
    <select id="selectAuthAll" resultType="com.lf.server.entity.sys.AuthEntity">
        select * from lf.sys_auth order by id
src/main/resources/mapper/sys/UserMapper.xml
@@ -31,9 +31,9 @@
    </select>
    <select id="selectCountForRole" resultType="java.lang.Integer" parameterType="java.lang.String">
        select count(*) from lf.sys_user a
        select count(a.*) from lf.sys_user a
        <where>
            not exists (select id from lf.sys_role_user b where b.userid = a.id
            not exists (select b.id from lf.sys_role_user b where b.userid = a.id
            <if test="roleid != null">
                and b.roleid = #{roleid}
            </if>
@@ -50,7 +50,7 @@
    <select id="selectByPageForRole" resultMap="resultMap" resultType="com.lf.server.entity.sys.UserEntity">
        select a.*,fn_rec_query(a.depid, 'dep') depName from lf.sys_user a
        <where>
            not exists (select id from lf.sys_role_user b where b.userid = a.id
            not exists (select b.id from lf.sys_role_user b where b.userid = a.id
            <if test="roleid != null">
                and b.roleid = #{roleid}
            </if>
˵Ã÷.txt
@@ -12,11 +12,12 @@
11.资源实时监控(CPU信息+内存信息+在线用户+资源状态)
12.下载文件并设置MIME类型
13.上传文件(commons-fileupload) *
1.前端集成登录接口
2.菜单接口添加用户权限
3.开发菜单权限、用户权限、资源权限接口
----------------------------------------------------------------------------------------------------
java è°ƒç”¨gdal读取gdb数据,linux下java调用gdal:
https://blog.csdn.net/weixin_53853459/article/details/120954597
https://blog.csdn.net/qq_43444401/article/details/125649414
https://blog.csdn.net/qq_43961619/article/details/124627871
http://127.0.0.1:12316/dict/selectCount?tab=sys_user
http://127.0.0.1:12316/Dict/selectByPage?tab=sys_user&pageSize=10&pageIndex=0