Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
I
indicators
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
zhangkb
indicators
Commits
26762fba
Commit
26762fba
authored
Aug 07, 2020
by
张祺
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改任务生成的问题
parent
5b3dc947
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
16 deletions
+15
-16
Constants.java
...ain/java/com/keymobile/indicators/constant/Constants.java
+6
-0
TaskServiceImpl.java
...le/indicators/service/dataenter/impl/TaskServiceImpl.java
+9
-16
No files found.
src/main/java/com/keymobile/indicators/constant/Constants.java
View file @
26762fba
...
...
@@ -165,4 +165,10 @@ public class Constants {
* ruleType=3 县级对标
*/
public
static
final
int
RULE_TYPE_COUNTY
=
3
;
public
static
final
String
PRIVINCE_TO_CITY
=
"省对市"
;
public
static
final
String
PRIVINCE_TO_COUNTY
=
"省对县"
;
public
static
final
String
CITY_TO_COUNTY
=
"市对县"
;
}
src/main/java/com/keymobile/indicators/service/dataenter/impl/TaskServiceImpl.java
View file @
26762fba
...
...
@@ -277,21 +277,14 @@ public class TaskServiceImpl implements TaskService {
Result
result
=
null
;
Date
now
=
new
Date
();
Task
task
=
taskMapper
.
getById
(
taskId
);
Integer
ruleType
=
task
.
getRuleType
();
String
ruleLevel
=
task
.
getRuleLevel
();
ConfigInfo
configInfo
=
null
;
switch
(
ruleType
)
{
case
Constants
.
RULE_TYPE_PROVINCE
:
if
(
Constants
.
PRIVINCE_TO_CITY
.
equals
(
ruleLevel
))
{
configInfo
=
configInfoService
.
getConfigInfoById
(
Constants
.
RULE_PROVINCE_AUDIT_ROLE
);
break
;
case
Constants
.
RULE_TYPE_CITY
:
}
else
if
(
Constants
.
PRIVINCE_TO_COUNTY
.
equals
(
ruleLevel
))
{
configInfo
=
configInfoService
.
getConfigInfoById
(
Constants
.
RULE_CITY_AUDIT_ROLE
);
break
;
case
Constants
.
RULE_TYPE_COUNTY
:
}
else
if
(
Constants
.
CITY_TO_COUNTY
.
equals
(
ruleLevel
))
{
configInfo
=
configInfoService
.
getConfigInfoById
(
Constants
.
RULE_COUNTY_AUDIT_ROLE
);
break
;
default
:
configInfo
=
configInfoService
.
getConfigInfoById
(
Constants
.
RULE_PROVINCE_AUDIT_ROLE
);
break
;
}
if
(
configInfo
!=
null
)
{
String
indDept
=
task
.
getRefIndDept
();
...
...
@@ -346,15 +339,15 @@ public class TaskServiceImpl implements TaskService {
LogManager
.
logInfo
(
Constants
.
LOG_CONTEXT_API
,
"{}提交任务id:{},name:{}到审核"
,
user
,
taskId
,
task
.
getRuleName
());
}
else
{
result
=
Result
.
genFailedResult
(
"此配置此任务审批人,rule
Type="
+
ruleType
+
",归属部门="
+
indDept
);
result
=
Result
.
genFailedResult
(
"此配置此任务审批人,rule
Level="
+
ruleLevel
+
",归属部门="
+
indDept
);
}
}
else
{
result
=
Result
.
genFailedResult
(
"系统配置的角色没有用户,rule
Type="
+
ruleType
);
result
=
Result
.
genFailedResult
(
"系统配置的角色没有用户,rule
Level="
+
ruleLevel
);
}
}
else
{
result
=
Result
.
genFailedResult
(
"系统没有配置此任务的审批角色,rule
Type="
+
ruleType
);
LogManager
.
logInfo
(
Constants
.
LOG_CONTEXT_API
,
"提交任务taskId={}失败没有配置rule
Type
={}的审批角色"
,
taskId
,
rule
Type
);
result
=
Result
.
genFailedResult
(
"系统没有配置此任务的审批角色,rule
Level="
+
ruleLevel
);
LogManager
.
logInfo
(
Constants
.
LOG_CONTEXT_API
,
"提交任务taskId={}失败没有配置rule
Level
={}的审批角色"
,
taskId
,
rule
Level
);
}
return
result
;
}
...
...
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