Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yifu-mvp
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
fangxinjiang
yifu-mvp
Commits
e3cff5db
Commit
e3cff5db
authored
Apr 01, 2025
by
fangxinjiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
项目负责人权限同步-fxj
parent
1c4ef46f
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
92 additions
and
5 deletions
+92
-5
TSettleDomain.java
...ifu/cloud/plus/v1/yifu/archives/entity/TSettleDomain.java
+13
-0
TSettleDomainEkpVo.java
...fu/cloud/plus/v1/yifu/archives/vo/TSettleDomainEkpVo.java
+6
-0
TSettleDomainUpServerTeamVo.java
...plus/v1/yifu/archives/vo/TSettleDomainUpServerTeamVo.java
+6
-0
TSettleDomainController.java
.../v1/yifu/archives/controller/TSettleDomainController.java
+1
-1
TSettleDomainService.java
...d/plus/v1/yifu/archives/service/TSettleDomainService.java
+2
-0
TSettleDomainServiceImpl.java
.../yifu/archives/service/impl/TSettleDomainServiceImpl.java
+44
-1
application.yml
...ives/yifu-archives-biz/src/main/resources/application.yml
+1
-1
TSettleDomainMapper.xml
...ves-biz/src/main/resources/mapper/TSettleDomainMapper.xml
+9
-2
SysUserPermissionMapper.xml
...biz/src/main/resources/mapper/SysUserPermissionMapper.xml
+10
-0
No files found.
yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/entity/TSettleDomain.java
View file @
e3cff5db
...
...
@@ -567,4 +567,17 @@ public class TSettleDomain extends BaseEntity {
@Schema
(
description
=
"登录账号"
)
private
String
csLoginName
;
/**
* 项目负责人
*/
@Schema
(
description
=
"项目负责人"
,
name
=
"projectManager"
)
private
String
projectManager
;
/**
* 项目负责人
*/
@TableField
(
exist
=
false
)
@Schema
(
description
=
"项目负责人姓名"
)
private
String
projectManagerName
;
}
yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/vo/TSettleDomainEkpVo.java
View file @
e3cff5db
...
...
@@ -463,4 +463,10 @@ public class TSettleDomainEkpVo implements Serializable {
*/
@Schema
(
description
=
"事业部"
,
name
=
"division"
)
private
String
division
;
/**
* 项目负责人
*/
@Schema
(
description
=
"项目负责人"
,
name
=
"projectManager"
)
private
String
projectManager
;
}
yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/vo/TSettleDomainUpServerTeamVo.java
View file @
e3cff5db
...
...
@@ -25,4 +25,10 @@ public class TSettleDomainUpServerTeamVo implements Serializable {
*/
@Schema
(
description
=
"EKP的服务团队"
,
name
=
"serviceTeam"
)
private
String
serviceTeam
;
/**
* 项目负责人
*/
@Schema
(
description
=
"项目负责人"
,
name
=
"projectManager"
)
private
String
projectManager
;
}
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/controller/TSettleDomainController.java
View file @
e3cff5db
...
...
@@ -132,7 +132,7 @@ public class TSettleDomainController {
@Operation
(
summary
=
"通过id查询"
,
description
=
"通过id查询"
)
@GetMapping
(
"/{id}"
)
public
R
<
TSettleDomain
>
getById
(
@PathVariable
(
"id"
)
String
id
)
{
return
R
.
ok
(
tSettleDomainService
.
getById
(
id
)
);
return
tSettleDomainService
.
getByIdAsso
(
id
);
}
/**
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/TSettleDomainService.java
View file @
e3cff5db
...
...
@@ -139,4 +139,6 @@ public interface TSettleDomainService extends IService<TSettleDomain> {
R
<
Boolean
>
changeIssueStatus
(
ChangeIssueStatusVo
changeIssueStatusVo
);
R
<
Boolean
>
updateProjectCsInfo
(
List
<
TDomainUpCsVo
>
list
);
R
<
TSettleDomain
>
getByIdAsso
(
String
id
);
}
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TSettleDomainServiceImpl.java
View file @
e3cff5db
...
...
@@ -506,9 +506,23 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T
return
R
.
ok
(
Boolean
.
TRUE
,
CommonConstants
.
RESULT_DATA_SUCESS
);
}
/**
* @Author fxj
* @Description 同步 项目人员权限(服务团队、项目负责人)
* @Date 18:07 2025/3/31
**/
private
void
initServerTeamPermission
(
TSettleDomain
domain
)
{
R
<
SysUserListVo
>
res
;
if
(
Common
.
isNotNull
(
domain
.
getServiceTeam
())){
R
<
SysUserListVo
>
res
=
upmsDaprUtils
.
getUserIdsByUserNames
(
domain
.
getServiceTeam
());
res
=
upmsDaprUtils
.
getUserIdsByUserNames
(
domain
.
getServiceTeam
());
if
(
Common
.
isNotNull
(
res
)
&&
Common
.
isNotNull
(
res
.
getData
())
&&
Common
.
isNotNull
(
res
.
getData
().
getUserList
())){
// 先清理缓存
this
.
removeSettleCache
(
null
,
res
.
getData
().
getUserIds
());
saveForEkp
(
res
.
getData
().
getUserList
(),
domain
);
}
}
if
(
Common
.
isNotNull
(
domain
.
getProjectManager
())){
res
=
upmsDaprUtils
.
getUserIdsByUserNames
(
domain
.
getProjectManager
());
if
(
Common
.
isNotNull
(
res
)
&&
Common
.
isNotNull
(
res
.
getData
())
&&
Common
.
isNotNull
(
res
.
getData
().
getUserList
())){
// 先清理缓存
this
.
removeSettleCache
(
null
,
res
.
getData
().
getUserIds
());
...
...
@@ -542,4 +556,33 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T
}
return
R
.
ok
(
Boolean
.
TRUE
,
CommonConstants
.
RESULT_DATA_SUCESS
);
}
/**
* @Author fxj
* @Description 获取项目基本信息,含项目负责人
* @Date 18:05 2025/3/31
**/
@Override
public
R
<
TSettleDomain
>
getByIdAsso
(
String
id
)
{
TSettleDomain
domain
=
baseMapper
.
selectById
(
id
);
if
(
Common
.
isNotNull
(
domain
)
&&
Common
.
isNotNull
(
domain
.
getProjectManager
())){
if
(
Common
.
isNotNull
(
domain
.
getProjectManager
())){
R
<
SysUserListVo
>
res
=
upmsDaprUtils
.
getUserIdsByUserNames
(
domain
.
getProjectManager
());
if
(
Common
.
isNotNull
(
res
)
&&
Common
.
isNotNull
(
res
.
getData
())
&&
Common
.
isNotNull
(
res
.
getData
().
getUserList
())){
StringBuilder
manager
=
new
StringBuilder
();
res
.
getData
().
getUserList
().
forEach
(
user
->{
if
(
Common
.
isNotNull
(
user
.
getUserId
())){
if
(
Common
.
isEmpty
(
manager
.
toString
())){
manager
.
append
(
user
.
getNickname
());
}
else
if
(
Common
.
isNotNull
(
user
.
getNickname
())){
manager
.
append
(
","
).
append
(
user
.
getNickname
());
}
}
});
domain
.
setProjectManager
(
manager
.
toString
());
}
}
}
return
R
.
ok
(
domain
);
}
}
yifu-archives/yifu-archives-biz/src/main/resources/application.yml
View file @
e3cff5db
...
...
@@ -26,7 +26,7 @@ mybatis-plus:
logic-not-delete-value
:
0
configuration
:
map-underscore-to-camel-case
:
true
#
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
log-impl
:
org.apache.ibatis.logging.stdout.StdOutImpl
# spring security 配置
security
:
...
...
yifu-archives/yifu-archives-biz/src/main/resources/mapper/TSettleDomainMapper.xml
View file @
e3cff5db
...
...
@@ -105,6 +105,9 @@
<result
property=
"csName"
column=
"cs_name"
/>
<result
property=
"csPhone"
column=
"cs_phone"
/>
<result
property=
"csLoginName"
column=
"cs_login_name"
/>
<!-- 2025-03-31 FXJ V1.7.9 -->
<result
property=
"projectManager"
column=
"PROJECT_MANAGER"
/>
</resultMap>
<resultMap
id=
"tSettleDomainTwoMap"
type=
"com.yifu.cloud.plus.v1.yifu.archives.vo.SecondBelongVo"
>
...
...
@@ -194,7 +197,8 @@
a.DIVISION,
a.cs_name,
a.cs_phone,
a.cs_login_name
a.cs_login_name,
a.PROJECT_MANAGER
</sql>
<resultMap
id=
"tSettleDomainSelectVoMap"
type=
"com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo"
>
...
...
@@ -234,6 +238,9 @@
<result
property=
"csName"
column=
"cs_name"
/>
<result
property=
"csPhone"
column=
"cs_phone"
/>
<result
property=
"csLoginName"
column=
"cs_login_name"
/>
<!-- 2025-03-31 FXJ V1.7.9 -->
<result
property=
"projectManager"
column=
"PROJECT_MANAGER"
/>
</resultMap>
<select
id=
"getPage"
resultMap=
"tSettleDomainMap"
>
...
...
@@ -434,7 +441,7 @@
a.DIVISION,
a.cs_name,
a.cs_phone,
a.cs_login_name
a.cs_login_name
,a.PROJECT_MANAGER
FROM
t_settle_domain a
<if
test=
"userId != null and userId.trim() != '-999'"
>
...
...
yifu-permission/yifu-permission-biz/src/main/resources/mapper/SysUserPermissionMapper.xml
View file @
e3cff5db
...
...
@@ -407,6 +407,16 @@
LEFT JOIN sys_org_element e on e.fd_id = d.fd_3ae55447e30d62
JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId}
union ALL
select
e.fd_name EMP_NAME,p.fd_login_name EMP_LOGIN_NAME,SUBSTRING_INDEX(SUBSTRING_INDEX(e.fd_ldap_dn,',ou', 2),',ou=', -1) EMP_DEPT
,'5' PERMISSION_TYPE,d.fd_3a829ae9bab760 NAME,d.fd_3a829aea0b84a4 CODE,0 SOURCE_TYPE
,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID
from ekp_fb3b8d0c8f148639b8e2 d
LEFT JOIN sys_org_element e on e.fd_id = d.fd_dept_manager
JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId}
) a GROUP BY a.USER_ID
</select>
...
...
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