|
@@ -1686,6 +1686,13 @@ public class WebMediatorImpl implements ViewMediator {
|
|
|
Optional<EndPointPO> endPointPOOptional = endPointDao.findByTaskCode(task.getCode());
|
|
|
TaskOperationControl taskOperationControl = new TaskOperationControl();
|
|
|
|
|
|
+ if (user.getRoleList().stream().anyMatch(role -> role.getName().equals("SystemAdministrator"))
|
|
|
+ || (user.getRegionalManager() != null && user.getId().equals(project.getRegionalManagerId()))) {
|
|
|
+ // 不管何时都可以导出任务
|
|
|
+ taskOperationControl.setExportTask(true);
|
|
|
+ taskOperationControl.setForkTask(true);
|
|
|
+ }
|
|
|
+
|
|
|
if (user == null || task.getStatus() == CrowdTestTaskStatus.HAS_TIME_OUT) {
|
|
|
return taskOperationControl;
|
|
|
}
|
|
@@ -1697,12 +1704,6 @@ public class WebMediatorImpl implements ViewMediator {
|
|
|
taskOperationControl.setTaskDemonstrate(true);
|
|
|
}
|
|
|
}
|
|
|
- if (user.getRoleList().stream().anyMatch(role -> role.getName().equals("SystemAdministrator"))
|
|
|
- || (user.getRegionalManager() != null && user.getId().equals(project.getRegionalManagerId()))) {
|
|
|
- // 不管何时都可以导出任务
|
|
|
- taskOperationControl.setExportTask(true);
|
|
|
- taskOperationControl.setForkTask(true);
|
|
|
- }
|
|
|
}else{
|
|
|
//区域管理员或系统管理员视角
|
|
|
if (user.getRoleList().stream().anyMatch(role -> role.getName().equals("SystemAdministrator"))
|