摘要: 1:导入相关依赖 2:数据库建表以及插入数据 sql / 用户表 / CREATE TABLE ( int(11) NOT NULL AUTO_INCREMENT, varchar(20) NOT NULL, varchar(100) NOT NULL, PRIMARY KEY ( ), UNIQU 阅读全文
posted @ 2020-04-24 22:34 努力的校长 阅读(264) 评论(0) 推荐(0) 编辑
摘要: 基于【shiro集成spring】项目改造 引入相关依赖环境 构建shiro 注解配置 在SpringMVC的配置文件中增加以下配置 注解的使用 可以注解在controller类上或者方法上,可以叠加使用 未登录或者无权限跳转页面 com\shiro\resolver\MyExceptionReso 阅读全文
posted @ 2020-04-24 22:33 努力的校长 阅读(715) 评论(0) 推荐(0) 编辑
摘要: ==基于【加密及密码比对器(三)】项目改造== 引入相关依赖环境 shiro spring已经包含 shiro core和shiro web 所以这两个依赖可以删掉 构建shiro配置文件 ==替代shiro.ini文件== resources\spring shiro.xml 把userseriv 阅读全文
posted @ 2020-04-24 22:32 努力的校长 阅读(148) 评论(0) 推荐(0) 编辑
摘要: ==基于【自定义remle(二)】项目增加加密功能== 1:数据库t_user表增加一列(盐) 增加字段:salt sql CREATE TABLE ( int(11) NOT NULL AUTO_INCREMENT, varchar(20) NOT NULL, varchar(100) NOT N 阅读全文
posted @ 2020-04-24 22:31 努力的校长 阅读(425) 评论(0) 推荐(0) 编辑
摘要: SpringMVC+SpringMVC+Mybatis项目 1:导入相关依赖 2:数据库建表语句 sql / 用户表 / CREATE TABLE ( int(11) NOT NULL AUTO_INCREMENT, varchar(20) NOT NULL, varchar(100) NOT NU 阅读全文
posted @ 2020-04-24 22:29 努力的校长 阅读(387) 评论(0) 推荐(0) 编辑
摘要: SpringMVC项目 1:pom引入相关依赖 2:安装ini插件 3:创建shiro默认配置文件 resources\shiro.ini 4:构建controller(模拟登陆操作) com\shiro\controller\LoginController.java 5:构建SpringMVC配置 阅读全文
posted @ 2020-04-24 22:28 努力的校长 阅读(226) 评论(0) 推荐(0) 编辑
摘要: 构建一个定时任务的service接口及实现(模拟) 接口:com\applesnt\springboot\service\TaskService.java 实现类:com\applesnt\springboot\service\impl\TaskServiceImpl.java ==需要定时业务处理 阅读全文
posted @ 2020-04-18 21:15 努力的校长 阅读(338) 评论(0) 推荐(0) 编辑
摘要: 说明 构建一个群发邮件的service接口及实现(模拟) 接口:com\\springboot\service\AsynxService.java 实现类:com\applesnt\springboot\service\impl\AsynxServiceImpl.java ==需要异步业务处理的方法 阅读全文
posted @ 2020-04-18 20:19 努力的校长 阅读(689) 评论(0) 推荐(0) 编辑
摘要: MyBatis默认提供了一个数据库连接池PooledDataSource,在此我们使用阿里提供的Druid数据库连接池 项目下载:https://files.cnblogs.com/files/applesnt/springboot db.zip 1:建表sql语句 sql CREATE TABLE 阅读全文
posted @ 2020-04-18 20:17 努力的校长 阅读(333) 评论(0) 推荐(0) 编辑
摘要: ==springboot2.2.6 delete请求报错,降至2.1.11功能可用 原因未知== 构建员工删除请求 com\springboot\controller\EmployeeController.java 在list.html增加删除员工按钮 resources\templates\lis 阅读全文
posted @ 2020-04-18 20:15 努力的校长 阅读(565) 评论(0) 推荐(1) 编辑
摘要: 构建员工修改请求 com\springboot\controller\EmployeeController.java 在list.html增加编辑员工按钮 resources\templates\list.html 构建修改页面 resources\templates\add.html(公用添加页, 阅读全文
posted @ 2020-04-18 20:14 努力的校长 阅读(312) 评论(0) 推荐(0) 编辑
摘要: 构建员工添加请求 com\springboot\controller\EmployeeController.java 在list.html增加添加员工按钮 resources\templates\list.html 构建添加页面 resources\templates\add.html form表单 阅读全文
posted @ 2020-04-18 20:12 努力的校长 阅读(369) 评论(0) 推荐(0) 编辑
摘要: 构建员工controller com\springboot\controller\EmployeeController.java 构建显示员工信息 resources\templates\list.html 页面展示 阅读全文
posted @ 2020-04-18 20:11 努力的校长 阅读(639) 评论(0) 推荐(0) 编辑
摘要: 把顶部和左侧的公共代码分别放到header.html和left.html中 顶部代码:resources\templates\header.html 主内容展示: 在dashboard.html和list.html页面分别引入顶部和左侧页面: list.html 主内容展示: dashboard.h 阅读全文
posted @ 2020-04-18 20:10 努力的校长 阅读(332) 评论(0) 推荐(1) 编辑
摘要: 1:构建登录javaBean com\springboot\vo\LoginUser.java 2:构建登录controller com\springboot\controller\LoginController.java 3:构建登录拦截器 4:把登录拦截器添加到spring以及添加主页视图解析器 阅读全文
posted @ 2020-04-18 20:09 努力的校长 阅读(278) 评论(0) 推荐(0) 编辑
摘要: 1:IDEA编码设置UTF 8 2:创建国际化文件 3:添加中英文 login_en_US.properties: login_zh_CN.properties: 4:国际化配置 5:首页国际化 resources\templates\index.html 6:首页访问(读取默认语言) 7:编写中英 阅读全文
posted @ 2020-04-18 20:07 努力的校长 阅读(217) 评论(0) 推荐(0) 编辑
摘要: 1:编写Controller com\springboot\controller\IndexController.java 首页跳转controller 2:添加扩展视图解析器 com\springboot\config\MyConfig.java 3:首页展示: 阅读全文
posted @ 2020-04-18 20:06 努力的校长 阅读(150) 评论(0) 推荐(0) 编辑
摘要: 1:静态资源 下载静态资源:https://files.cnblogs.com/files/applesnt/ztzy.zip 项目下载:https://files.cnblogs.com/files/applesnt/hellospringboot.zip 把css、js、img文件夹放在stat 阅读全文
posted @ 2020-04-18 20:04 努力的校长 阅读(174) 评论(0) 推荐(0) 编辑
摘要: Springboot默认使用的日志框架就是logback 创建自定义的logback spring.xml放在resources类目录下即可 logback spring.xml: java调用: 阅读全文
posted @ 2020-04-11 23:07 努力的校长 阅读(166) 评论(0) 推荐(0) 编辑
摘要: 存放位置:resources\templates 访问方式:通过Controller请求访问,不可直接访问(相当于web项目的WEB INF目录) 环境依赖: 命名空间: 相关配置: 相关参考: https://www.cnblogs.com/itdragon/archive/2018/04/13/ 阅读全文
posted @ 2020-04-11 21:49 努力的校长 阅读(361) 评论(0) 推荐(0) 编辑