- 博客(10)
- 收藏
- 关注
原创 spring boot第八次作业
Shiro进行权限控制1 . 添加依赖 org.apache.shiro shiro-spring 1.2.5 org.apache.shiro shiro-ehcache 1.2.52 . 编写Shiro配置类package com.xbz.web.system.config;import at.pollux.thymeleaf.shiro.dialect.ShiroDialect;import org.apache.shiro.authc
2020-08-04 22:10:15 177
原创 ssm第三次作业
1.初始化一个空的git仓库caotaiqiang@server1:~$ mkdir myfirstgitcaotaiqiang@server1:~$ cd myfirstgit/caotaiqiang@server1:~/myfirstgit$ git initInitialized empty Git repository in /home/caotaiqiang/myfirstgit/.git/caotaiqiang@server1:~/myfirstgit$初始化一个不包含工作目录的仓库
2020-08-03 21:52:47 102
原创 spring boot第七次作业
1.pom文件org.springframework.bootspring-boot-starter-parent1.5.2.RELEASE<dependencies> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> </dependency&g
2020-08-03 21:44:47 98
原创 spring boot第一次作业
springboot设计实体类,实现登录以及类别展示功能User类@Entity@Table(name=“t_user”)public class User {@Id //主键标识@GeneratedValue(strategy = GenerationType.IDENTITY)private Long id;private String nickname;private String username;private String password;private Strin
2020-08-03 09:44:03 216
原创 spring boot第二次作业
使用SpringBoot实现分类管理和标签管理1.在TypeRepository中添加接口,用来控制不能添加重复的分类:Type findByName(String name);2.在TypeService中增加方法接口:Type saveType(Type type);Type getTypeByName(String name);void delete(Long id);Type getType(Long id);Type updateType(Long id,Type type);在
2020-08-03 09:24:32 152
原创 spring boot第三次作业
spring boot新闻管理条件查询分页展示+新增+编辑commoditytypeDaoImpl实现类,实现接口方法@Overridepublic Commoditytype getCommoditytypeById(String ct_id) {Commoditytype ct = null;try {Connection conn = DBHelper.getConnection();String sql = “select * from commoditytype where ct_i
2020-08-03 09:19:09 156
原创 spring boot第四次作业
spring boot实现新闻首页与详情页NewService//主页显示新闻列表Page listNew(Pageable pageable);//主页推荐最新新闻列表List<News> listRecommendNewTop(Integer size);//全局搜索Page<News> listNew(String query,Pageable pageable);News getAndConvert(Long id);NewServiceImpl@O
2020-08-03 09:11:51 221
原创 spring boot第五次作业
评论,页面分类和标签功能新建comment实体类@Entity@Table(name=“t_comment”)public class Comment {@Id@GeneratedValue(strategy = GenerationType.IDENTITY)private Long id;private String nickname;private String email;private String content;private String avatar;@Tempor
2020-08-03 09:05:49 107
原创 spring boot第六次作业
异常处理SpringBoot的异常处理@ControllerAdvicepublic class ExceptionControllerAdvice {private final static Logger LOGGER = LoggerFactory.getLogger(ExceptionControllerAdvice.class);@ExceptionHandler(BusinessException.class)@ResponseBodypublic Result<?> h
2020-08-03 09:00:36 68
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人