Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
member-api
Project
Project
Details
Activity
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
曲欣亮
member-api
Commits
3fb8675f
Commit
3fb8675f
authored
Dec 04, 2018
by
Quxl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
x
parent
11680c6f
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
12 deletions
+25
-12
FilmService.java
src/main/java/com/egolm/film/api/service/FilmService.java
+3
-1
FilmServiceImpl.java
...java/com/egolm/film/api/service/impl/FilmServiceImpl.java
+8
-8
AdminFirstController.java
...va/com/egolm/film/api/web/admin/AdminFirstController.java
+14
-3
No files found.
src/main/java/com/egolm/film/api/service/FilmService.java
View file @
3fb8675f
...
...
@@ -136,6 +136,8 @@ public interface FilmService {
void
allot
(
Long
member_film_id
,
Integer
review_round
,
Integer
[]
user_id
);
void
saveUploadInfo
(
Long
member_film_id
,
String
upload_id
,
Integer
upload_state
);
void
saveUploadId
(
Long
member_film_id
,
String
upload_id
);
void
saveUploadState
(
Long
member_film_id
,
Integer
upload_state
);
}
src/main/java/com/egolm/film/api/service/impl/FilmServiceImpl.java
View file @
3fb8675f
...
...
@@ -5,6 +5,7 @@ import java.sql.PreparedStatement;
import
java.sql.SQLException
;
import
java.sql.Statement
;
import
java.util.ArrayList
;
import
java.util.Date
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
...
...
@@ -514,14 +515,13 @@ public class FilmServiceImpl implements FilmService {
}
@Override
public
void
saveUploadInfo
(
Long
member_film_id
,
String
upload_id
,
Integer
upload_state
)
{
Fc_member_film
film
=
new
Fc_member_film
();
film
.
setId
(
member_film_id
);
film
.
setUpload_state
(
upload_state
);
if
(
StringUtil
.
isNotBlank
(
upload_id
))
{
film
.
setUpload_id
(
upload_id
);
public
void
saveUploadId
(
Long
member_film_id
,
String
upload_id
)
{
jdbcTemplate
.
executeUpdate
(
"update fc_member_film set upload_id = ?, upload_time = ? where id = ?"
,
upload_id
,
new
Date
(),
member_film_id
);
}
jdbcTemplate
.
merge
(
film
);
@Override
public
void
saveUploadState
(
Long
member_film_id
,
Integer
upload_state
)
{
jdbcTemplate
.
executeUpdate
(
"update fc_member_film set upload_state = ? where id = ?"
,
upload_state
,
member_film_id
);
}
}
src/main/java/com/egolm/film/api/web/admin/AdminFirstController.java
View file @
3fb8675f
...
...
@@ -170,15 +170,26 @@ public class AdminFirstController {
}
@ResponseBody
@PostMapping
(
"save_upload_i
nfo
"
)
@PostMapping
(
"save_upload_i
d
"
)
@ApiOperation
(
"保存上传状态和上传ID"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"long"
,
required
=
true
,
name
=
"member_film_id"
,
value
=
"申报影片ID"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"string"
,
required
=
true
,
name
=
"upload_id"
,
value
=
"影片上传ID"
),
})
public
Object
save_upload_id
(
Long
member_film_id
,
String
upload_id
)
{
memberFilmService
.
saveUploadId
(
member_film_id
,
upload_id
);
return
Rjx
.
jsonOk
();
}
@ResponseBody
@PostMapping
(
"save_upload_info"
)
@ApiOperation
(
"保存上传状态和上传ID"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"long"
,
required
=
true
,
name
=
"member_film_id"
,
value
=
"申报影片ID"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"int"
,
required
=
true
,
name
=
"upload_state"
,
value
=
"影片上传状态(0上传中,1已完成)"
),
})
public
Object
save_upload_info
(
Long
member_film_id
,
String
upload_id
,
Integer
upload_state
)
{
memberFilmService
.
saveUpload
Info
(
member_film_id
,
upload
_id
,
upload_state
);
public
Object
save_upload_info
(
Long
member_film_id
,
Integer
upload_state
)
{
memberFilmService
.
saveUpload
State
(
member_film
_id
,
upload_state
);
return
Rjx
.
jsonOk
();
}
...
...
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