| | |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.util.Assert; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.*; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | |
| | | fileService.saveBatch(fileList); |
| | | return Result.ok(); |
| | | } |
| | | |
| | | @Override |
| | | public Result getManagerFlag(Integer recordId) { |
| | | ProjectInfo projectInfo = baseMapper.selectById(recordId); |
| | | // 判断当前用户id是否在主管列表中 |
| | | String competentDepartment = projectInfo.getCompetentDepartment(); |
| | | List<String> list = Arrays.asList(competentDepartment.split(",")); |
| | | // 获得当前用户id |
| | | Long userId = SecurityUtils.getUserId(); |
| | | if (list.contains(userId.toString())) { |
| | | return Result.ok().data(true); |
| | | } else { |
| | | return Result.ok().data(false); |
| | | } |
| | | } |
| | | } |