Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
bpm
Overview
Overview
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
王厚康
bpm
Commits
6acd0588
Commit
6acd0588
authored
Apr 08, 2019
by
Java-曹文达
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
规范代码规则
parent
200d12ad
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
134 additions
and
66 deletions
+134
-66
UserApiController.java
src/main/java/com/bbd/bpm/controller/user/UserApiController.java
+42
-21
UserInfoService.java
src/main/java/com/bbd/bpm/service/UserInfoService.java
+47
-22
UserInfoServiceImpl.java
src/main/java/com/bbd/bpm/serviceImpl/UserInfoServiceImpl.java
+45
-23
No files found.
src/main/java/com/bbd/bpm/controller/user/UserApiController.java
View file @
6acd0588
...
...
@@ -24,13 +24,18 @@ public class UserApiController {
@Autowired
private
UserInfoService
userInfoService
;
/**
* @Author:cwd
* @Description:用户列表
* @Date: 2019/03/04 22:53
* @Param:
* @return
**/
* @Description: 用户列表
* @author: cwd
* @param: id
* @param pageBean
* @param userName
* @return Result
* @date: 2019/3/4
* @time: 11:03
*/
@RequestMapping
(
value
=
"/userList"
)
@ResponseBody
public
Result
userList
(
Integer
id
,
PageBean
pageBean
,
String
userName
){
...
...
@@ -50,8 +55,8 @@ public class UserApiController {
* @Author:cwd
* @Description:获取组织列表
* @Date: 2019/03/04 22:53
* @
Param:
* @return
* @
param id
* @return
Result
**/
@RequestMapping
(
value
=
"getOrganizationInfo"
)
@ResponseBody
...
...
@@ -64,8 +69,11 @@ public class UserApiController {
* @Author:cwd
* @Description:获取组织列表
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param pageBean
* @param id
* @param pId
* @param name
* @return Result
**/
@RequestMapping
(
value
=
"getOrganization"
)
@ResponseBody
...
...
@@ -86,8 +94,7 @@ public class UserApiController {
* @Author:cwd
* @Description:加载ztree
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @return Result
**/
@RequestMapping
(
value
=
"getOrganizationList"
)
@ResponseBody
...
...
@@ -100,7 +107,10 @@ public class UserApiController {
* @Author:cwd
* @Description:添加组织
* @Date: 2019/03/04 22:53
* @Param:
* @param pId
* @param id
* @param abbreviationName
* @param name
* @return
**/
@RequestMapping
(
value
=
"addOrganization"
)
...
...
@@ -116,8 +126,13 @@ public class UserApiController {
* @Author:cwd
* @Description:添加部门人员
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param id
* @param name
* @param pId
* @param department
* @param position
* @param type
* @return Result
**/
@RequestMapping
(
value
=
"addOrganizationMember"
)
@ResponseBody
...
...
@@ -132,8 +147,10 @@ public class UserApiController {
* @Author:cwd
* @Description:修改组织
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param name
* @param abbreviationName
* @param id
* @return Result
**/
@RequestMapping
(
value
=
"editOrganization"
)
@ResponseBody
...
...
@@ -150,7 +167,7 @@ public class UserApiController {
* @Date: 2019/03/04 22:53
* @param id
* @param pId
* @return
* @return
Result
*/
@RequestMapping
(
value
=
"deleteOrganization"
)
@ResponseBody
...
...
@@ -161,7 +178,9 @@ public class UserApiController {
/**
* 获取下级部门信息
* @return
* @Author:cwd
* @param id
* @return Result
*/
@RequestMapping
(
value
=
"getAreaAll"
)
@ResponseBody
...
...
@@ -175,7 +194,7 @@ public class UserApiController {
* @Author:cwd
* 获取左侧树
* @Date: 2019.3.7
* @return
* @return
Result
*/
@RequestMapping
(
value
=
"/menuList"
,
method
=
RequestMethod
.
GET
)
@ResponseBody
...
...
@@ -188,8 +207,9 @@ public class UserApiController {
/**
* @Author:cwd
* 添加用户
* @param user
* @Date: 2019.4.4
* @return
* @return
Result
*/
@RequestMapping
(
value
=
"/addUser"
,
method
=
RequestMethod
.
POST
)
@ResponseBody
...
...
@@ -202,6 +222,7 @@ public class UserApiController {
* @Author:cwd
* 删除用户
* @Date: 2019.4.4
* @param user
* @return
*/
@RequestMapping
(
value
=
"/deleteUser"
,
method
=
RequestMethod
.
POST
)
...
...
src/main/java/com/bbd/bpm/service/UserInfoService.java
View file @
6acd0588
...
...
@@ -6,58 +6,78 @@ import com.bbd.bpm.result.Result;
public
interface
UserInfoService
{
/**
* 获取组织列表
* @Author:cwd
* @Description:获取组织列表
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param pageBean
* @param id
* @param pId
* @param name
* @return Result
**/
Result
getOrganization
(
PageBean
pageBean
,
Integer
id
,
Integer
pId
,
String
name
);
/**
* 加载ztree
* @Author:cwd
* @Description:加载ztree
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @return Result
**/
Result
getOrganizationList
();
/**
* 添加组织
* @Author:cwd
* @Description:添加组织
* @Date: 2019/03/04 22:53
* @Param:
* @param pId
* @param id
* @param abbreviationName
* @param name
* @return
**/
Result
addOrganization
(
String
name
,
String
abbreviationName
,
Long
pId
,
Integer
id
);
/**
* 添加部门人员
* @Author:cwd
* @Description:添加部门人员
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param id
* @param name
* @param pId
* @param department
* @param position
* @param type
* @return Result
**/
Result
addOrganizationMember
(
String
name
,
String
position
,
Long
pId
,
Integer
id
,
Integer
department
,
Integer
type
);
/**
* 获取组织列表
* @Author:cwd
* @Description:获取组织
详情
* @Description:获取组织
列表
* @Date: 2019/03/04 22:53
* @
Param:
* @return
* @
param id
* @return
Result
**/
Result
getOrganizationInfo
(
Integer
id
);
/**
* 修改组织
* @Author:cwd
* @Description:修改组织
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param name
* @param abbreviationName
* @param id
* @return Result
**/
Result
editOrganization
(
String
name
,
String
abbreviationName
,
Integer
id
);
/**
* 删除组织及下级
* @Author:cwd
* @Date: 2019/03/04 22:53
* @param id
* @param pId
* @return
* @return
Result
*/
Result
deleteOrganization
(
Long
id
,
Integer
pId
);
/**
...
...
@@ -69,30 +89,35 @@ public interface UserInfoService {
Result
getAreaAll
(
Integer
id
);
/**
* @Author:cwd
* 获取左侧树
* @Author:cwd
* @Date: 2019.3.7
* @return
*/
Result
getMenuList
();
/**
* @Author:cwd
* 获取用户列表
* @Date: 2019.3.7
* @return
* 用户列表
* @Description: 用户列表
* @author: cwd
* @param id
* @param pageBean
* @param userName
* @return Result
* @date: 2019/3/4
* @time: 11:03
*/
Result
userList
(
Integer
id
,
PageBean
pageBean
,
String
userName
);
/**
* @Author:cwd
* 添加用户
* @Date: 2019.4.4
* @return
* @Author:cwd
* @param user
* @Date: 2019.4.4
* @return Result
*/
Result
addUser
(
User
user
);
/**
* @Author:cwd
* 删除用户
* @Author:cwd
* @Date: 2019.4.4
* @return
* @param user
...
...
src/main/java/com/bbd/bpm/serviceImpl/UserInfoServiceImpl.java
View file @
6acd0588
...
...
@@ -32,11 +32,15 @@ public class UserInfoServiceImpl implements UserInfoService{
@Autowired
private
MemberMapper
memberMapper
;
/**
* 获取组织列表
* @Author:cwd
* @Description:获取组织列表
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param pageBean
* @param id
* @param pId
* @param name
* @return Result
**/
@Override
public
Result
getOrganization
(
PageBean
pageBean
,
Integer
id
,
Integer
pId
,
String
name
)
{
...
...
@@ -84,11 +88,11 @@ public class UserInfoServiceImpl implements UserInfoService{
}
/**
* 加载ztree
* @Author:cwd
* @Description:加载ztree
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @return Result
**/
@Override
public
Result
getOrganizationList
()
{
...
...
@@ -112,7 +116,8 @@ public class UserInfoServiceImpl implements UserInfoService{
try
{
BpmCompany
bpmCompany
=
new
BpmCompany
();
//组织编号
StringBuilder
str
=
new
StringBuilder
();
//定义变长字符串
//定义变长字符串
StringBuilder
str
=
new
StringBuilder
();
Random
random
=
new
Random
();
//随机生成数字,并添加到字符串
for
(
int
i
=
0
;
i
<
8
;
i
++){
...
...
@@ -143,11 +148,17 @@ public class UserInfoServiceImpl implements UserInfoService{
}
}
/**
* 添加部门人员
* @Author:cwd
* @Description:
部门下添加人员信息
* @Description:
添加部门人员
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param id
* @param name
* @param pId
* @param department
* @param position
* @param type
* @return Result
**/
@Override
public
Result
addOrganizationMember
(
String
name
,
String
position
,
Long
pId
,
Integer
id
,
Integer
department
,
Integer
type
)
{
...
...
@@ -175,11 +186,12 @@ public class UserInfoServiceImpl implements UserInfoService{
}
/**
* 获取组织列表
* @Author:cwd
* @Description:获取组织
详情
* @Description:获取组织
列表
* @Date: 2019/03/04 22:53
* @
Param:
* @return
* @
param id
* @return
Result
**/
@Override
public
Result
getOrganizationInfo
(
Integer
id
)
{
...
...
@@ -192,11 +204,14 @@ public class UserInfoServiceImpl implements UserInfoService{
}
}
/**
* 修改组织
* @Author:cwd
* @Description:修改组织
信息
* @Description:修改组织
* @Date: 2019/03/04 22:53
* @Param:
* @return
* @param name
* @param abbreviationName
* @param id
* @return Result
**/
@Override
public
Result
editOrganization
(
String
name
,
String
abbreviationName
,
Integer
id
)
{
...
...
@@ -215,9 +230,11 @@ public class UserInfoServiceImpl implements UserInfoService{
/**
* 删除组织及下级
* @Author:cwd
* @Date: 2019/03/04 22:53
* @param id
* @param pId
* @return
* @return
Result
*/
@Override
public
Result
deleteOrganization
(
Long
id
,
Integer
pId
)
{
...
...
@@ -277,10 +294,15 @@ public class UserInfoServiceImpl implements UserInfoService{
/**
* @Author:cwd
* 获取用户列表
* @Date: 2019.3.7
* @return
* 用户列表
* @Description: 用户列表
* @author: cwd
* @param id
* @param pageBean
* @param userName
* @return Result
* @date: 2019/3/4
* @time: 11:03
*/
@Override
public
Result
userList
(
Integer
id
,
PageBean
pageBean
,
String
userName
)
{
...
...
@@ -295,11 +317,11 @@ public class UserInfoServiceImpl implements UserInfoService{
}
/**
* @Author:cwd
* 添加用户
* @Date: 2019.4.4
* @return
* @Author:cwd
* @param user
* @Date: 2019.4.4
* @return Result
*/
@Override
public
Result
addUser
(
User
user
)
{
...
...
@@ -326,8 +348,8 @@ public class UserInfoServiceImpl implements UserInfoService{
}
/**
* @Author:cwd
* 删除用户
* @Author:cwd
* @Date: 2019.4.4
* @return
* @param user
...
...
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