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
b53f7b3e
Commit
b53f7b3e
authored
Mar 18, 2025
by
fangxinjiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
项目规则配置-代码优化-fxj
parent
dbc8e587
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
TAutoMainRelServiceImpl.java
...1/yifu/archives/service/impl/TAutoMainRelServiceImpl.java
+4
-2
No files found.
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TAutoMainRelServiceImpl.java
View file @
b53f7b3e
...
...
@@ -81,6 +81,8 @@ public class TAutoMainRelServiceImpl extends ServiceImpl<TAutoMainRelMapper, TAu
public
static
final
String
itemsLabel
=
"label,description,disable"
;
public
static
final
String
itemsLabelRepeat
=
"同一项目岗位名称不可重复"
;
/**
* 项目配置表主表简单分页查询
* @param tAutoMainRel 项目配置表主表
...
...
@@ -270,7 +272,7 @@ public class TAutoMainRelServiceImpl extends ServiceImpl<TAutoMainRelMapper, TAu
Set
<
String
>
repeatItems
=
new
HashSet
<>();
for
(
SysAutoDictItem
item:
autoDictItems
)
{
if
(
Common
.
isNotNull
(
repeatItems
.
contains
(
item
.
getLabel
())))
{
return
R
.
failed
(
"同一项目岗位名称不可重复"
);
return
R
.
failed
(
itemsLabelRepeat
);
}
}
//新增主表
...
...
@@ -385,7 +387,7 @@ public class TAutoMainRelServiceImpl extends ServiceImpl<TAutoMainRelMapper, TAu
if
(
Common
.
isNotNull
(
repeatItems
))
{
checkItem
=
repeatItems
.
get
(
item
.
getLabel
());
if
(
null
!=
checkItem
&&
item
.
getLabel
().
equals
(
checkItem
.
getLabel
())){
return
R
.
failed
(
"同一项目岗位名称不可重复"
);
return
R
.
failed
(
itemsLabelRepeat
);
}
repeatItems
.
put
(
item
.
getLabel
(),
item
);
}
...
...
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