Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
涂亚平
/
subsidy
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 05c3ab8d
authored
Aug 04, 2022
by
邓敏
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '2.7.1人脸识别版本' into websocker
2 parents
99ef83c5
2db05a18
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
51 changed files
with
536 additions
and
177 deletions
src/main/java/com/subsidy/controller/AdministerController.java
src/main/java/com/subsidy/controller/AnsweringQuestionController.java
src/main/java/com/subsidy/controller/CategoryController.java
src/main/java/com/subsidy/controller/ClassDictController.java
src/main/java/com/subsidy/controller/CompanyDictController.java
src/main/java/com/subsidy/controller/ExerciseDictController.java
src/main/java/com/subsidy/controller/ImageCheckRecordController.java
src/main/java/com/subsidy/controller/MemberController.java
src/main/java/com/subsidy/controller/SignInRecordController.java
src/main/java/com/subsidy/controller/VodPlayHistoryController.java
src/main/java/com/subsidy/dto/image/CheckResultDTO.java
src/main/java/com/subsidy/dto/image/ImageCheckDTO.java
src/main/java/com/subsidy/dto/member/GetMemberSignInfoDTO.java
src/main/java/com/subsidy/mapper/CategoryMapper.java
src/main/java/com/subsidy/mapper/ImageCheckRecordMapper.java
src/main/java/com/subsidy/mapper/VodDictMapper.java
src/main/java/com/subsidy/model/CategoryDO.java
src/main/java/com/subsidy/model/ClassDictDO.java
src/main/java/com/subsidy/model/CompanyDictDO.java
src/main/java/com/subsidy/model/ImageCheckRecordDO.java
src/main/java/com/subsidy/model/SignInRecordDO.java
src/main/java/com/subsidy/service/AdministerService.java
src/main/java/com/subsidy/service/CategoryService.java
src/main/java/com/subsidy/service/CompanyDictService.java
src/main/java/com/subsidy/service/ImageCheckRecordService.java
src/main/java/com/subsidy/service/VodPlayHistoryService.java
src/main/java/com/subsidy/service/impl/ActivityDetectionServiceImpl.java
src/main/java/com/subsidy/service/impl/AdministerServiceImpl.java
src/main/java/com/subsidy/service/impl/CategoryServiceImpl.java
src/main/java/com/subsidy/service/impl/CompanyDictServiceImpl.java
src/main/java/com/subsidy/service/impl/ImageCheckRecordServiceImpl.java
src/main/java/com/subsidy/service/impl/SignInRecordServiceImpl.java
src/main/java/com/subsidy/service/impl/VodPlayHistoryServiceImpl.java
src/main/java/com/subsidy/util/ExcelFormatUtils.java
src/main/java/com/subsidy/util/IpAddressUtil.java
src/main/java/com/subsidy/util/excel/ExcelUtil.java
src/main/java/com/subsidy/vo/administer/ImageCheckDetailVO.java
src/main/java/com/subsidy/vo/administer/ManageMemberVO.java
src/main/java/com/subsidy/vo/catagory/GetCategoriesVO.java
src/main/java/com/subsidy/vo/image/CheckImageResultVO.java
src/main/java/com/subsidy/vo/image/GetMemberCheckDetailVO.java
src/main/java/com/subsidy/vo/member/ClassSignVO.java
src/main/java/com/subsidy/vo/member/GetMemberSignInfoVO.java
src/main/java/com/subsidy/vo/token/CheckResultVO.java
src/main/java/com/subsidy/vo/token/SendResultVO.java
src/main/resources/code.properties
src/main/resources/mapper/CategoryMapper.xml
src/main/resources/mapper/ImageCheckRecordMapper.xml
src/main/resources/mapper/MemberMapper.xml
src/main/resources/mapper/VodDictMapper.xml
src/main/resources/mybatis-plus.properties
src/main/java/com/subsidy/controller/AdministerController.java
View file @
05c3ab8
...
...
@@ -5,10 +5,7 @@ import com.subsidy.common.ResponseData;
import
com.subsidy.common.ResponseVO
;
import
com.subsidy.common.interceptor.LoginRequired
;
import
com.subsidy.dto.administer.*
;
import
com.subsidy.model.AdministerDO
;
import
com.subsidy.model.ExerciseDoneHistoryDO
;
import
com.subsidy.model.ExerciseDoneResultDO
;
import
com.subsidy.model.MemberDO
;
import
com.subsidy.model.*
;
import
com.subsidy.service.AdministerService
;
import
com.subsidy.util.ConstantUtils
;
import
io.swagger.annotations.Api
;
...
...
@@ -91,7 +88,7 @@ public class AdministerController {
@PostMapping
(
"classSummary"
)
@ApiOperation
(
"班级详情--数据概览 id 班级id "
)
@LoginRequired
//
@LoginRequired
public
ResponseVO
classSummary
(
@RequestBody
ClassDetailDTO
classDetailDTO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
administerService
.
classSummary
(
classDetailDTO
));
}
...
...
@@ -233,6 +230,12 @@ public class AdministerController {
return
ResponseData
.
generateCreatedResponse
(
0
,
administerService
.
imageCheckDetail
(
classDetailDTO
));
}
@PostMapping
(
"getMemberCheckDetail"
)
@ApiOperation
(
"查看某个学生的验证详情 memberId 学员id classId"
)
@LoginRequired
public
ResponseVO
getMemberCheckDetail
(
@RequestBody
ImageCheckRecordDO
imageCheckRecordDO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
administerService
.
getMemberCheckDetail
(
imageCheckRecordDO
));
}
@PostMapping
(
"exportZip"
)
@ApiOperation
(
"下载压缩包 id 班级id"
)
...
...
@@ -257,9 +260,17 @@ public class AdministerController {
}
@PostMapping
(
"manageMember"
)
@ApiOperation
(
"用户管理 {pageSize pageNum userName:名字
【废弃】
}"
)
@ApiOperation
(
"用户管理 {pageSize pageNum userName:名字 }"
)
@LoginRequired
public
ResponseVO
manageMember
(
@RequestBody
ManageMemberDTO
manageMemberDTO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
administerService
.
manageMember
(
manageMemberDTO
));
}
@PostMapping
(
"exportManageMember"
)
@ApiOperation
(
"导出认证信息 {pageSize pageNum userName:名字 } "
)
@LoginRequired
public
void
exportManageMember
(
@RequestBody
ManageMemberDTO
manageMemberDTO
){
administerService
.
exportManageMember
(
manageMemberDTO
);
}
}
src/main/java/com/subsidy/controller/AnsweringQuestionController.java
View file @
05c3ab8
...
...
@@ -10,6 +10,7 @@ import com.subsidy.service.AnsweringQuestionService;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cache.annotation.CachePut
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
...
@@ -41,6 +42,7 @@ public class AnsweringQuestionController {
@PostMapping
(
"addQuestion"
)
@ApiOperation
(
"新增答疑 {classId askId title}"
)
@LoginRequired
@CachePut
(
value
=
"ResultData"
,
key
=
"'classId_'+#answeringQuestionDO.getClassId()"
)
public
ResponseVO
addQuestion
(
@RequestBody
AnsweringQuestionDO
answeringQuestionDO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
answeringQuestionService
.
addQuestion
(
answeringQuestionDO
));
}
...
...
@@ -48,6 +50,7 @@ public class AnsweringQuestionController {
@PostMapping
(
"deleteQuestion"
)
@ApiOperation
(
" 删除答疑 {id}"
)
@LoginRequired
@CachePut
(
value
=
"ResultData"
,
key
=
"'classId_'+#answeringQuestionDO.getClassId()"
)
public
ResponseVO
deleteQuestion
(
@RequestBody
AnsweringQuestionDO
answeringQuestionDO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
answeringQuestionService
.
deleteQuestion
(
answeringQuestionDO
));
}
...
...
@@ -55,6 +58,7 @@ public class AnsweringQuestionController {
@PostMapping
(
"updateQuestion"
)
@ApiOperation
(
"编辑答疑 {id answerId answer}"
)
@LoginRequired
@CachePut
(
value
=
"ResultData"
,
key
=
"'classId_'+#answeringQuestionDO.getClassId()"
)
public
ResponseVO
updateQuestion
(
@RequestBody
AnsweringQuestionDO
answeringQuestionDO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
answeringQuestionService
.
updateQuestion
(
answeringQuestionDO
));
}
...
...
src/main/java/com/subsidy/controller/CategoryController.java
View file @
05c3ab8
...
...
@@ -8,6 +8,7 @@ import com.subsidy.dto.category.GetCategoriesDTO;
import
com.subsidy.model.CategoryDO
;
import
com.subsidy.service.CategoryService
;
import
com.subsidy.util.ConstantUtils
;
import
com.subsidy.vo.catagory.GetCategoriesVO
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -25,7 +26,7 @@ import org.springframework.web.bind.annotation.RestController;
* @since 2021-10-11
*/
@RestController
@Api
(
tags
=
"
类目
"
)
@Api
(
tags
=
"
行业领域
"
)
@RequestMapping
(
"/category"
)
public
class
CategoryController
{
...
...
@@ -33,37 +34,37 @@ public class CategoryController {
private
CategoryService
categoryService
;
@PostMapping
(
"getCategories"
)
@ApiOperation
(
"查询
类目
name 类目名称 companyId pageSize pageNum"
)
@ApiOperation
(
"查询
行业领域
name 类目名称 companyId pageSize pageNum"
)
@LoginRequired
public
ResponseVO
getCategories
(
@RequestBody
GetCategoriesDTO
getCategoriesDTO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
categoryService
.
getCategories
(
getCategoriesDTO
));
}
@PostMapping
(
"getAll"
)
@ApiOperation
(
"查询所有类目 companyId"
)
@ApiOperation
(
"查询所有类目
【是否还有用?】
companyId"
)
public
ResponseVO
getAll
(
@RequestBody
GetCategoriesDTO
getCategoriesDTO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
categoryService
.
getAll
(
getCategoriesDTO
));
}
@PostMapping
(
"addCategory"
)
@ApiOperation
(
"新增
类目 name companyId
"
)
@ApiOperation
(
"新增
行业领域 name companyId categoryDOS[name 行业领域名称]
"
)
@LoginRequired
public
ResponseVO
addCategory
(
@RequestBody
CategoryDO
categoryD
O
){
return
ResponseData
.
generateCreatedResponse
(
0
,
categoryService
.
addCategory
(
categoryD
O
));
public
ResponseVO
addCategory
(
@RequestBody
GetCategoriesVO
getCategoriesV
O
){
return
ResponseData
.
generateCreatedResponse
(
0
,
categoryService
.
addCategory
(
getCategoriesV
O
));
}
@PostMapping
(
"deleteCategory"
)
@ApiOperation
(
"删除
类目
id"
)
@ApiOperation
(
"删除
一级行业领域
id"
)
@LoginRequired
public
ResponseVO
deleteCategory
(
@RequestBody
CategoryDO
categoryDO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
categoryService
.
deleteCategory
(
categoryDO
));
}
@PostMapping
(
"updateCategory"
)
@ApiOperation
(
"修改
类目 id name companyId
"
)
@ApiOperation
(
"修改
行业领域 id name companyId categoryDOS[name 行业领域名称]
"
)
@LoginRequired
public
ResponseVO
updateCategory
(
@RequestBody
CategoryDO
categoryD
O
){
return
ResponseData
.
generateCreatedResponse
(
0
,
categoryService
.
updateCategory
(
categoryD
O
));
public
ResponseVO
updateCategory
(
@RequestBody
GetCategoriesVO
getCategoriesV
O
){
return
ResponseData
.
generateCreatedResponse
(
0
,
categoryService
.
updateCategory
(
getCategoriesV
O
));
}
}
src/main/java/com/subsidy/controller/ClassDictController.java
View file @
05c3ab8
...
...
@@ -16,6 +16,7 @@ import com.subsidy.util.ConstantUtils;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cache.annotation.CachePut
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
...
@@ -59,7 +60,10 @@ public class ClassDictController {
}
@PostMapping
(
"updateClass"
)
@ApiOperation
(
"修改班级 id companyId className classTypeId startDate endDate"
)
@ApiOperation
(
"修改班级 id className classTypeId startDate endDate isOrder 是否按顺序播放 isFastPlay 是否允许快进 "
+
"testRule:测试规则 limitHour 学习上限时长 imageClassCheck:首次进入班级时人脸验证 imageTestCheck:测试前人脸识别验证"
+
"activityDetection:活跃度检测开启/关闭 activityDetectionMethod:活跃度检测方式 firstDragAllowed:首次播放允许拖曳"
+
"firstSpeedAllowed:首次播放允许倍速 playSnap 课程抓拍 "
)
@LoginRequired
public
ResponseVO
updateClass
(
@RequestBody
ClassDictDO
classDictDO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
classDictService
.
updateClass
(
classDictDO
));
...
...
src/main/java/com/subsidy/controller/CompanyDictController.java
View file @
05c3ab8
...
...
@@ -57,12 +57,28 @@ public class CompanyDictController {
}
@PostMapping
(
"updateCompany"
)
@ApiOperation
(
"修改企业 id superviseName 第三方监管名称 accountName:账号 logo companyName:企业名称 address 企业所在地 shortName 简称 banner:标语 field[]:领域 role 1:超级管理员 2:普通成员"
)
@ApiOperation
(
"修改企业 id superviseName 第三方监管名称 accountName:账号 logo companyName:企业名称 address 企业所在地 shortName 简称 "
+
"banner:标语 field[]:领域 role 1:超级管理员 2:普通成员 "
)
@LoginRequired
public
ResponseVO
updateAdminister
(
@RequestBody
AddCompanyDTO
addCompanyDTO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
companyDictService
.
updateAdminister
(
addCompanyDTO
));
}
@PostMapping
(
"updateCompanySettings"
)
@ApiOperation
(
"修改企业设置 id timeLimit:上课时间不晚于23:30,不早于6:30"
+
"ipAddressRecord: 签到时记录IP地址 deviceNoRecord: 设备类型"
)
@LoginRequired
public
ResponseVO
updateCompanySettings
(
@RequestBody
CompanyDictDO
companyDictDO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
companyDictService
.
updateCompanySettings
(
companyDictDO
));
}
@PostMapping
(
"getCompanyInfo"
)
@ApiOperation
(
"获取公司配置信息 id "
)
@LoginRequired
public
ResponseVO
getCompanyInfo
(
@RequestBody
CompanyDictDO
companyDictDO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
companyDictService
.
getCompanyInfo
(
companyDictDO
));
}
@PostMapping
(
"getAllCompany"
)
@ApiOperation
(
"获取全部企业 {companyName}"
)
@LoginRequired
...
...
src/main/java/com/subsidy/controller/ExerciseDictController.java
View file @
05c3ab8
...
...
@@ -15,6 +15,7 @@ import com.subsidy.util.ConstantUtils;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cache.annotation.CachePut
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
...
@@ -61,6 +62,7 @@ public class ExerciseDictController {
@ApiOperation
(
"提交答案 {paperId 卷子id memberId 成员id classId课程 courseId 课程id memberExerciseVOS [ id selectAnswer ] length:做题时长} "
)
@LoginRequired
@TimeRequired
@CachePut
(
value
=
"ResultData"
,
key
=
"'classId_'+#submitDTO.getClassId()"
)
public
ResponseVO
submit
(
@RequestBody
SubmitDTO
submitDTO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
exerciseDictService
.
submit
(
submitDTO
));
}
...
...
src/main/java/com/subsidy/controller/ImageCheckRecordController.java
View file @
05c3ab8
...
...
@@ -4,6 +4,8 @@ package com.subsidy.controller;
import
com.subsidy.common.ResponseData
;
import
com.subsidy.common.ResponseVO
;
import
com.subsidy.common.interceptor.LoginRequired
;
import
com.subsidy.common.interceptor.TimeRequired
;
import
com.subsidy.dto.image.CheckResultDTO
;
import
com.subsidy.dto.image.ImageCheckDTO
;
import
com.subsidy.model.ImageCheckRecordDO
;
import
com.subsidy.service.ImageCheckRecordService
;
...
...
@@ -41,11 +43,37 @@ public class ImageCheckRecordController {
}
@PostMapping
(
"imageCheck"
)
@ApiOperation
(
"人身核验 id 用户id nonce "
)
@ApiOperation
(
"课程/测评人身核验(权威库:身份证) PC端 id 用户id classId 班级id "
)
@TimeRequired
public
ResponseVO
imageCheck
(
@RequestBody
ImageCheckDTO
imageCheckDTO
)
throws
Exception
{
return
ResponseData
.
generateCreatedResponse
(
0
,
imageCheckRecordService
.
imageCheck
(
imageCheckDTO
));
}
@PostMapping
(
"h5ImageCheck"
)
@ApiOperation
(
"课程/测评人脸核验(权威库:身份证) 微信浮层H5 id 用户id classId 班级id"
)
@TimeRequired
public
ResponseVO
h5CheckResult
(
@RequestBody
ImageCheckDTO
imageCheckDTO
)
throws
Exception
{
return
ResponseData
.
generateCreatedResponse
(
0
,
imageCheckRecordService
.
h5CheckResult
(
imageCheckDTO
));
}
@PostMapping
(
"loginCheck"
)
@ApiOperation
(
"签到页做人脸核验 (权威库:身份证) PC端 id 用户id"
)
@TimeRequired
public
ResponseVO
loginCheck
(
@RequestBody
ImageCheckDTO
imageCheckDTO
)
throws
Exception
{
return
ResponseData
.
generateCreatedResponse
(
0
,
imageCheckRecordService
.
loginCheck
(
imageCheckDTO
));
}
@PostMapping
(
"h5LoginCheck"
)
@ApiOperation
(
"签到页做人脸核验 (权威库:身份证) PC端 id 用户id"
)
@TimeRequired
public
ResponseVO
h5LoginCheck
(
@RequestBody
ImageCheckDTO
imageCheckDTO
)
throws
Exception
{
return
ResponseData
.
generateCreatedResponse
(
0
,
imageCheckRecordService
.
h5LoginCheck
(
imageCheckDTO
));
}
@PostMapping
(
"checkResult"
)
@ApiOperation
(
"人脸验证结果 存图片 id 订单号 "
)
public
ResponseVO
checkResult
(
@RequestBody
CheckResultDTO
checkResultDTO
)
throws
Exception
{
return
ResponseData
.
generateCreatedResponse
(
0
,
imageCheckRecordService
.
checkResult
(
checkResultDTO
));
}
}
src/main/java/com/subsidy/controller/MemberController.java
View file @
05c3ab8
...
...
@@ -110,7 +110,7 @@ public class MemberController {
@PostMapping
(
"myCourses"
)
@ApiOperation
(
"手机端:我的学习--课程 memberId 学员id status 状态 0:全部 1:进行中 2:待开始 3:已完成 "
)
//
@LoginRequired
@LoginRequired
@TimeRequired
public
ResponseVO
myCourses
(
@RequestBody
MyCoursesDTO
myCoursesDTO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
memberService
.
myCourses
(
myCoursesDTO
));
...
...
@@ -118,7 +118,7 @@ public class MemberController {
@PostMapping
(
"contentVod"
)
@ApiOperation
(
"手机端:目录+视频 classId 班级id courseId 课程 memberId 学员id"
)
//
@LoginRequired
@LoginRequired
@TimeRequired
public
ResponseVO
contentVod
(
@RequestBody
ContentMemberDTO
contentVodDTO
){
return
ResponseData
.
generateCreatedResponse
(
0
,
memberService
.
contentVod
(
contentVodDTO
));
...
...
src/main/java/com/subsidy/controller/SignInRecordController.java
View file @
05c3ab8
...
...
@@ -13,6 +13,7 @@ import com.subsidy.util.ConstantUtils;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cache.annotation.CachePut
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
...
@@ -35,16 +36,17 @@ public class SignInRecordController {
private
SignInRecordService
signInRecordService
;
@PostMapping
(
"getMemberSignInfo"
)
@ApiOperation
(
"获取某个成员的签到记录 id 成员id pageSize pageNum"
)
@ApiOperation
(
"获取某个成员的签到记录 id 成员id
classId 班级id
pageSize pageNum"
)
@LoginRequired
public
ResponseVO
getMemberSignInfo
(
@RequestBody
GetMemberSignInfoDTO
getMemberSignInfoDTO
)
{
return
ResponseData
.
generateCreatedResponse
(
0
,
signInRecordService
.
getMemberSignInfo
(
getMemberSignInfoDTO
));
}
@PostMapping
(
"signIn"
)
@ApiOperation
(
"签到 memberId"
)
@LoginRequired
@ApiOperation
(
"签到 memberId
deviceNo:设备号
"
)
//
@LoginRequired
@TimeRequired
@CachePut
(
value
=
"ResultData"
,
key
=
"'classId_'+#signInRecordDO.getClassId()"
)
public
ResponseVO
signIn
(
@RequestBody
SignInRecordDO
signInRecordDO
)
{
return
ResponseData
.
generateCreatedResponse
(
0
,
signInRecordService
.
signIn
(
signInRecordDO
));
}
...
...
@@ -58,7 +60,7 @@ public class SignInRecordController {
@PostMapping
(
"signInStatus"
)
@ApiOperation
(
"判断学生当天有没有打卡 {memberId 学生id}"
)
@LoginRequired
//
@LoginRequired
@TimeRequired
public
ResponseVO
signInStatus
(
@RequestBody
SignInRecordDO
signInRecordDO
)
{
return
ResponseData
.
generateCreatedResponse
(
0
,
signInRecordService
.
signInStatus
(
signInRecordDO
));
...
...
src/main/java/com/subsidy/controller/VodPlayHistoryController.java
View file @
05c3ab8
...
...
@@ -80,7 +80,6 @@ public class VodPlayHistoryController {
vodPlayHistoryService
.
playLengthFix
(
remainSecondsDTO
);
}
@PostMapping
(
"testPlays"
)
@ApiOperation
(
"解决有交叉时间的数据"
)
public
ResponseVO
testPlays
(
@RequestBody
VodPlayHistoryDO
vodPlayHistoryDO
){
...
...
src/main/java/com/subsidy/dto/image/CheckResultDTO.java
0 → 100644
View file @
05c3ab8
package
com
.
subsidy
.
dto
.
image
;
import
lombok.Data
;
@Data
public
class
CheckResultDTO
{
private
String
id
;
}
src/main/java/com/subsidy/dto/image/ImageCheckDTO.java
View file @
05c3ab8
...
...
@@ -7,12 +7,6 @@ public class ImageCheckDTO {
private
Long
id
;
private
String
imageBase64
;
private
Long
classId
;
private
Long
paperId
;
private
String
nonce
;
}
src/main/java/com/subsidy/dto/member/GetMemberSignInfoDTO.java
View file @
05c3ab8
...
...
@@ -9,6 +9,8 @@ public class GetMemberSignInfoDTO {
private
Integer
pageNum
;
private
Long
classId
;
private
Long
id
;
}
src/main/java/com/subsidy/mapper/CategoryMapper.java
View file @
05c3ab8
package
com
.
subsidy
.
mapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.subsidy.model.CategoryDO
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.subsidy.vo.catagory.GetCategoriesVO
;
import
org.springframework.stereotype.Repository
;
import
java.util.List
;
...
...
@@ -19,8 +21,15 @@ public interface CategoryMapper extends BaseMapper<CategoryDO> {
/**
* 查看某个课程下的所有
类目
* 查看某个课程下的所有
行业领域
*/
List
<
CategoryDO
>
queryCourseCategory
(
Long
courseId
);
/**
* 查看行业领域
* 公司id为空的话就查平台的,否则传公司的行业领域
*/
IPage
<
GetCategoriesVO
>
getCategories
(
IPage
page
,
Long
companyId
,
String
name
);
}
src/main/java/com/subsidy/mapper/ImageCheckRecordMapper.java
View file @
05c3ab8
...
...
@@ -2,8 +2,11 @@ package com.subsidy.mapper;
import
com.subsidy.model.ImageCheckRecordDO
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.subsidy.vo.image.GetMemberCheckDetailVO
;
import
org.springframework.stereotype.Repository
;
import
java.util.List
;
/**
* <p>
* 实名验证记录表 Mapper 接口
...
...
@@ -12,7 +15,13 @@ import org.springframework.stereotype.Repository;
* @author DengMin
* @since 2022-07-14
*/
@Repository
@Repository
public
interface
ImageCheckRecordMapper
extends
BaseMapper
<
ImageCheckRecordDO
>
{
/**
* 获取某个人某个课程的验证记录
*/
List
<
GetMemberCheckDetailVO
>
getMemberCheckDetail
(
Long
memberId
,
Long
classId
);
}
src/main/java/com/subsidy/mapper/VodDictMapper.java
View file @
05c3ab8
...
...
@@ -44,5 +44,5 @@ public interface VodDictMapper extends BaseMapper<VodDictDO> {
/**
* 重复数据查找
*/
List
<
VodPlayStateVO
>
testPlays
(
Long
memberId
);
List
<
VodPlayStateVO
>
testPlays
(
Long
memberId
,
Long
classId
);
}
src/main/java/com/subsidy/model/CategoryDO.java
View file @
05c3ab8
...
...
@@ -26,6 +26,11 @@ public class CategoryDO extends BaseModel {
private
Long
id
;
/**
* 父id
*/
private
Long
parentId
;
/**
* 企业id
*/
private
Long
companyId
;
...
...
src/main/java/com/subsidy/model/ClassDictDO.java
View file @
05c3ab8
...
...
@@ -68,10 +68,10 @@ public class ClassDictDO extends BaseModel {
*/
private
Integer
isFastPlay
;
/
//
**
//
* 班级状态
//
*/
//
private String openStatus;
/**
* 班级状态
*/
private
String
openStatus
;
/**
* 测试规则
...
...
@@ -118,6 +118,4 @@ public class ClassDictDO extends BaseModel {
*/
private
Integer
playSnap
;
}
src/main/java/com/subsidy/model/CompanyDictDO.java
View file @
05c3ab8
...
...
@@ -60,4 +60,20 @@ public class CompanyDictDO extends BaseModel {
*/
private
String
superviseName
;
/**
* 上课时间不晚于23:30,不早于6:30
*/
private
Integer
timeLimit
;
/**
* 签到时记录IP地址
*/
private
Integer
ipAddressRecord
;
/**
* 签到时记录设备型号
*/
private
Integer
deviceNoRecord
;
}
src/main/java/com/subsidy/model/ImageCheckRecordDO.java
View file @
05c3ab8
...
...
@@ -26,7 +26,7 @@ public class ImageCheckRecordDO extends BaseModel {
private
Long
id
;
/**
* 班级
id
* 班级
*/
private
Long
classId
;
...
...
@@ -36,12 +36,39 @@ public class ImageCheckRecordDO extends BaseModel {
private
Long
memberId
;
/**
*
请求id
*
活体检测得分
*/
private
String
requestId
;
private
String
liveRate
;
/**
*
图片地址
*
人脸检测得分
*/
private
String
imageUrl
;
private
String
similarity
;
/**
* 刷脸时间
*/
private
String
occurredTime
;
/**
* 图片
*/
private
String
photo
;
/**
* 流水号
*/
private
String
bizSeqNo
;
/**
* 检测类型 检测类型 1,权威库 0照片比对
*/
private
Integer
checkType
;
/**
* 检测地点 1,签到页 0 班级内
*/
private
Integer
checkPlace
;
}
src/main/java/com/subsidy/model/SignInRecordDO.java
View file @
05c3ab8
...
...
@@ -46,5 +46,15 @@ public class SignInRecordDO extends BaseModel {
@ExcelColumnUtil
(
value
=
"sign_in_date"
,
col
=
4
)
private
LocalDateTime
signInDate
;
/**
* 地址
*/
private
String
ipAddress
;
/**
* 设备号
*/
private
String
deviceNo
;
}
src/main/java/com/subsidy/service/AdministerService.java
View file @
05c3ab8
...
...
@@ -6,8 +6,10 @@ import com.subsidy.dto.administer.*;
import
com.subsidy.model.AdministerDO
;
import
com.subsidy.model.ExerciseDoneHistoryDO
;
import
com.subsidy.model.ExerciseDoneResultDO
;
import
com.subsidy.model.ImageCheckRecordDO
;
import
com.subsidy.vo.administer.*
;
import
com.subsidy.vo.classdict.ClassDetailVO
;
import
com.subsidy.vo.image.GetMemberCheckDetailVO
;
import
com.subsidy.vo.member.ClassSignVO
;
import
com.subsidy.vo.sign.AnswerRecordVO
;
import
org.springframework.web.multipart.MultipartFile
;
...
...
@@ -74,6 +76,8 @@ public interface AdministerService extends IService<AdministerDO> {
IPage
<
ImageCheckDetailVO
>
imageCheckDetail
(
ClassDetailDTO
classDetailDTO
);
List
<
GetMemberCheckDetailVO
>
getMemberCheckDetail
(
ImageCheckRecordDO
imageCheckRecordDO
);
void
export
(
ClassDetailDTO
classDetailDTO
)
throws
Exception
;
IPage
memberStudy
(
MemberStudyLogDTO
memberStudyLogDTO
);
...
...
@@ -83,4 +87,6 @@ public interface AdministerService extends IService<AdministerDO> {
String
importMember
(
Long
companyId
,
MultipartFile
multipartFile
)
throws
Exception
;
IPage
<
ManageMemberVO
>
manageMember
(
ManageMemberDTO
manageMemberDTO
);
void
exportManageMember
(
ManageMemberDTO
manageMemberDTO
);
}
src/main/java/com/subsidy/service/CategoryService.java
View file @
05c3ab8
...
...
@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import
com.subsidy.dto.category.GetCategoriesDTO
;
import
com.subsidy.model.CategoryDO
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.subsidy.vo.catagory.GetCategoriesVO
;
import
java.util.List
;
...
...
@@ -17,13 +18,13 @@ import java.util.List;
*/
public
interface
CategoryService
extends
IService
<
CategoryDO
>
{
IPage
<
CategoryD
O
>
getCategories
(
GetCategoriesDTO
getCategoriesDTO
);
IPage
<
GetCategoriesV
O
>
getCategories
(
GetCategoriesDTO
getCategoriesDTO
);
List
<
CategoryDO
>
getAll
(
GetCategoriesDTO
getCategoriesDTO
);
String
addCategory
(
CategoryDO
categoryD
O
);
String
addCategory
(
GetCategoriesVO
getCategoriesV
O
);
String
deleteCategory
(
CategoryDO
categoryDO
);
String
updateCategory
(
CategoryDO
categoryD
O
);
String
updateCategory
(
GetCategoriesVO
getCategoriesV
O
);
}
src/main/java/com/subsidy/service/CompanyDictService.java
View file @
05c3ab8
...
...
@@ -33,6 +33,10 @@ public interface CompanyDictService extends IService<CompanyDictDO> {
String
updateAdminister
(
AddCompanyDTO
addCompanyDTO
);
String
updateCompanySettings
(
CompanyDictDO
companyDictDO
);
CompanyDictDO
getCompanyInfo
(
CompanyDictDO
companyDictDO
);
List
<
GetAllCompanyVO
>
getAllCompany
(
CompanyDictDO
companyDictDO
);
IPage
<
GetCompanyMembersVO
>
getCompanyMembers
(
GetCompanyMembersDTO
getCompanyMembersDTO
);
...
...
src/main/java/com/subsidy/service/ImageCheckRecordService.java
View file @
05c3ab8
package
com
.
subsidy
.
service
;
import
com.subsidy.dto.image.CheckResultDTO
;
import
com.subsidy.dto.image.ImageCheckDTO
;
import
com.subsidy.model.ImageCheckRecordDO
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.subsidy.vo.token.SendIdCardInfoVO
;
import
java.util.List
;
...
...
@@ -18,6 +20,14 @@ public interface ImageCheckRecordService extends IService<ImageCheckRecordDO> {
List
<
ImageCheckRecordDO
>
getImageCheckHistory
(
ImageCheckRecordDO
imageCheckRecordDO
);
String
imageCheck
(
ImageCheckDTO
imageCheckDTO
)
throws
Exception
;
SendIdCardInfoVO
imageCheck
(
ImageCheckDTO
imageCheckDTO
)
throws
Exception
;
SendIdCardInfoVO
h5CheckResult
(
ImageCheckDTO
imageCheckDTO
)
throws
Exception
;
SendIdCardInfoVO
loginCheck
(
ImageCheckDTO
imageCheckDTO
)
throws
Exception
;
SendIdCardInfoVO
h5LoginCheck
(
ImageCheckDTO
imageCheckDTO
)
throws
Exception
;
ImageCheckRecordDO
checkResult
(
CheckResultDTO
checkResultDTO
)
throws
Exception
;
}
src/main/java/com/subsidy/service/VodPlayHistoryService.java
View file @
05c3ab8
...
...
@@ -8,6 +8,7 @@ import com.subsidy.model.VodPlayHistoryDO;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.subsidy.vo.vod.VodPlayStateVO
;
import
java.util.HashSet
;
import
java.util.List
;
/**
...
...
@@ -32,5 +33,5 @@ public interface VodPlayHistoryService extends IService<VodPlayHistoryDO> {
void
playLengthFix
(
RemainSecondsDTO
remainSecondsDTO
);
Lis
t
<
Long
>
testPlays
(
VodPlayHistoryDO
vodPlayHistoryDO
);
HashSe
t
<
Long
>
testPlays
(
VodPlayHistoryDO
vodPlayHistoryDO
);
}
src/main/java/com/subsidy/service/impl/ActivityDetectionServiceImpl.java
View file @
05c3ab8
...
...
@@ -37,10 +37,12 @@ public class ActivityDetectionServiceImpl extends ServiceImpl<ActivityDetectionM
activityDetectionDO
.
setMemberId
(
verifyDTO
.
getMemberId
());
activityDetectionDO
.
setRequestId
(
resp
.
getRequestId
());
if
(
resp
.
getCaptchaCode
()==
1
){
//成功
activityDetectionDO
.
setStatus
(
1
);
this
.
baseMapper
.
insert
(
activityDetectionDO
);
return
ConstantUtils
.
SUCCESS_VERIFY
;
}
else
{
//失败
activityDetectionDO
.
setStatus
(
0
);
this
.
baseMapper
.
insert
(
activityDetectionDO
);
return
ConstantUtils
.
FAIL_VERIFY
;
...
...
@@ -48,7 +50,7 @@ public class ActivityDetectionServiceImpl extends ServiceImpl<ActivityDetectionM
}
catch
(
Exception
e
)
{
// System.out.println(e.toString());
}
return
null
;
return
ConstantUtils
.
SUCCESS_VERIFY
;
}
public
IPage
<
GetCheckHistoryVO
>
getCheckHistory
(
GetCheckHistoryDTO
getCheckHistoryDTO
){
...
...
src/main/java/com/subsidy/service/impl/AdministerServiceImpl.java
View file @
05c3ab8
This diff is collapsed.
Click to expand it.
src/main/java/com/subsidy/service/impl/CategoryServiceImpl.java
View file @
05c3ab8
...
...
@@ -10,6 +10,8 @@ import com.subsidy.mapper.CategoryMapper;
import
com.subsidy.service.CategoryService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.subsidy.util.ConstantUtils
;
import
com.subsidy.vo.catagory.GetCategoriesVO
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.stereotype.Service
;
...
...
@@ -26,20 +28,21 @@ import java.util.List;
@Service
public
class
CategoryServiceImpl
extends
ServiceImpl
<
CategoryMapper
,
CategoryDO
>
implements
CategoryService
{
public
IPage
<
CategoryD
O
>
getCategories
(
GetCategoriesDTO
getCategoriesDTO
)
{
public
IPage
<
GetCategoriesV
O
>
getCategories
(
GetCategoriesDTO
getCategoriesDTO
)
{
Page
pager
=
new
Page
(
getCategoriesDTO
.
getPageNum
(),
getCategoriesDTO
.
getPageSize
());
if
(
null
==
getCategoriesDTO
.
getCompanyId
())
{
return
this
.
baseMapper
.
selectPage
(
pager
,
new
QueryWrapper
<
CategoryDO
>()
.
lambda
()
.
like
(
CategoryDO:
:
getName
,
getCategoriesDTO
.
getName
())
.
isNull
(
CategoryDO:
:
getCompanyId
));
}
else
{
return
this
.
baseMapper
.
selectPage
(
pager
,
new
QueryWrapper
<
CategoryDO
>()
IPage
<
GetCategoriesVO
>
categoryDOIPage
=
this
.
baseMapper
.
getCategories
(
pager
,
getCategoriesDTO
.
getCompanyId
(),
getCategoriesDTO
.
getName
());
//二级行业领域
List
<
GetCategoriesVO
>
getCategoriesVOS
=
categoryDOIPage
.
getRecords
();
for
(
GetCategoriesVO
gcv
:
getCategoriesVOS
){
//找二级
List
<
CategoryDO
>
categoryDOS
=
this
.
baseMapper
.
selectList
(
new
QueryWrapper
<
CategoryDO
>()
.
lambda
()
.
like
(
CategoryDO:
:
getName
,
getCategoriesDTO
.
getName
())
.
eq
(
CategoryDO:
:
getCompanyId
,
getCategoriesDTO
.
getCompanyId
())
);
.
eq
(
CategoryDO:
:
getParentId
,
gcv
.
getId
()));
gcv
.
setCategoryDOS
(
categoryDOS
);
}
return
categoryDOIPage
;
}
...
...
@@ -56,48 +59,79 @@ public class CategoryServiceImpl extends ServiceImpl<CategoryMapper, CategoryDO>
}
}
public
String
addCategory
(
CategoryDO
categoryD
O
)
{
public
String
addCategory
(
GetCategoriesVO
getCategoriesV
O
)
{
int
count
;
if
(
null
==
categoryD
O
.
getCompanyId
())
{
if
(
null
==
getCategoriesV
O
.
getCompanyId
())
{
count
=
this
.
baseMapper
.
selectCount
(
new
QueryWrapper
<
CategoryDO
>()
.
lambda
()
.
like
(
CategoryDO:
:
getName
,
categoryD
O
.
getName
())
.
like
(
CategoryDO:
:
getName
,
getCategoriesV
O
.
getName
())
.
isNull
(
CategoryDO:
:
getCompanyId
));
}
else
{
count
=
this
.
baseMapper
.
selectCount
(
new
QueryWrapper
<
CategoryDO
>()
.
lambda
()
.
like
(
CategoryDO:
:
getName
,
categoryD
O
.
getName
())
.
eq
(
CategoryDO:
:
getCompanyId
,
categoryD
O
.
getCompanyId
()));
.
like
(
CategoryDO:
:
getName
,
getCategoriesV
O
.
getName
())
.
eq
(
CategoryDO:
:
getCompanyId
,
getCategoriesV
O
.
getCompanyId
()));
}
if
(
count
>
0
)
{
throw
new
HttpException
(
90001
);
}
//一级目录
CategoryDO
categoryDO
=
new
CategoryDO
();
BeanUtils
.
copyProperties
(
getCategoriesVO
,
categoryDO
);
this
.
baseMapper
.
insert
(
categoryDO
);
//二级目录
List
<
CategoryDO
>
categoryDOS
=
getCategoriesVO
.
getCategoryDOS
();
for
(
CategoryDO
cd
:
categoryDOS
){
cd
.
setCompanyId
(
getCategoriesVO
.
getCompanyId
());
cd
.
setParentId
(
categoryDO
.
getId
());
this
.
baseMapper
.
insert
(
cd
);
}
return
ConstantUtils
.
ADD_SUCCESS
;
}
public
String
deleteCategory
(
CategoryDO
categoryDO
)
{
this
.
baseMapper
.
deleteById
(
categoryDO
.
getId
());
this
.
baseMapper
.
delete
(
new
QueryWrapper
<
CategoryDO
>()
.
lambda
()
.
eq
(
CategoryDO:
:
getParentId
,
categoryDO
.
getId
()));
return
ConstantUtils
.
DELETE_SUCCESS
;
}
public
String
updateCategory
(
CategoryDO
categoryD
O
)
{
public
String
updateCategory
(
GetCategoriesVO
getCategoriesV
O
)
{
int
count
=
this
.
baseMapper
.
selectCount
(
new
QueryWrapper
<
CategoryDO
>()
.
lambda
()
.
eq
(
CategoryDO:
:
getName
,
categoryD
O
.
getName
())
.
eq
(
CategoryDO:
:
getCompanyId
,
categoryD
O
.
getCompanyId
())
.
ne
(
CategoryDO:
:
getId
,
categoryD
O
.
getId
()));
.
eq
(
CategoryDO:
:
getName
,
getCategoriesV
O
.
getName
())
.
eq
(
CategoryDO:
:
getCompanyId
,
getCategoriesV
O
.
getCompanyId
())
.
ne
(
CategoryDO:
:
getId
,
getCategoriesV
O
.
getId
()));
if
(
count
>
0
)
{
throw
new
HttpException
(
90001
);
}
CategoryDO
categoryDO
=
new
CategoryDO
();
BeanUtils
.
copyProperties
(
getCategoriesVO
,
categoryDO
);
this
.
baseMapper
.
updateById
(
categoryDO
);
CategoryDO
categoryDO1
=
this
.
baseMapper
.
selectById
(
categoryDO
.
getId
());
if
(
getCategoriesVO
.
getCategoryDOS
().
size
()>
0
){
this
.
baseMapper
.
delete
(
new
QueryWrapper
<
CategoryDO
>()
.
lambda
()
.
eq
(
CategoryDO:
:
getParentId
,
getCategoriesVO
.
getId
()));
List
<
CategoryDO
>
categoryDOS
=
getCategoriesVO
.
getCategoryDOS
();
for
(
CategoryDO
cd:
categoryDOS
){
cd
.
setParentId
(
getCategoriesVO
.
getId
());
cd
.
setCompanyId
(
categoryDO1
.
getCompanyId
());
this
.
baseMapper
.
insert
(
cd
);
}
}
return
ConstantUtils
.
SET_SUCCESS
;
}
...
...
src/main/java/com/subsidy/service/impl/CompanyDictServiceImpl.java
View file @
05c3ab8
...
...
@@ -279,13 +279,22 @@ public class CompanyDictServiceImpl extends ServiceImpl<CompanyDictMapper, Compa
return
ConstantUtils
.
SET_SUCCESS
;
}
public
String
updateCompanySettings
(
CompanyDictDO
companyDictDO
)
{
this
.
baseMapper
.
updateById
(
companyDictDO
);
return
ConstantUtils
.
SET_SUCCESS
;
}
public
CompanyDictDO
getCompanyInfo
(
CompanyDictDO
companyDictDO
)
{
return
this
.
baseMapper
.
selectById
(
companyDictDO
.
getId
());
}
public
List
<
GetAllCompanyVO
>
getAllCompany
(
CompanyDictDO
companyDictDO
)
{
return
this
.
baseMapper
.
getAllCompany
(
companyDictDO
);
}
public
IPage
<
GetCompanyMembersVO
>
getCompanyMembers
(
GetCompanyMembersDTO
getCompanyMembersDTO
)
{
Page
pager
=
new
Page
(
getCompanyMembersDTO
.
getPageNum
(),
getCompanyMembersDTO
.
getPageSize
());
return
this
.
baseMapper
.
getCompanyMembers
(
pager
,
getCompanyMembersDTO
.
getCompanyId
(),
getCompanyMembersDTO
.
getUserName
());
return
this
.
baseMapper
.
getCompanyMembers
(
pager
,
getCompanyMembersDTO
.
getCompanyId
(),
getCompanyMembersDTO
.
getUserName
());
}
@Override
...
...
@@ -344,17 +353,17 @@ public class CompanyDictServiceImpl extends ServiceImpl<CompanyDictMapper, Compa
//总数
Integer
total
=
memberMapper
.
selectCount
(
new
QueryWrapper
<
MemberDO
>()
.
lambda
()
.
eq
(
MemberDO:
:
getCompanyId
,
getCompanyMembersDTO
.
getCompanyId
()));
.
eq
(
MemberDO:
:
getCompanyId
,
getCompanyMembersDTO
.
getCompanyId
()));
memberSummaryVO
.
setTotal
(
total
);
//短信验证
Integer
smsCnt
=
memberMapper
.
selectCount
(
new
QueryWrapper
<
MemberDO
>()
.
lambda
()
.
eq
(
MemberDO:
:
getCompanyId
,
getCompanyMembersDTO
.
getCompanyId
())
.
eq
(
MemberDO:
:
getCompanyId
,
getCompanyMembersDTO
.
getCompanyId
())
.
isNull
(
MemberDO:
:
getFirstLogin
));
memberSummaryVO
.
setSmsCnt
(
smsCnt
);
memberSummaryVO
.
setImgCnt
(
total
-
smsCnt
);
memberSummaryVO
.
setImgCnt
(
total
-
smsCnt
);
return
memberSummaryVO
;
}
...
...
src/main/java/com/subsidy/service/impl/ImageCheckRecordServiceImpl.java
View file @
05c3ab8
This diff is collapsed.
Click to expand it.
src/main/java/com/subsidy/service/impl/SignInRecordServiceImpl.java
View file @
05c3ab8
...
...
@@ -21,6 +21,7 @@ import com.subsidy.model.VodDictDO;
import
com.subsidy.service.SignInRecordService
;
import
com.subsidy.util.ConstantUtils
;
import
com.subsidy.util.DateFormatUtil
;
import
com.subsidy.util.IpAddressUtil
;
import
com.subsidy.vo.member.GetMemberSignInfoVO
;
import
com.subsidy.vo.sign.DataViewVO
;
import
com.subsidy.vo.sign.SignInStatusVO
;
...
...
@@ -73,6 +74,7 @@ public class SignInRecordServiceImpl extends ServiceImpl<SignInRecordMapper, Sig
return
this
.
baseMapper
.
selectPage
(
pager
,
new
QueryWrapper
<
SignInRecordDO
>()
.
lambda
()
.
eq
(
SignInRecordDO:
:
getMemberId
,
getMemberSignInfoDTO
.
getId
())
.
eq
(
SignInRecordDO:
:
getClassId
,
getMemberSignInfoDTO
.
getClassId
())
.
orderByDesc
(
SignInRecordDO:
:
getCreateDate
));
}
...
...
@@ -99,12 +101,12 @@ public class SignInRecordServiceImpl extends ServiceImpl<SignInRecordMapper, Sig
this
.
baseMapper
.
deleteById
(
sign
.
getId
());
}
// signInRecordDO.setIpAddress(IpAddressUtil.getIpAddress());
signInRecordDO
.
setClassId
(
classDictDO
.
getId
());
signInRecordDO
.
setSignInDate
(
LocalDateTime
.
now
());
signInRecordDO
.
setCreateDate
(
LocalDateTime
.
now
());
this
.
baseMapper
.
insert
(
signInRecordDO
);
}
return
ConstantUtils
.
ADD_SUCCESS
;
}
...
...
src/main/java/com/subsidy/service/impl/VodPlayHistoryServiceImpl.java
View file @
05c3ab8
...
...
@@ -11,6 +11,7 @@ import com.subsidy.mapper.*;
import
com.subsidy.model.*
;
import
com.subsidy.service.VodPlayHistoryService
;
import
com.subsidy.util.ConstantUtils
;
import
com.subsidy.util.DateFormatUtil
;
import
com.subsidy.util.RedisUtil
;
import
com.subsidy.vo.vod.VodPlayStateVO
;
import
org.apache.commons.lang3.StringUtils
;
...
...
@@ -21,11 +22,7 @@ import org.springframework.stereotype.Service;
import
java.text.SimpleDateFormat
;
import
java.time.LocalDateTime
;
import
java.time.format.DateTimeFormatter
;
import
java.util.ArrayList
;
import
java.util.Arrays
;
import
java.util.LinkedHashMap
;
import
java.util.List
;
import
java.util.Random
;
import
java.util.*
;
/**
* <p>
...
...
@@ -81,7 +78,7 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
//查看当天这个人看了多少时间
Integer
total
=
vodPlayHistoryMapper
.
memberDailyStudyLength
(
memberDO
.
getId
());
if
(
total
==
classHourDictDO
.
getClassHour
()
*
3600
){
if
(
total
==
classHourDictDO
.
getClassHour
()
*
3600
)
{
throw
new
HttpException
(
13001
);
}
...
...
@@ -90,7 +87,7 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
int
playLength
=
classHourDictDO
.
getClassHour
()
*
3600
-
total
;
vodPlayHistoryDO
.
setPlayLength
(
playLength
);
vodPlayHistoryDO
.
setPlayCount
(
1
);
if
(
playLength
>
3
)
{
if
(
playLength
>
3
)
{
this
.
baseMapper
.
insert
(
vodPlayHistoryDO
);
}
throw
new
HttpException
(
13001
);
...
...
@@ -119,7 +116,7 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
//查看当天这个人看了多少时间
Integer
total
=
vodPlayHistoryMapper
.
memberDailyStudyLength
(
memberDO
.
getId
());
if
(
total
==
classHourDictDO
.
getClassHour
()
*
3600
){
if
(
total
==
classHourDictDO
.
getClassHour
()
*
3600
)
{
throw
new
HttpException
(
13001
);
}
...
...
@@ -128,7 +125,7 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
int
playLength
=
classHourDictDO
.
getClassHour
()
*
3600
-
total
;
vodPlayHistoryDO
.
setPlayLength
(
playLength
);
vodPlayHistoryDO
.
setPlayCount
(
1
);
if
(
playLength
>
3
)
{
if
(
playLength
>
3
)
{
this
.
baseMapper
.
insert
(
vodPlayHistoryDO
);
}
throw
new
HttpException
(
13001
);
...
...
@@ -631,39 +628,40 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
// }
}
public
Lis
t
<
Long
>
testPlays
(
VodPlayHistoryDO
vodPlayHistoryDO
)
{
public
HashSe
t
<
Long
>
testPlays
(
VodPlayHistoryDO
vodPlayHistoryDO
)
{
String
classIds
=
"
261
"
;
String
classIds
=
"
150,151,152,153,165,195,199,200,202,207,209,210,211,212,213,215,227,228,229,233,234,235,240,241,243,244,248,249,250,251,252,253,254,255,256,257,258,261,268,278,280,282,286,287,288,289,292,293,294,295,297,298,300,301,303,304,305,306
"
;
// String classIds = "122,150";
List
<
String
>
classIdArr
=
Arrays
.
asList
(
classIds
.
split
(
","
));
List
<
Long
>
result
=
new
ArrayLis
t
<>();
HashSet
<
Long
>
result
=
new
HashSe
t
<>();
for
(
String
classId
:
classIdArr
)
{
List
<
ClassMemberMappingDO
>
classMemberMappingDOS
=
classMemberMappingMapper
.
selectList
(
new
QueryWrapper
<
ClassMemberMappingDO
>()
.
lambda
()
.
eq
(
ClassMemberMappingDO:
:
getClassId
,
classId
));
for
(
ClassMemberMappingDO
classMemberMappingDO
:
classMemberMappingDOS
)
{
List
<
VodPlayStateVO
>
vodPlayStateVOS
=
vodDictMapper
.
testPlays
(
classMemberMappingDO
.
getMemberId
());
for
(
int
i
=
0
;
i
<
vodPlayStateVOS
.
size
();
i
++)
{
for
(
int
k
=
i
+
1
;
k
<
vodPlayStateVOS
.
size
();
k
++)
{
VodPlayStateVO
vodPlayStateVO
=
vodPlayStateVOS
.
get
(
k
);
VodPlayStateVO
vodPlayStateVO1
=
vodPlayStateVOS
.
get
(
i
);
if
(
vodPlayStateVO
.
getStartDate
().
after
(
vodPlayStateVO1
.
getStartDate
())
&&
vodPlayStateVO
.
getStartDate
().
before
(
vodPlayStateVO1
.
getEndDate
()))
{
System
.
out
.
println
(
"111111111"
+
vodPlayStateVO
);
List
<
VodPlayStateVO
>
vodPlayStateVOS
=
vodDictMapper
.
testPlays
(
classMemberMappingDO
.
getMemberId
(),
Long
.
valueOf
(
classId
));
for
(
int
i
=
0
;
i
<
vodPlayStateVOS
.
size
()
-
1
;
i
++)
{
VodPlayStateVO
vodPlayStateVO
=
vodPlayStateVOS
.
get
(
i
+
1
);
//后面
VodPlayStateVO
vodPlayStateVO1
=
vodPlayStateVOS
.
get
(
i
);
//前面
if
(
vodPlayStateVO1
.
getEndDate
().
getTime
()
-
3000
>
vodPlayStateVO
.
getStartDate
().
getTime
()
&&
vodPlayStateVO
.
getPlayLength
()
>=
3
)
{
//这一条数据有问题
System
.
out
.
println
(
"111111111111111111111"
+
vodPlayStateVO
);
//查看这个人 这个课程 当天的全部数据 按照createDate升序排序
// List<VodPlayHistoryDO> vodPlayHistoryDOS = this.baseMapper.getVodPlayDay(Long.valueOf(classId), vodPlayStateVO.getMemberId(), vodPlayStateVO.getEndDate());
//从第一条开始看,顺延减去第二条的playlength得到第二条的create_date 以此类推
// for (int l = 0; l < vodPlayHistoryDOS.size() - 1; l++) {
// VodPlayHistoryDO vph1 = vodPlayHistoryDOS.get(l);
// VodPlayHistoryDO vph2 = vodPlayHistoryDOS.get(l + 1);
// LocalDateTime dateTmp = vph1.getCreateDate().minusSeconds(-vph2.getPlayLength() - getRandom1_2());
// vph2.setCreateDate(dateTmp);
// this.baseMapper.updateById(vph2);
result
.
add
(
vodPlayStateVO
.
getId
());
// }
List
<
VodPlayHistoryDO
>
vodPlayHistoryDOS
=
this
.
baseMapper
.
getVodPlayDay
(
Long
.
valueOf
(
classId
),
classMemberMappingDO
.
getMemberId
(),
vodPlayStateVO
.
getStartDate
());
// //从第一条开始看,顺延减去第二条的playlength得到第二条的create_date 以此类推
for
(
int
l
=
0
;
l
<
vodPlayHistoryDOS
.
size
()
-
1
;
l
++)
{
VodPlayHistoryDO
vph1
=
vodPlayHistoryDOS
.
get
(
l
);
//第一条
if
(
l
==
0
){
vph1
.
setPlayDate
(
vph1
.
getCreateDate
());
}
VodPlayHistoryDO
vph2
=
vodPlayHistoryDOS
.
get
(
l
+
1
);
//第二条
LocalDateTime
dateTmp
=
vph1
.
getPlayDate
().
plusSeconds
(
vph2
.
getPlayLength
()+
getRandom1_2
());
vph2
.
setPlayDate
(
dateTmp
);
this
.
baseMapper
.
updateById
(
vph2
);
}
result
.
add
(
vodPlayStateVO
.
getId
());
// break;
}
}
}
...
...
@@ -678,42 +676,46 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
/**
* 3次签到 23400---28800
*/
public
Integer
_3times
()
{
public
Integer
_3times
()
{
return
new
Random
().
nextInt
(
28800
-
23400
+
1
)
+
23400
;
}
/**
* 4次签到 23400---28800
*/
public
Integer
_4times
()
{
public
Integer
_4times
()
{
return
new
Random
().
nextInt
(
6
*
60
*
60
-
48
*
6
*
60
+
1
)
+
48
*
6
*
60
;
}
/**
* 5次签到 23400---28800
*/
public
Integer
_5times
()
{
public
Integer
_5times
()
{
return
new
Random
().
nextInt
(
6
*
60
*
60
-
4
*
60
*
60
+
1
)
+
4
*
60
*
60
;
}
/**
* 6次签到 23400---28800
*/
public
Integer
_6times
()
{
public
Integer
_6times
()
{
return
new
Random
().
nextInt
(
6
*
60
*
60
-
32
*
6
*
60
+
1
)
+
32
*
60
*
6
;
}
/**
* 7次签到 23400---28800
*/
public
Integer
_7times
()
{
public
Integer
_7times
()
{
return
new
Random
().
nextInt
(
6
*
60
*
60
-
25
*
6
*
60
+
1
)
+
25
*
6
*
60
;
}
public
static
void
main
(
String
[]
args
)
{
public
static
void
main
(
String
[]
args
)
{
while
(
true
)
{
System
.
out
.
println
(
getRandom
());
System
.
out
.
println
(
getRandom1_2
());
}
// System.out.println(LocalDateTime.now());
// System.out.println(LocalDateTime.now().minusMinutes(3));
// int m = 0;
//
// int signInrecord = 4;
...
...
@@ -786,13 +788,12 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
//}
}
public
static
Integer
getRandom
()
{
public
static
Integer
getRandom
()
{
return
(
int
)
(
Math
.
random
()
*
3
/
2
+
5
);
}
public
static
Integer
getRandom1_2
()
{
public
static
Integer
getRandom1_2
()
{
return
(
int
)
(
Math
.
random
()
*
3
/
2
+
1
);
}
}
}
src/main/java/com/subsidy/util/ExcelFormatUtils.java
View file @
05c3ab8
...
...
@@ -8,7 +8,7 @@ public class ExcelFormatUtils {
public
static
final
List
<
String
>
memberList
=
Arrays
.
asList
(
"序号"
,
"成员名称"
,
"身份证号码"
,
"性别"
,
"账号"
,
"联系方式"
,
"签到次数"
,
"课程进度"
,
"学习时长(小时)"
,
"学习时长(分钟)"
,
"答疑数"
,
"测试成绩"
,
"总评价"
);
public
static
final
List
<
String
>
signList
=
Arrays
.
asList
(
"序号"
,
"成员名称"
,
"身份证号
码"
,
"联系方式"
,
"学习时长(小时)"
,
"学习时长(分钟)"
,
"课程进度"
,
"完成率"
,
"签到次数"
,
"签到日期
"
);
public
static
final
List
<
String
>
signList
=
Arrays
.
asList
(
"序号"
,
"成员名称"
,
"身份证号
"
,
"联系方式"
,
"签到次数"
,
"签到时间"
,
"最近签到ip地址"
,
"最近签到设备型号
"
);
public
static
final
List
<
String
>
scoreList
=
Arrays
.
asList
(
"序号"
,
"成员名称"
,
"身份证号码"
,
"联系方式"
,
"测试成绩"
,
"测试次数"
,
"总评价"
);
...
...
src/main/java/com/subsidy/util/IpAddressUtil.java
View file @
05c3ab8
...
...
@@ -6,6 +6,9 @@ import java.net.UnknownHostException;
public
class
IpAddressUtil
{
/**
* 返回客户端ip
*/
public
static
String
getIpAddress
(
HttpServletRequest
request
)
{
String
ipAddress
=
request
.
getHeader
(
"x-forwarded-for"
);
if
(
ipAddress
==
null
||
ipAddress
.
length
()
==
0
||
"unknown"
.
equalsIgnoreCase
(
ipAddress
))
{
...
...
src/main/java/com/subsidy/util/excel/ExcelUtil.java
View file @
05c3ab8
...
...
@@ -313,17 +313,44 @@ public class ExcelUtil {
return
dataList
;
}
public
static
<
T
>
void
writeExcel
(
List
<
Long
>
memberIds
,
HashMap
<
Long
,
HashMap
<
String
,
Integer
>>
hashMap
,
List
<
String
>
dates
)
{
/**
* 导出excel文件
* @param list
* @param cls
* @param <T>
*/
public
static
<
T
>
void
writeExcel
(
List
<
T
>
list
,
Class
cls
)
{
ServletRequestAttributes
servletRequestAttributes
=
(
ServletRequestAttributes
)
RequestContextHolder
.
getRequestAttributes
();
HttpServletResponse
response
=
servletRequestAttributes
.
getResponse
();
Field
[]
fields
=
cls
.
getDeclaredFields
();
List
<
Field
>
fieldList
=
Arrays
.
stream
(
fields
).
filter
(
field
->
{
ExcelColumn
annotation
=
field
.
getAnnotation
(
ExcelColumn
.
class
);
if
(
annotation
!=
null
)
{
field
.
setAccessible
(
true
);
return
true
;
}
return
false
;
}).
sorted
(
Comparator
.
comparing
(
field
->
{
int
col
=
0
;
ExcelColumn
annotation
=
field
.
getAnnotation
(
ExcelColumn
.
class
);
if
(
annotation
!=
null
)
{
col
=
annotation
.
col
();
}
return
col
;
})).
collect
(
Collectors
.
toList
());
Workbook
wb
=
new
XSSFWorkbook
();
Sheet
sheet
=
wb
.
createSheet
();
AtomicInteger
ai
=
new
AtomicInteger
();
{
Row
row
=
sheet
.
createRow
(
ai
.
getAndIncrement
());
AtomicInteger
at
=
new
AtomicInteger
();
dates
.
forEach
(
field
->
{
fieldList
.
forEach
(
field
->
{
ExcelColumn
annotation
=
field
.
getAnnotation
(
ExcelColumn
.
class
);
String
columnName
=
""
;
if
(
annotation
!=
null
)
{
columnName
=
annotation
.
value
();
}
Cell
cell
=
row
.
createCell
(
at
.
getAndIncrement
());
CellStyle
cellStyle
=
wb
.
createCellStyle
();
cellStyle
.
setFillForegroundColor
(
IndexedColors
.
PALE_BLUE
.
getIndex
());
...
...
@@ -331,33 +358,33 @@ public class ExcelUtil {
font
.
setBoldweight
(
Font
.
BOLDWEIGHT_BOLD
);
cellStyle
.
setFont
(
font
);
cell
.
setCellStyle
(
cellStyle
);
cell
.
setCellValue
(
field
);
cell
.
setCellValue
(
columnName
);
});
if
(
hashMap
!=
null
)
{
memberIds
.
forEach
(
data
->
{
if
(
list
!=
null
)
{
list
.
forEach
(
data
->
{
Row
r
=
sheet
.
createRow
(
ai
.
getAndIncrement
());
AtomicInteger
a
=
new
AtomicInteger
();
Cell
cell
=
r
.
createCell
(
at
.
getAndIncrement
());
CellStyle
cellStyle
=
wb
.
createCellStyle
();
cellStyle
.
setFillForegroundColor
(
IndexedColors
.
PALE_BLUE
.
getIndex
());
cell
.
setCellStyle
(
cellStyle
);
HashMap
<
String
,
Integer
>
hashMap1
=
hashMap
.
get
(
data
);
dates
.
forEach
(
field
->
{
System
.
out
.
println
(
data
+
"========"
);
System
.
out
.
println
(
field
);
Cell
cell1
=
r
.
createCell
(
a
.
getAndIncrement
());
if
(
null
!=
hashMap1
)
{
cell1
.
setCellValue
(
null
==
hashMap1
.
get
(
field
)
?
0
:
hashMap1
.
get
(
field
));
}
else
{
cell1
.
setCellValue
(
0
);
fieldList
.
forEach
(
field
->
{
try
{
Class
<?>
type
=
field
.
getType
();
Object
value
=
field
.
get
(
data
);
Cell
cell
=
r
.
createCell
(
a
.
getAndIncrement
());
if
(
value
!=
null
)
{
cell
.
setCellValue
(
value
.
toString
());
}
}
catch
(
IllegalAccessException
e
)
{
e
.
printStackTrace
();
}
});
});
for
(
int
i
=
0
;
i
<
list
.
size
();
i
++)
{
sheet
.
autoSizeColumn
(
i
);
}
}
String
fileName
=
String
.
valueOf
(
new
Date
().
getTime
());
buildExcelDocument
(
fileName
+
"."
+
EXCEL2007
,
wb
,
response
);
}
}
public
static
<
T
>
void
writeMemberExcel
(
String
companyName
,
String
studyDate
,
String
courseName
,
String
title
,
List
<
ClassDetailVO
>
list
,
List
<
String
>
headerList
)
throws
Exception
{
...
...
@@ -697,7 +724,7 @@ public class ExcelUtil {
sheet
.
addMergedRegion
(
cellRangeAddress21
);
setBorderStyle
(
HSSFCellStyle
.
BORDER_THIN
,
cellRangeAddress21
,
sheet
,
workbook
);
//给合并过的单元格加边框
CellRangeAddress
cellRangeAddress22
=
new
CellRangeAddress
(
1
,
1
,
4
,
9
);
CellRangeAddress
cellRangeAddress22
=
new
CellRangeAddress
(
1
,
1
,
4
,
7
);
sheet
.
addMergedRegion
(
cellRangeAddress22
);
setBorderStyle
(
HSSFCellStyle
.
BORDER_THIN
,
cellRangeAddress22
,
sheet
,
workbook
);
//给合并过的单元格加边框
...
...
@@ -713,7 +740,7 @@ public class ExcelUtil {
sheet
.
addMergedRegion
(
cellRangeAddress31
);
setBorderStyle
(
HSSFCellStyle
.
BORDER_THIN
,
cellRangeAddress31
,
sheet
,
workbook
);
//给合并过的单元格加边框
CellRangeAddress
cellRangeAddress32
=
new
CellRangeAddress
(
2
,
2
,
4
,
9
);
CellRangeAddress
cellRangeAddress32
=
new
CellRangeAddress
(
2
,
2
,
4
,
7
);
sheet
.
addMergedRegion
(
cellRangeAddress32
);
setBorderStyle
(
HSSFCellStyle
.
BORDER_THIN
,
cellRangeAddress32
,
sheet
,
workbook
);
//给合并过的单元格加边框
thirdRow
.
createCell
(
0
).
setCellValue
(
thirdHead
[
0
]);
...
...
@@ -765,28 +792,19 @@ public class ExcelUtil {
newCell
=
dataRow
.
createCell
(
4
);
newCell
.
setCellStyle
(
cellStyle
);
newCell
.
setCellValue
(
classSignVO
.
get
TrainingLengthStr
());
newCell
.
setCellValue
(
classSignVO
.
get
SignCounts
());
newCell
=
dataRow
.
createCell
(
5
);
newCell
.
setCellStyle
(
cellStyle
);
newCell
.
setCellValue
(
classSignVO
.
get
TrainingLengthMinute
());
newCell
.
setCellValue
(
classSignVO
.
get
SignInDateList
());
newCell
=
dataRow
.
createCell
(
6
);
newCell
.
setCellStyle
(
cellStyle
);
newCell
.
setCellValue
(
classSignVO
.
get
ClassProc
ess
());
newCell
.
setCellValue
(
classSignVO
.
get
IpAddr
ess
());
newCell
=
dataRow
.
createCell
(
7
);
newCell
.
setCellStyle
(
cellStyle
);
newCell
.
setCellValue
(
classSignVO
.
getPercent
());
newCell
=
dataRow
.
createCell
(
8
);
newCell
.
setCellStyle
(
cellStyle
);
newCell
.
setCellValue
(
classSignVO
.
getSignCounts
());
newCell
=
dataRow
.
createCell
(
9
);
newCell
.
setCellStyle
(
cellStyle
);
newCell
.
setCellValue
(
classSignVO
.
getSignInDateList
());
newCell
.
setCellValue
(
classSignVO
.
getDeviceNo
());
rowIndex
++;
seq
++;
...
...
src/main/java/com/subsidy/vo/administer/ImageCheckDetailVO.java
View file @
05c3ab8
...
...
@@ -4,4 +4,19 @@ import lombok.Data;
@Data
public
class
ImageCheckDetailVO
{
private
Long
id
;
private
String
userName
;
private
String
accountName
;
private
String
telephone
;
private
String
idCard
;
private
String
cnt
;
private
String
recentDate
;
}
src/main/java/com/subsidy/vo/administer/ManageMemberVO.java
View file @
05c3ab8
package
com
.
subsidy
.
vo
.
administer
;
import
com.subsidy.util.excel.ExcelColumn
;
import
lombok.Data
;
@Data
...
...
@@ -7,14 +8,28 @@ public class ManageMemberVO {
private
Long
id
;
@ExcelColumn
(
col
=
1
,
value
=
"用户名称"
)
private
String
userName
;
@ExcelColumn
(
col
=
2
,
value
=
"手机号"
)
private
String
telephone
;
@ExcelColumn
(
col
=
3
,
value
=
"身份证号"
)
private
String
idCard
;
@ExcelColumn
(
col
=
4
,
value
=
"所属企业"
)
private
String
companyName
;
private
String
accountName
;
private
String
checkImage
;
private
String
checkTime
;
private
Integer
firstLogin
;
private
String
smsCheck
;
private
String
imageCheckStatus
;
}
src/main/java/com/subsidy/vo/catagory/GetCategoriesVO.java
0 → 100644
View file @
05c3ab8
package
com
.
subsidy
.
vo
.
catagory
;
import
com.subsidy.model.CategoryDO
;
import
lombok.Data
;
import
java.util.List
;
@Data
public
class
GetCategoriesVO
extends
CategoryDO
{
private
List
<
CategoryDO
>
categoryDOS
;
}
src/main/java/com/subsidy/vo/image/CheckImageResultVO.java
0 → 100644
View file @
05c3ab8
package
com
.
subsidy
.
vo
.
image
;
import
com.subsidy.model.ImageCheckRecordDO
;
import
lombok.Data
;
@Data
public
class
CheckImageResultVO
extends
ImageCheckRecordDO
{
private
Boolean
result
;
}
src/main/java/com/subsidy/vo/image/GetMemberCheckDetailVO.java
0 → 100644
View file @
05c3ab8
package
com
.
subsidy
.
vo
.
image
;
import
lombok.Data
;
@Data
public
class
GetMemberCheckDetailVO
{
private
Long
id
;
private
String
occurredTime
;
private
String
photo
;
private
Double
similarity
;
private
String
result
;
}
src/main/java/com/subsidy/vo/member/ClassSignVO.java
View file @
05c3ab8
...
...
@@ -27,25 +27,14 @@ public class ClassSignVO {
private
String
signInDateList
;
/**
*
培训时长
*
ip地址
*/
private
Integer
trainingLength
;
@ExcelColumn
(
col
=
4
,
value
=
"培训时长(小时)"
)
private
String
trainingLengthStr
;
@ExcelColumn
(
col
=
5
,
value
=
"培训时长(分钟)"
)
private
String
trainingLengthMinute
;
@ExcelColumn
(
col
=
6
,
value
=
"课程进度"
)
private
String
classProcess
;
private
String
ipAddress
;
/**
*
完成率
*
最近设型号
*/
@ExcelColumn
(
col
=
7
,
value
=
"完成率"
)
private
String
percent
;
private
String
deviceNo
;
...
...
src/main/java/com/subsidy/vo/member/GetMemberSignInfoVO.java
View file @
05c3ab8
...
...
@@ -4,4 +4,14 @@ import lombok.Data;
@Data
public
class
GetMemberSignInfoVO
{
private
Long
id
;
private
String
ipAddress
;
private
String
deviceNo
;
private
String
signInDate
;
}
src/main/java/com/subsidy/vo/token/CheckResultVO.java
View file @
05c3ab8
...
...
@@ -11,7 +11,7 @@ public class CheckResultVO {
private
String
bizSeqNo
;
private
ResultVO
result
VO
;
private
ResultVO
result
;
private
String
transactionTime
;
...
...
src/main/java/com/subsidy/vo/token/SendResultVO.java
View file @
05c3ab8
...
...
@@ -17,4 +17,14 @@ public class SendResultVO {
private
Boolean
success
;
private
String
wbAppId
;
private
String
nonce
;
private
Long
userId
;
private
String
sign
;
private
String
faceId
;
}
src/main/resources/code.properties
View file @
05c3ab8
...
...
@@ -18,6 +18,7 @@ meishu.code-message[10022]=密码输入错误,您还可以输入2次密码
meishu.code-message[10023]=密码输入错误,您还可以输入3次密码
meishu.code-message[10024]=密码输入错误,您还可以输入4次密码
meishu.code-message[10025]=身份证识别错误
meishu.code-message[10026]=姓名或身份证号格式不正确
meishu.code-message[20001]=该课程已存在
...
...
@@ -65,7 +66,9 @@ meishu.code-message[16001]=该条件已存在
meishu.code-message[17001]=系统不支持
00
:
00:00~06:00:00学习
meishu.code-message[18000]=视频不存在
meishu.code-message[18001]=删除失败,目录下没有该视频
meishu.code-message[18001]=已超过当日验证次数上线
src/main/resources/mapper/CategoryMapper.xml
View file @
05c3ab8
...
...
@@ -30,4 +30,23 @@
AND t2.delete_date IS NULL
and t.course_id = #{courseId}
</select>
<select
id=
"getCategories"
resultType=
"com.subsidy.vo.catagory.GetCategoriesVO"
>
SELECT
*
FROM
category t
WHERE
t.delete_date IS NULL
AND t.parent_id IS NULL
<if
test=
"name !=null and name != ''"
>
AND t.`name` like concat('%',#{name} ,'%')
</if>
<if
test=
"companyId != null and companyId != ''"
>
and t.company_id = #{companyId}
</if>
<if
test=
"companyId == null"
>
and t.company_id is null
</if>
</select>
</mapper>
src/main/resources/mapper/ImageCheckRecordMapper.xml
View file @
05c3ab8
...
...
@@ -9,8 +9,6 @@
<result
column=
"update_date"
property=
"updateDate"
/>
<result
column=
"delete_date"
property=
"deleteDate"
/>
<result
column=
"class_id"
property=
"classId"
/>
<result
column=
"paper_id"
property=
"paperId"
/>
<result
column=
"request_id"
property=
"requestId"
/>
</resultMap>
<!-- 通用查询结果列 -->
...
...
@@ -21,4 +19,18 @@
id, class_id, paper_id, request_id
</sql>
<select
id=
"getMemberCheckDetail"
resultType=
"com.subsidy.vo.image.GetMemberCheckDetailVO"
>
SELECT
t.id,
t.occurred_time,
t.photo,
t.similarity
FROM
image_check_record t
WHERE
t.delete_date IS NULL
AND t.class_id = #{classId}
AND t.member_id = #{memberId}
</select>
</mapper>
src/main/resources/mapper/MemberMapper.xml
View file @
05c3ab8
...
...
@@ -270,7 +270,10 @@
t.telephone,
t.id_card,
t.account_name,
t2.company_name
t2.company_name,
t.check_image,
t.check_time,
t.first_login
FROM
member t
LEFT JOIN company_dict t2 ON t.company_id = t2.id
...
...
@@ -325,6 +328,6 @@
</select>
<update
id=
"removeCheckImage"
parameterType=
"long"
>
update member set check_image = nulll where id = #{id}
update member set check_image = null
,check_time = nul
l where id = #{id}
</update>
</mapper>
src/main/resources/mapper/VodDictMapper.xml
View file @
05c3ab8
...
...
@@ -105,7 +105,10 @@
create_date
FROM
vod_play_history t
where t.member_id = #{memberId}
where
t.delete_date is null
and t.member_id = #{memberId}
and t.class_id =#{classId}
ORDER BY
t.member_id,
start_date
...
...
src/main/resources/mybatis-plus.properties
View file @
05c3ab8
# 此处为本项目src所在路径(代码生成器输出路径)
outputDir
=
/src/main/java
author
=
DengMin
author
=
Tuyp
# 父的包名
setParent
=
com.subsidy
# mapper.xml文件生成路径
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment