Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
S
sentinel
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
曲欣亮
sentinel
Commits
0f7b23ed
Commit
0f7b23ed
authored
Dec 28, 2018
by
Quxl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
x
parent
88c04861
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
3 deletions
+33
-3
AdminUserService.java
...ain/java/com/egolm/film/api/service/AdminUserService.java
+6
-0
AdminUserServiceImpl.java
...com/egolm/film/api/service/impl/AdminUserServiceImpl.java
+20
-0
AdminUserController.java
...ava/com/egolm/film/api/web/admin/AdminUserController.java
+7
-3
No files found.
src/main/java/com/egolm/film/api/service/AdminUserService.java
View file @
0f7b23ed
...
@@ -6,6 +6,7 @@ import java.util.Map;
...
@@ -6,6 +6,7 @@ import java.util.Map;
import
com.egolm.common.jdbc.Page
;
import
com.egolm.common.jdbc.Page
;
import
com.egolm.film.bean.Fc_user
;
import
com.egolm.film.bean.Fc_user
;
import
com.egolm.film.bean.Fc_user_group
;
import
com.egolm.film.bean.Fc_user_group
;
import
com.egolm.film.bean.Fc_user_group_enroll
;
import
com.egolm.film.bean.Fc_user_group_fun
;
import
com.egolm.film.bean.Fc_user_group_fun
;
public
interface
AdminUserService
{
public
interface
AdminUserService
{
...
@@ -24,9 +25,13 @@ public interface AdminUserService {
...
@@ -24,9 +25,13 @@ public interface AdminUserService {
void
saveGroupFun
(
Integer
group_id
,
Integer
[]
fun_id
);
void
saveGroupFun
(
Integer
group_id
,
Integer
[]
fun_id
);
void
saveGroupEnroll
(
Integer
group_id
,
Integer
[]
enroll_types
);
Fc_user_group
queryGroupById
(
Integer
group_id
);
Fc_user_group
queryGroupById
(
Integer
group_id
);
List
<
Fc_user_group_fun
>
queryGroupFunList
(
Integer
group_id
);
List
<
Fc_user_group_fun
>
queryGroupFunList
(
Integer
group_id
);
List
<
Fc_user_group_enroll
>
queryGroupEnrollList
(
Integer
group_id
);
void
deleteUserById
(
Integer
uid
);
void
deleteUserById
(
Integer
uid
);
...
@@ -35,5 +40,6 @@ public interface AdminUserService {
...
@@ -35,5 +40,6 @@ public interface AdminUserService {
List
<
Map
<
String
,
Object
>>
getReviewUserList
(
Integer
review_id
);
List
<
Map
<
String
,
Object
>>
getReviewUserList
(
Integer
review_id
);
List
<
Map
<
String
,
Object
>>
getReviewGroupList
(
Integer
review_id
);
List
<
Map
<
String
,
Object
>>
getReviewGroupList
(
Integer
review_id
);
}
}
src/main/java/com/egolm/film/api/service/impl/AdminUserServiceImpl.java
View file @
0f7b23ed
...
@@ -15,6 +15,7 @@ import com.egolm.common.jdbc.Page;
...
@@ -15,6 +15,7 @@ import com.egolm.common.jdbc.Page;
import
com.egolm.film.api.service.AdminUserService
;
import
com.egolm.film.api.service.AdminUserService
;
import
com.egolm.film.bean.Fc_user
;
import
com.egolm.film.bean.Fc_user
;
import
com.egolm.film.bean.Fc_user_group
;
import
com.egolm.film.bean.Fc_user_group
;
import
com.egolm.film.bean.Fc_user_group_enroll
;
import
com.egolm.film.bean.Fc_user_group_fun
;
import
com.egolm.film.bean.Fc_user_group_fun
;
import
com.egolm.film.util.Common
;
import
com.egolm.film.util.Common
;
import
com.egolm.film.util.SqlWhere
;
import
com.egolm.film.util.SqlWhere
;
...
@@ -76,6 +77,20 @@ public class AdminUserServiceImpl implements AdminUserService {
...
@@ -76,6 +77,20 @@ public class AdminUserServiceImpl implements AdminUserService {
jdbcTemplate
.
batchSave
(
list
);
jdbcTemplate
.
batchSave
(
list
);
}
}
@Override
public
void
saveGroupEnroll
(
Integer
group_id
,
Integer
[]
enroll_types
)
{
if
(
enroll_types
!=
null
&&
enroll_types
.
length
>
0
)
{
List
<
Fc_user_group_enroll
>
typeList
=
new
ArrayList
<
Fc_user_group_enroll
>();
for
(
Integer
enrollType
:
enroll_types
)
{
Fc_user_group_enroll
type
=
new
Fc_user_group_enroll
();
type
.
setGroup_id
(
group_id
);
type
.
setEnroll_type_id
(
enrollType
);
typeList
.
add
(
type
);
}
jdbcTemplate
.
batchSave
(
typeList
);
}
}
@Override
@Override
public
Fc_user_group
queryGroupById
(
Integer
group_id
)
{
public
Fc_user_group
queryGroupById
(
Integer
group_id
)
{
return
jdbcTemplate
.
queryForBean
(
"select * from fc_user_group where group_id = ?"
,
Fc_user_group
.
class
,
group_id
);
return
jdbcTemplate
.
queryForBean
(
"select * from fc_user_group where group_id = ?"
,
Fc_user_group
.
class
,
group_id
);
...
@@ -85,6 +100,11 @@ public class AdminUserServiceImpl implements AdminUserService {
...
@@ -85,6 +100,11 @@ public class AdminUserServiceImpl implements AdminUserService {
public
List
<
Fc_user_group_fun
>
queryGroupFunList
(
Integer
group_id
)
{
public
List
<
Fc_user_group_fun
>
queryGroupFunList
(
Integer
group_id
)
{
return
jdbcTemplate
.
queryForBeans
(
"select * from fc_user_group_fun where group_id = ?"
,
Fc_user_group_fun
.
class
,
group_id
);
return
jdbcTemplate
.
queryForBeans
(
"select * from fc_user_group_fun where group_id = ?"
,
Fc_user_group_fun
.
class
,
group_id
);
}
}
@Override
public
List
<
Fc_user_group_enroll
>
queryGroupEnrollList
(
Integer
group_id
)
{
return
jdbcTemplate
.
queryForBeans
(
"select * from fc_user_group_enroll where group_id = ?"
,
Fc_user_group_enroll
.
class
,
group_id
);
}
@Override
@Override
public
void
deleteUserById
(
Integer
uid
)
{
public
void
deleteUserById
(
Integer
uid
)
{
...
...
src/main/java/com/egolm/film/api/web/admin/AdminUserController.java
View file @
0f7b23ed
...
@@ -19,6 +19,7 @@ import com.egolm.film.api.service.AdminTokenService;
...
@@ -19,6 +19,7 @@ import com.egolm.film.api.service.AdminTokenService;
import
com.egolm.film.api.service.AdminUserService
;
import
com.egolm.film.api.service.AdminUserService
;
import
com.egolm.film.bean.Fc_user
;
import
com.egolm.film.bean.Fc_user
;
import
com.egolm.film.bean.Fc_user_group
;
import
com.egolm.film.bean.Fc_user_group
;
import
com.egolm.film.bean.Fc_user_group_enroll
;
import
com.egolm.film.bean.Fc_user_group_fun
;
import
com.egolm.film.bean.Fc_user_group_fun
;
import
com.egolm.film.config.WebMvcConfig
;
import
com.egolm.film.config.WebMvcConfig
;
import
com.egolm.film.util.Common
;
import
com.egolm.film.util.Common
;
...
@@ -64,7 +65,8 @@ public class AdminUserController {
...
@@ -64,7 +65,8 @@ public class AdminUserController {
public
Rjx
groupDetail
(
Integer
group_id
)
{
public
Rjx
groupDetail
(
Integer
group_id
)
{
Fc_user_group
group
=
service
.
queryGroupById
(
group_id
);
Fc_user_group
group
=
service
.
queryGroupById
(
group_id
);
List
<
Fc_user_group_fun
>
funList
=
service
.
queryGroupFunList
(
group_id
);
List
<
Fc_user_group_fun
>
funList
=
service
.
queryGroupFunList
(
group_id
);
return
Rjx
.
jsonOk
().
setData
(
group
).
set
(
"funList"
,
funList
);
List
<
Fc_user_group_enroll
>
enrollList
=
service
.
queryGroupEnrollList
(
group_id
);
return
Rjx
.
jsonOk
().
setData
(
group
).
set
(
"funList"
,
funList
).
set
(
"enrollList"
,
enrollList
);
}
}
@ResponseBody
@ResponseBody
...
@@ -76,9 +78,10 @@ public class AdminUserController {
...
@@ -76,9 +78,10 @@ public class AdminUserController {
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"string"
,
required
=
true
,
name
=
"group_name"
,
value
=
"分组名称"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"string"
,
required
=
true
,
name
=
"group_name"
,
value
=
"分组名称"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"int"
,
required
=
true
,
name
=
"state"
,
value
=
"状态"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"int"
,
required
=
true
,
name
=
"state"
,
value
=
"状态"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"string"
,
required
=
true
,
name
=
"job_desc"
,
value
=
"工作介绍"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"string"
,
required
=
true
,
name
=
"job_desc"
,
value
=
"工作介绍"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"int"
,
required
=
true
,
name
=
"fun_id"
,
value
=
"权限[功能]ID [1-6]选权限,7快进后退权限"
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"int"
,
required
=
true
,
name
=
"fun_id"
,
value
=
"权限[功能]ID [1-6]选权限,7快进后退权限"
,
allowMultiple
=
true
),
@ApiImplicitParam
(
paramType
=
"query"
,
dataType
=
"int"
,
required
=
true
,
name
=
"enroll_types"
,
value
=
"评委审片权限 1金爵流程 2亚新流程 4参展流程"
,
allowMultiple
=
true
),
})
})
public
Rjx
saveGroup
(
Integer
group_id
,
String
group_name
,
Integer
state
,
String
job_desc
,
Integer
[]
fun_id
)
{
public
Rjx
saveGroup
(
Integer
group_id
,
String
group_name
,
Integer
state
,
String
job_desc
,
Integer
[]
fun_id
,
Integer
[]
enroll_types
)
{
Fc_user_group
group
=
new
Fc_user_group
();
Fc_user_group
group
=
new
Fc_user_group
();
group
.
setGroup_id
(
group_id
);
group
.
setGroup_id
(
group_id
);
group
.
setGroup_name
(
group_name
);
group
.
setGroup_name
(
group_name
);
...
@@ -91,6 +94,7 @@ public class AdminUserController {
...
@@ -91,6 +94,7 @@ public class AdminUserController {
}
}
service
.
mergeGroup
(
group
);
service
.
mergeGroup
(
group
);
service
.
saveGroupFun
(
group
.
getGroup_id
(),
fun_id
);
service
.
saveGroupFun
(
group
.
getGroup_id
(),
fun_id
);
service
.
saveGroupEnroll
(
group
.
getGroup_id
(),
enroll_types
);
return
Rjx
.
jsonOk
().
setData
(
group
);
return
Rjx
.
jsonOk
().
setData
(
group
);
}
}
...
...
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