Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
engine-class-work
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liuchengjiu
engine-class-work
Commits
df1357bf
Commit
df1357bf
authored
Jul 18, 2023
by
Ryan Loong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add 清除单个学生成绩的接口
parent
3a4bf0e2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
39 additions
and
0 deletions
+39
-0
IdVo.java
...in/java/cn/exploring/engine/server/db/domain/vo/IdVo.java
+21
-0
StudentPointService.java
...ploring/engine/server/db/service/StudentPointService.java
+11
-0
PointController.java
...va/cn/exploring/engine/server/wx/web/PointController.java
+7
-0
No files found.
server-db/src/main/java/cn/exploring/engine/server/db/domain/vo/IdVo.java
0 → 100644
View file @
df1357bf
package
cn
.
exploring
.
engine
.
server
.
db
.
domain
.
vo
;
public
class
IdVo
{
private
Integer
id
;
public
IdVo
()
{
}
public
IdVo
(
Integer
id
)
{
this
.
id
=
id
;
}
public
Integer
getId
()
{
return
id
;
}
public
void
setId
(
Integer
id
)
{
this
.
id
=
id
;
}
}
server-db/src/main/java/cn/exploring/engine/server/db/service/StudentPointService.java
View file @
df1357bf
...
...
@@ -115,6 +115,17 @@ public class StudentPointService {
.
example
());
}
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
void
removeByStudentId
(
Integer
studentId
)
{
studentPointInfoMapper
.
updateByExampleSelective
(
new
StudentPointInfo
(){{
setUpdateTime
(
LocalDateTime
.
now
());
setDeleted
(
StudentPointInfo
.
IS_DELETED
);
}},
new
StudentPointInfoExample
().
createCriteria
()
.
andDeletedEqualTo
(
StudentPointInfo
.
NOT_DELETED
)
.
andStudentIdEqualTo
(
studentId
)
.
example
());
}
@Transactional
(
propagation
=
Propagation
.
NOT_SUPPORTED
,
readOnly
=
true
)
public
List
<
StudentPointInfo
>
listByClassId
(
Integer
classId
)
{
return
studentPointInfoMapper
.
selectByExample
(
new
StudentPointInfoExample
().
createCriteria
()
...
...
server-wx-api/src/main/java/cn/exploring/engine/server/wx/web/PointController.java
View file @
df1357bf
...
...
@@ -3,6 +3,7 @@ package cn.exploring.engine.server.wx.web;
import
cn.exploring.engine.server.core.storage.StorageService
;
import
cn.exploring.engine.server.core.util.ResponseUtil
;
import
cn.exploring.engine.server.db.domain.StudentPointInfo
;
import
cn.exploring.engine.server.db.domain.vo.IdVo
;
import
cn.exploring.engine.server.db.service.StudentInfoService
;
import
cn.exploring.engine.server.db.service.StudentPointService
;
import
org.springframework.util.CollectionUtils
;
...
...
@@ -68,6 +69,12 @@ public class PointController {
return
ResponseUtil
.
ok
();
}
@PostMapping
(
"remove"
)
public
Object
remove
(
@RequestBody
IdVo
req
)
{
pointService
.
removeByStudentId
(
req
.
getId
());
return
ResponseUtil
.
ok
();
}
@GetMapping
(
"export"
)
public
Object
export
(
Integer
classId
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment