Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
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
项目统一框架
amos-boot-biz
Commits
9bcbbe81
Commit
9bcbbe81
authored
Aug 17, 2021
by
chenhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改流程中登陸人中文獲取的黨法
parent
e8981cde
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
110 additions
and
91 deletions
+110
-91
FailureRepairlog.java
.../amos/boot/module/common/api/entity/FailureRepairlog.java
+5
-0
IFailureRepairlogService.java
...t/module/common/api/service/IFailureRepairlogService.java
+1
-1
FailureDetailsServiceImpl.java
...le/common/biz/service/impl/FailureDetailsServiceImpl.java
+101
-87
FailureRepairlogServiceImpl.java
.../common/biz/service/impl/FailureRepairlogServiceImpl.java
+3
-3
No files found.
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/entity/FailureRepairlog.java
View file @
9bcbbe81
...
...
@@ -32,6 +32,11 @@ public class FailureRepairlog extends BaseEntity {
*/
@TableField
(
"process_auditor"
)
private
String
processAuditor
;
/**
* 流程处理人
*/
@TableField
(
"process_auditor_name"
)
private
String
processAuditorName
;
/**
* 处理人所属部门
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/service/IFailureRepairlogService.java
View file @
9bcbbe81
...
...
@@ -9,7 +9,7 @@ import com.yeejoin.amos.boot.module.common.api.entity.FailureRepairlog;
* @date 2021-08-12
*/
public
interface
IFailureRepairlogService
{
public
FailureRepairlog
findByprocessAuditor
Id
(
Lo
ng
userId
);
public
FailureRepairlog
findByprocessAuditor
(
Stri
ng
userId
);
public
FailureRepairlog
findByFaultId
(
Long
faultId
)
;
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/service/impl/FailureDetailsServiceImpl.java
View file @
9bcbbe81
package
com
.
yeejoin
.
amos
.
boot
.
module
.
common
.
biz
.
service
.
impl
;
import
java.lang.reflect.InvocationTargetException
;
import
java.text.SimpleDateFormat
;
import
java.util.ArrayList
;
import
java.util.Collections
;
...
...
@@ -10,6 +11,7 @@ import java.util.Map;
import
java.util.Random
;
import
org.apache.commons.lang3.ObjectUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -17,6 +19,7 @@ import org.springframework.beans.factory.annotation.Value;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.interceptor.TransactionAspectSupport
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
com.alibaba.fastjson.JSONArray
;
...
...
@@ -24,7 +27,9 @@ import com.alibaba.fastjson.JSONObject;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.toolkit.BeanUtils
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.itextpdf.text.pdf.PdfStructTreeController.returnType
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.biz.common.workflow.feign.WorkflowFeignService
;
import
com.yeejoin.amos.boot.module.common.api.dto.FailureDetailsDto
;
...
...
@@ -73,7 +78,7 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
IFailureRepairlogService
failureRepairlog
;
public
static
String
EMERGENCY_COMMAND
=
"应急指挥科"
;
public
static
String
[]
PROCESS_NAME
=
{
"提交维修单"
,
"审核"
,
"维修"
,
"验收"
};
public
static
String
[]
PROCESS_NAME
=
{
"提交维修单"
,
"审核"
,
"维修"
,
"验收"
};
private
final
Logger
logger
=
LoggerFactory
.
getLogger
(
FailureDetailsServiceImpl
.
class
);
...
...
@@ -84,21 +89,18 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
/**
* 分页查询
*/
public
IPage
<
FailureDetails
>
queryAllPage
(
long
size
,
long
current
)
{
public
IPage
<
FailureDetails
>
queryAllPage
(
long
size
,
long
current
)
{
QueryWrapper
<
FailureDetails
>
wrapper
=
new
QueryWrapper
<>();
wrapper
.
orderByDesc
(
"submission_time"
);
IPage
<
FailureDetails
>
page
=
new
Page
<>(
current
,
size
);
return
baseMapper
.
selectPage
(
page
,
wrapper
);
}
public
IPage
<
FailureDetails
>
queryForFailureDetailsPage
(
Page
<
FailureDetails
>
page
,
AgencyUserModel
userInfo
,
Integer
type
)
{
public
IPage
<
FailureDetails
>
queryForFailureDetailsPage
(
Page
<
FailureDetails
>
page
,
AgencyUserModel
userInfo
,
Integer
type
)
{
if
(
type
.
equals
(
SELECY_ALL
)
)
{
return
this
.
queryAllPage
(
page
.
getSize
(),
page
.
getCurrent
());
if
(
type
.
equals
(
SELECY_ALL
))
{
return
this
.
queryAllPage
(
page
.
getSize
(),
page
.
getCurrent
());
}
if
(
type
.
equals
(
SELECY_ISUBMIT
))
{
...
...
@@ -106,7 +108,7 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
return
queryForPage
(
page
,
userInfo
.
getUserId
());
}
return
this
.
queryForWaitManage
(
page
,
userInfo
.
getUserId
());
return
this
.
queryForWaitManage
(
page
,
userInfo
.
getUserId
());
}
/**
...
...
@@ -117,7 +119,7 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
return
null
;
}
QueryWrapper
<
FailureDetails
>
wrapper
=
new
QueryWrapper
<>();
wrapper
.
eq
(
"submission_pid"
,
submissionPid
);
wrapper
.
eq
(
"submission_pid"
,
submissionPid
);
wrapper
.
orderByDesc
(
"submission_time"
);
IPage
<
FailureDetails
>
failureDetailsPage
=
new
Page
<>(
page
.
getCurrent
(),
page
.
getSize
());
return
baseMapper
.
selectPage
(
failureDetailsPage
,
wrapper
);
...
...
@@ -131,16 +133,14 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
return
null
;
}
QueryWrapper
<
FailureDetails
>
wrapper
=
new
QueryWrapper
<>();
wrapper
.
eq
(
"submission_pid"
,
submissionPid
);
wrapper
.
notIn
(
"current_status"
,
FailureStatuEnum
.
REFUSE
.
getCode
(),
FailureStatuEnum
.
FINISH
.
getCode
(),
wrapper
.
eq
(
"submission_pid"
,
submissionPid
);
wrapper
.
notIn
(
"current_status"
,
FailureStatuEnum
.
REFUSE
.
getCode
(),
FailureStatuEnum
.
FINISH
.
getCode
(),
FailureStatuEnum
.
WAITING_AUDIT
.
getCode
());
wrapper
.
orderByDesc
(
"submission_time"
);
IPage
<
FailureDetails
>
failureDetailsPage
=
new
Page
<>(
page
.
getCurrent
(),
page
.
getSize
());
return
baseMapper
.
selectPage
(
failureDetailsPage
,
wrapper
);
}
/**
* 列表查询 示例
*/
...
...
@@ -152,13 +152,13 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
* 根据状态查询
*/
public
FailureDetailsDto
queryForOne
(
Long
sequenceNbr
){
public
FailureDetailsDto
queryForOne
(
Long
sequenceNbr
)
{
FailureDetailsDto
failureDetailsDto
=
this
.
queryBySeq
(
sequenceNbr
);
failureDetailsDto
.
setCurrentStatusName
(
Constants
.
currentStatusNameMap
.
get
(
failureDetailsDto
.
getCurrentStatus
()));
failureDetailsDto
.
setCurrentStatusName
(
Constants
.
currentStatusNameMap
.
get
(
failureDetailsDto
.
getCurrentStatus
()));
List
<
SourceFile
>
sourceFiles
=
sourceFileServiceImpl
.
findBySourceId
(
sequenceNbr
);
failureDetailsDto
.
setAttachment
(
sourceFiles
);
return
failureDetailsDto
;
return
failureDetailsDto
;
}
/**
...
...
@@ -174,77 +174,74 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
list
.
add
(
FailureStatuEnum
.
REFUSE
);
list
.
add
(
FailureStatuEnum
.
FINISH
);
for
(
int
i
=
0
;
i
<
list
.
size
();
i
++)
{
if
(
currentStatus
.
equals
(
list
.
get
(
i
).
getCode
())){
if
(
currentStatus
.
equals
(
list
.
get
(
i
).
getCode
()))
{
status
=
list
.
get
(
i
).
getName
();
};
}
/*FailureStatuEnum[] failureStatuEnums = new FailureStatuEnum []{};*/
;
}
/* FailureStatuEnum[] failureStatuEnums = new FailureStatuEnum []{}; */
QueryWrapper
<
FailureDetails
>
queryWrapper
=
new
QueryWrapper
<>();
queryWrapper
.
eq
(
"current_status"
,
status
).
orderByDesc
(
"submission_time"
);
return
baseMapper
.
selectList
(
queryWrapper
);
}
/**
* 查询任务状态数量
*/
public
List
<
FailureStatusCountDto
>
queryStatusCount
(
Integer
type
)
{
List
<
FailureDetailsDto
>
failureDetailsDtos
=
new
ArrayList
<>();
List
<
FailureDetailsDto
>
failureDetailsDtos
=
new
ArrayList
<>();
if
(
type
.
equals
(
SELECY_ALL
))
{
failureDetailsDtos
=
this
.
queryForFailureDetailsList
();
}
if
(
type
.
equals
(
SELECY_ISUBMIT
))
{
failureDetailsDtos
=
this
.
queryForFailureDetailsList
();
}
int
auditStatus
=
0
;
int
submitStatus
=
0
;
int
maintainStatus
=
0
;
int
acceptanceStatus
=
0
;
int
refuseStatus
=
0
;
int
finishStatus
=
0
;
int
inMaintenance
=
0
;
int
auditStatus
=
0
;
int
submitStatus
=
0
;
int
maintainStatus
=
0
;
int
acceptanceStatus
=
0
;
int
refuseStatus
=
0
;
int
finishStatus
=
0
;
int
inMaintenance
=
0
;
List
<
FailureStatusCountDto
>
list
=
new
ArrayList
<>();
// String[] statusName = new String[]{"待审核", "待提交", "待维修", "待验收", "已拒绝", "已完结"};
List
<
String
>
statusName
=
new
ArrayList
<>();
Collections
.
addAll
(
statusName
,
FailureStatuEnum
.
WAITING_AUDIT
.
getName
(),
FailureStatuEnum
.
WAITING_SUBMIT
.
getName
(),
FailureStatuEnum
.
WAITING_MAINTAIN
.
getName
(),
FailureStatuEnum
.
WAITING_ACCEPTANCE
.
getName
(),
FailureStatuEnum
.
REFUSE
.
getName
(),
FailureStatuEnum
.
FINISH
.
getName
(),
FailureStatuEnum
.
IN_MAINTENANCE
.
getName
());
FailureStatuEnum
.
WAITING_SUBMIT
.
getName
(),
FailureStatuEnum
.
WAITING_MAINTAIN
.
getName
(),
FailureStatuEnum
.
WAITING_ACCEPTANCE
.
getName
(),
FailureStatuEnum
.
REFUSE
.
getName
(),
FailureStatuEnum
.
FINISH
.
getName
(),
FailureStatuEnum
.
IN_MAINTENANCE
.
getName
());
for
(
int
i
=
0
;
i
<
failureDetailsDtos
.
size
();
i
++)
{
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
WAITING_AUDIT
.
getCode
())){
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
WAITING_AUDIT
.
getCode
()))
{
auditStatus
++;
}
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
WAITING_SUBMIT
.
getCode
())){
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
WAITING_SUBMIT
.
getCode
()))
{
submitStatus
++;
}
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
WAITING_MAINTAIN
.
getCode
())){
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
WAITING_MAINTAIN
.
getCode
()))
{
maintainStatus
++;
}
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
WAITING_ACCEPTANCE
.
getCode
())){
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
WAITING_ACCEPTANCE
.
getCode
()))
{
acceptanceStatus
++;
}
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
REFUSE
.
getCode
())){
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
REFUSE
.
getCode
()))
{
refuseStatus
++;
}
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
FINISH
.
getCode
())){
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
FINISH
.
getCode
()))
{
finishStatus
++;
}
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
IN_MAINTENANCE
.
getCode
())){
if
(
failureDetailsDtos
.
get
(
i
).
getCurrentStatus
().
equals
(
FailureStatuEnum
.
IN_MAINTENANCE
.
getCode
()))
{
inMaintenance
++;
}
}
int
[]
statusCount
=
{
auditStatus
,
submitStatus
,
maintainStatus
,
acceptanceStatus
,
refuseStatus
,
finishStatus
,
inMaintenance
};
int
[]
statusCount
=
{
auditStatus
,
submitStatus
,
maintainStatus
,
acceptanceStatus
,
refuseStatus
,
finishStatus
,
inMaintenance
};
for
(
int
i
=
0
;
i
<
statusName
.
size
();
i
++)
{
FailureStatusCountDto
statusCountDto
=
new
FailureStatusCountDto
();
FailureStatusCountDto
statusCountDto
=
new
FailureStatusCountDto
();
statusCountDto
.
setStatus
(
statusName
.
get
(
i
));
statusCountDto
.
setCount
(
statusCount
[
i
]);
list
.
add
(
statusCountDto
);
...
...
@@ -284,19 +281,21 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
model
=
this
.
createWithModel
(
failureDetailsDto
);
if
(
ObjectUtils
.
isNotEmpty
(
failureDetailsDto
.
getAttachment
()))
{
sourceFileServiceImpl
.
saveSourceFile
(
failureDetailsDto
.
getSequenceNbr
(),
failureDetailsDto
.
getAttachment
());
sourceFileServiceImpl
.
saveSourceFile
(
failureDetailsDto
.
getSequenceNbr
(),
failureDetailsDto
.
getAttachment
());
}
//添加至报修日志
//
添加至报修日志
try
{
Long
faultId
=
model
.
getSequenceNbr
();
String
processAuditor
=
model
.
getRecUserName
();
Integer
processAuditorId
=
model
.
getSubmissionPid
();
String
processResult
=
"提交报修单"
;
String
processDepartment
=
userInfo
.
getDepartment
().
getDepartmentName
();
Long
departmentId
=
userInfo
.
getDepartment
().
getSequenceNbr
();
Long
departmentId
=
userInfo
.
getDepartment
().
getSequenceNbr
();
Date
processTime
=
model
.
getSubmissionTime
();
repairlog
(
faultId
,
processAuditor
,
processAuditorId
,
departmentId
,
processTime
,
processDepartment
,
processResult
);
}
catch
(
Exception
e
){
repairlog
(
faultId
,
processAuditor
,
processAuditorId
,
departmentId
,
processTime
,
processDepartment
,
processResult
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
logger
.
info
(
"添加流程日志到数据库失败"
);
TransactionAspectSupport
.
currentTransactionStatus
().
setRollbackOnly
();
...
...
@@ -309,11 +308,11 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
return
false
;
// return CommonResponseUtil.failure("添加失败");
}
try
{
try
{
if
(
ObjectUtils
.
isNotEmpty
(
model
))
{
excuteTask
(
instance
.
getString
(
"id"
),
userInfo
,
null
);
}
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
false
;
}
...
...
@@ -325,8 +324,8 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
* 添加报修日志
*/
@Transactional
public
Boolean
repairlog
(
Long
faultId
,
String
processAuditor
,
Integer
processAuditorId
,
Long
departmentId
,
Date
processTime
,
String
processDepartment
,
String
processResult
)
{
public
Boolean
repairlog
(
Long
faultId
,
String
processAuditor
,
Integer
processAuditorId
,
Long
departmentId
,
Date
processTime
,
String
processDepartment
,
String
processResult
)
{
FailureRepairlogDto
failureRepairlogDto
=
new
FailureRepairlogDto
();
failureRepairlogDto
.
setFaultId
(
faultId
);
failureRepairlogDto
.
setProcessAuditor
(
processAuditor
);
...
...
@@ -336,7 +335,7 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
failureRepairlogDto
.
setProcessDepartment
(
processDepartment
);
failureRepairlogDto
.
setProcessResult
(
processResult
);
FailureRepairlogDto
RepairlogModel
=
failureRepairlogService
.
createWithModel
(
failureRepairlogDto
);
if
(
ObjectUtils
.
isNotEmpty
(
RepairlogModel
)){
if
(
ObjectUtils
.
isNotEmpty
(
RepairlogModel
))
{
return
true
;
}
return
false
;
...
...
@@ -489,22 +488,36 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
public
Object
getCurrentProcessHistoryTask
(
Long
id
)
{
FailureDetailsDto
failureDetailsDto
=
this
.
queryBySeq
(
id
);
String
processId
=
failureDetailsDto
.
getProcessId
();
JSONObject
object
=
workflowFeignService
.
queryHistoryTaskListByProcessId
(
processId
);
JSONArray
datArray
=
null
;
if
(
ObjectUtils
.
isNotEmpty
(
object
))
{
datArray
=
object
.
getJSONArray
(
"rows
"
);
JSONObject
object
=
workflowFeignService
.
queryHistoryTaskListByProcessId
(
processId
);
JSONArray
datArray
=
null
;
if
(
ObjectUtils
.
isNotEmpty
(
object
))
{
datArray
=
object
.
getJSONArray
(
"data
"
);
}
List
<
Object
>
list
=
new
ArrayList
<
Object
>();
if
(
datArray
!=
null
)
{
datArray
.
stream
().
forEach
(
i
->
{
if
(
datArray
!=
null
)
{
for
(
Object
i
:
datArray
)
{
JSONObject
detail
=
JSONObject
.
parseObject
(
JSONObject
.
toJSONString
(
i
));
if
(
detail
.
containsKey
(
"operator"
)
&&
!
detail
.
getString
(
"name"
).
equals
(
"维修中"
))
{
//从流程记录表中拿到处理人的名称
FailureRepairlog
failureRepairlog
=
failureRepairlogService
.
findByprocessAuditorId
(
Long
.
parseLong
(
detail
.
getString
(
"operator"
)));
detail
.
replace
(
"operator"
,
failureRepairlog
.
getProcessAuditor
());
list
.
add
(
object
);
}
});
if
(
detail
.
containsKey
(
"operator"
)
&&
!
detail
.
getString
(
"name"
).
contains
(
"维修中"
))
{
// 从流程记录表中拿到处理人的名称
FailureRepairlog
failureRepairlog
=
failureRepairlogService
.
findByprocessAuditor
(
detail
.
getString
(
"operator"
));
if
(
failureRepairlog
!=
null
)
{
detail
.
replace
(
"operator"
,
failureRepairlog
.
getProcessAuditorName
()==
null
?
""
:
failureRepairlog
.
getProcessAuditorName
());
}
}
list
.
add
(
detail
);
}
// datArray.stream().forEach(i -> {
// JSONObject detail = JSONObject.parseObject(JSONObject.toJSONString(i));
// if (detail.containsKey("operator") && !detail.getString("name").equals("维修中")) {
// // 从流程记录表中拿到处理人的名称
// FailureRepairlog failureRepairlog = failureRepairlogService
// .findByprocessAuditor(detail.getString("operator"));
// detail.replace("operator", failureRepairlog.getProcessAuditorName());
// list.add(detail);
// }
// });
}
return
list
;
}
...
...
@@ -522,35 +535,36 @@ public class FailureDetailsServiceImpl extends BaseService<FailureDetailsDto, Fa
/**
* 获取当前登录人能够操作的任务执行Button类型
*
* @param sequenceNbr
* @param userInfo
* @return
*/
public
Integer
getExcuteTaskAuthButton
(
Long
sequenceNbr
,
ReginParams
userInfo
)
{
int
flag
=
0
;
int
flag
=
0
;
Map
<
String
,
Object
>
map
=
this
.
checkExcuteTaskAuthMap
(
sequenceNbr
,
userInfo
);
if
(
Boolean
.
parseBoolean
(
map
.
get
(
"checkFlag"
).
toString
()))
{
if
(
Boolean
.
parseBoolean
(
map
.
get
(
"checkFlag"
).
toString
()))
{
String
buttonValueString
=
map
.
get
(
"name"
).
toString
();
if
(
buttonValueString
.
endsWith
(
PROCESS_NAME
[
0
]))
{
//
提交维修单
flag
=
1
;
}
else
if
(
buttonValueString
.
endsWith
(
PROCESS_NAME
[
1
]))
{
//
审核
flag
=
2
;
if
(
buttonValueString
.
startsWith
(
PROCESS_NAME
[
2
]))
{
flag
=
3
;
if
(
buttonValueString
.
endsWith
(
PROCESS_NAME
[
0
]))
{
//
提交维修单
flag
=
1
;
}
else
if
(
buttonValueString
.
endsWith
(
PROCESS_NAME
[
1
]))
{
//
审核
flag
=
2
;
if
(
buttonValueString
.
startsWith
(
PROCESS_NAME
[
2
]))
{
flag
=
3
;
}
}
else
if
(
buttonValueString
.
endsWith
(
PROCESS_NAME
[
2
]))
{
//
维修
flag
=
4
;
}
else
if
(
buttonValueString
.
endsWith
(
PROCESS_NAME
[
3
]))
{
//
验收
flag
=
5
;
}
else
if
(
buttonValueString
.
endsWith
(
PROCESS_NAME
[
2
]))
{
//
维修
flag
=
4
;
}
else
if
(
buttonValueString
.
endsWith
(
PROCESS_NAME
[
3
]))
{
//
验收
flag
=
5
;
}
}
FailureDetails
details
=
this
.
baseMapper
.
selectById
(
sequenceNbr
);
JSONObject
object
=
workflowFeignService
.
queryHistoryTasksByProcessInstanceId
(
details
.
getProcessId
());
JSONArray
array
=
object
.
getJSONArray
(
"rows"
);
JSONObject
object
=
workflowFeignService
.
queryHistoryTasksByProcessInstanceId
(
details
.
getProcessId
());
JSONArray
array
=
object
.
getJSONArray
(
"rows"
);
for
(
Object
historyDetail
:
array
)
{
JSONObject
historyDetailJson
=
JSONObject
.
parseObject
(
JSONObject
.
toJSONString
(
historyDetail
));
if
(
"rejected"
.
equals
(
historyDetailJson
.
getString
(
"activityId"
)))
{
flag
=
6
;
JSONObject
historyDetailJson
=
JSONObject
.
parseObject
(
JSONObject
.
toJSONString
(
historyDetail
));
if
(
"rejected"
.
equals
(
historyDetailJson
.
getString
(
"activityId"
)))
{
flag
=
6
;
}
}
return
flag
;
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/service/impl/FailureRepairlogServiceImpl.java
View file @
9bcbbe81
...
...
@@ -47,9 +47,9 @@ public class FailureRepairlogServiceImpl extends BaseService<FailureRepairlogDto
}
public
FailureRepairlog
findByprocessAuditor
Id
(
Lo
ng
userId
)
{
QueryWrapper
<
FailureRepairlog
>
queryWrapper
=
new
QueryWrapper
<
FailureRepairlog
>();
queryWrapper
.
eq
(
"process_auditor_id"
,
userId
);
public
FailureRepairlog
findByprocessAuditor
(
Stri
ng
userId
)
{
LambdaQueryWrapper
<
FailureRepairlog
>
queryWrapper
=
new
Lambda
QueryWrapper
<
FailureRepairlog
>();
queryWrapper
.
eq
(
FailureRepairlog:
:
getProcessAuditor
,
userId
);
queryWrapper
.
last
(
"LIMIT 1"
);
return
baseMapper
.
selectOne
(
queryWrapper
);
}
...
...
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