今天給大家開源一個基于springboot的在線教育平臺系統,系統是小孟開發的,第一個版本是小鋒開發的(小鋒的博客),我進行了本版本的開發,
該系統完全免費、開源,
系統完美運行,無任何的bug,技術較多,可以當做面試的專案或者作為畢設的專案,
系統獲取原始碼的方式見文章底部,
為防止刷著刷者找不到,大家點贊、收藏文章,
系統完美運行,具體的介紹如下所示,
目錄
1. 技術介紹
2.功能介紹
3. 前端
3.1 首頁
3.2 課程
3.3 登入
3.4 商品兌換
3.5 課程發布
4. 后端
4.1 登錄
4.2 系統管理
4.3 課程管理
4.4 教師管理
4.5 導航選單
4.6 輪播管理
4.7 通知管理
4.8 禮品管理
5,系統的核心代碼
6,原始碼獲取
1. 技術介紹
核心技術:SpringBoot+mybatis;
前端:layui;
開發工具:idea;
資料庫:mysql5.7;
模版引擎:thymeleaf;
安全框架:SpringSecurity;
日志框架:logback;
資料庫連接池:druid;
在線編輯器:ckeditor;
圖片輪播組件:jQuerySwipeslider;
2.功能介紹
本專案分前臺用戶界面功能和后臺管理功能;
前臺用戶界面功能:
-
滾動大條幅展示重要通知和課程或者活動;
-
展示課程,根據實際業務需求,展示課程推薦,最新課程,免費課程,實戰課程;
-
課程搜索,用戶輸入指定課程關鍵字,可以搜索查詢,也可以根據課程類別分類,和型別進行搜索;
-
課程詳細展示
-
用戶登陸
-
在線支付
后臺管理功能:
-
管理員登錄
-
課程管理
-
課程類別管理
-
用戶管理
-
授課老師管理
-
訂單管理
-
選單管理
-
友情鏈接管理
-
系統屬性管理
-
自定義帖子管理
-
輪轉圖片帖子管理
3. 前端
3.1 首頁

3.2 課程
提供按照課程的類別,型別以及搜索框進行快速查詢相關課程

點擊任意一門課程,免費課程可以直接觀看,vip課程則需要通過支付寶或者微信繳費開通vip進行觀看

3.3 登入
學習課程時候需要登錄才能觀看相關視頻資料

登入后可以查看個人中心的相關功能

在我的訂單界面可以查看已經購買的課程

3.4 商品兌換

3.5 課程發布
在課程發布頁面可以提交發布的課程資料

在我的發布頁面可以查看所有已經發布的課程相關資訊,查看審核狀態

4. 后端
4.1 登錄

4.2 系統管理
包括用戶管理,角色管理,選單管理,可以查看對應的資訊并添加,匯入,修改或洗掉

角色管理界面可以為角色分配權限

4.3 課程管理
可以添加課程,對課程進行分類管理:公共課程,專業課程,免費課程等


在類別管理中可以添加課程的分類資訊

在審核功能處可以對上傳的視頻進行審核
4.4 教師管理

4.5 導航選單

4.6 輪播管理

4.7 通知管理

4.8 禮品管理

5,系統的核心代碼
/**
* 操作日志記錄注解
* Created by xiaomeng 2020-03-21 17:03
*技術交流v:kaifazixun
* 操作日志記錄注解
* Created by wangfan on 2020-03-21 17:03
*/
@Target({ElementType.TYPE, ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
public @interface OperLog {
/**
* 模塊
*/
String value();
/**
* 功能
*/
String desc();
/**
* 是否記錄請求引數
*/
boolean param() default true;
/**
* 是否記錄回傳結果
*/
boolean result() default false;
}*
*/
@Target({ElementType.TYPE, ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
public @interface OperLog {
/**
* 模塊
*/
String value();
/**
* 功能
*/
String desc();
/**
* 是否記錄請求引數
*/
boolean param() default true;
/**
* 是否記錄回傳結果
*/
boolean result() default false;
}
@Aspect
@Component
public class OperLogAspect {
private ThreadLocal<Long> startTime = new ThreadLocal<>();
@Autowired
private OperRecordService operRecordService;
@Pointcut("@annotation(com.egao.common.core.annotation.OperLog)")
public void operLog() {
}
@Before("operLog()")
public void doBefore(JoinPoint joinPoint) throws Throwable {
startTime.set(System.currentTimeMillis());
}
@AfterReturning(pointcut = "operLog()", returning = "result")
public void doAfterReturning(JoinPoint joinPoint, Object result) {
saveLog(joinPoint, result, null);
}
@AfterThrowing(value = "operLog()", throwing = "e")
public void doAfterThrowing(JoinPoint joinPoint, Exception e) {
saveLog(joinPoint, null, e);
}
private void saveLog(JoinPoint joinPoint, Object result, Exception e) {
// 獲取reques物件
ServletRequestAttributes attributes = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes();
HttpServletRequest request = (attributes == null ? null : attributes.getRequest());
// 構建操作日志
OperRecord operRecord = new OperRecord();
operRecord.setUserId(getLoginUserId());
if (startTime.get() != null) operRecord.setSpendTime(System.currentTimeMillis() - startTime.get());
if (request != null) {
operRecord.setRequestMethod(request.getMethod());
operRecord.setUrl(request.getRequestURI());
operRecord.setIp(UserAgentGetter.getIp(request));
}
// 記錄例外資訊
if (e != null) {
operRecord.setState(1);
operRecord.setComments(StrUtil.sub(e.toString(), 0, 2000));
}
public class BaseController {
/**
* 獲取當前登錄的user
*/
public User getLoginUser() {
Subject subject = SecurityUtils.getSubject();
if (subject == null) return null;
Object object = subject.getPrincipal();
if (object != null) return (User) object;
return null;
}
/**
* 獲取當前登錄的userId
*/
public Integer getLoginUserId() {
User loginUser = getLoginUser();
return loginUser == null ? null : loginUser.getUserId();
}
}
/**
* 用戶管理
* Created by xiaomeng 2020-12-24 16:10
*技術交流V:kaifazixun
*/
@Controller
@RequestMapping("/sys/user")
public class UserController extends BaseController {
@Autowired
private UserService userService;
@Autowired
private DictionaryDataService dictionaryDataService;
@Autowired
private RoleService roleService;
@Autowired
private OrganizationService organizationService;
@RequiresPermissions("sys:user:view")
@RequestMapping()
public String view(Model model) {
model.addAttribute("sexList", dictionaryDataService.listByDictCode("sex"));
model.addAttribute("organizationTypeList", dictionaryDataService.listByDictCode("organization_type"));
model.addAttribute("rolesJson", JSON.toJSONString(roleService.list()));
return "system/user.html";
}
/**
* 個人中心
*/
@RequestMapping("/info")
public String userInfo(Model model) {
model.addAttribute("user", userService.getFullById(getLoginUserId()));
model.addAttribute("sexList", dictionaryDataService.listByDictCode("sex"));
return "index/user-info.html";
}
/**
* 分頁查詢用戶
*/
@OperLog(value = "用戶管理", desc = "分頁查詢")
@RequiresPermissions("sys:user:list")
@ResponseBody
@RequestMapping("/page")
public PageResult<User> page(HttpServletRequest request) {
PageParam<User> pageParam = new PageParam<>(request);
pageParam.setDefaultOrder(null, new String[]{"create_time"});
return userService.listPage(pageParam);
}
/**
* 查詢全部用戶
*/
@OperLog(value = "用戶管理", desc = "查詢全部")
@RequiresPermissions("sys:user:list")
@ResponseBody
@RequestMapping("/list")
public JsonResult list(HttpServletRequest request) {
PageParam<User> pageParam = new PageParam<>(request);
List<User> records = userService.listAll(pageParam.getNoPageParam());
return JsonResult.ok().setData(pageParam.sortRecords(records));
}
/**
* 根據id查詢用戶
*/
@OperLog(value = "用戶管理", desc = "根據id查詢")
@RequiresPermissions("sys:user:list")
@ResponseBody
@RequestMapping("/get")
public JsonResult get(Integer id) {
PageParam<User> pageParam = new PageParam<>();
pageParam.put("userId", id);
List<User> records = userService.listAll(pageParam.getNoPageParam());
return JsonResult.ok().setData(pageParam.getOne(records));
}
/**
* 字典管理
* Created by xiaomeng on 2021-03-14 11:29:03
* 技術交流加v:kafazixun
*/
@Controller
@RequestMapping("/sys/dict")
public class DictionaryController extends BaseController {
@Autowired
private DictionaryService dictionaryService;
@RequiresPermissions("sys:dict:view")
@RequestMapping()
public String view() {
return "system/dictionary.html";
}
/**
* 分頁查詢字典
*/
@OperLog(value = "字典管理", desc = "分頁查詢")
@RequiresPermissions("sys:dict:list")
@ResponseBody
@RequestMapping("/page")
public PageResult<Dictionary> page(HttpServletRequest request) {
PageParam<Dictionary> pageParam = new PageParam<>(request);
return new PageResult<>(dictionaryService.page(pageParam, pageParam.getWrapper()).getRecords(), pageParam.getTotal());
}
/**
* 查詢全部字典
*/
@OperLog(value = "字典管理", desc = "查詢全部")
@RequiresPermissions("sys:dict:list")
@ResponseBody
@RequestMapping("/list")
public JsonResult list(HttpServletRequest request) {
PageParam<Dictionary> pageParam = new PageParam<>(request);
return JsonResult.ok().setData(dictionaryService.list(pageParam.getOrderWrapper()));
}
/**
* 根據id查詢字典
*/
@OperLog(value = "字典管理", desc = "根據id查詢")
@RequiresPermissions("sys:dict:list")
@ResponseBody
@RequestMapping("/get")
public JsonResult get(Integer id) {
return JsonResult.ok().setData(dictionaryService.getById(id));
}
6,原始碼獲取
源獲取點擊下面,關注彈出的公眾號圖,
回復:精品課程
不是評論區回復,不是評論區回復,不是評論區回復,
資料獲取加技術抱團,點擊 關注👇🏻👇🏻👇🏻
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/303310.html
標籤:java
