移除任务人员空指针处理;
This commit is contained in:
+4
-1
@@ -606,7 +606,10 @@ public class StockInOrderApplicationService {
|
|||||||
List<String> taskIds = Arrays.asList(split);
|
List<String> taskIds = Arrays.asList(split);
|
||||||
if (taskIds != null && taskIds.size() > 0) {
|
if (taskIds != null && taskIds.size() > 0) {
|
||||||
// 删除匹配元素
|
// 删除匹配元素
|
||||||
taskIds.removeIf(str -> removeUserId.equals(str));
|
//taskIds.removeIf(str -> removeUserId.equals(str));
|
||||||
|
taskIds = taskIds.stream()
|
||||||
|
.filter(str -> !Objects.equals(removeUserId, str))
|
||||||
|
.collect(Collectors.toList());
|
||||||
if (taskIds != null && taskIds.size() > 0) {
|
if (taskIds != null && taskIds.size() > 0) {
|
||||||
String newTaskIssueUserId = String.join(",", taskIds);
|
String newTaskIssueUserId = String.join(",", taskIds);
|
||||||
stock.setTaskIssueUserId(newTaskIssueUserId);
|
stock.setTaskIssueUserId(newTaskIssueUserId);
|
||||||
|
|||||||
+4
-1
@@ -1653,7 +1653,10 @@ public class StockOutOrderApplicationService {
|
|||||||
List<String> taskIds = Arrays.asList(split);
|
List<String> taskIds = Arrays.asList(split);
|
||||||
if (taskIds != null && taskIds.size() > 0) {
|
if (taskIds != null && taskIds.size() > 0) {
|
||||||
// 删除匹配元素
|
// 删除匹配元素
|
||||||
taskIds.removeIf(str -> removeUserId.equals(str));
|
//taskIds.removeIf(str -> removeUserId.equals(str));
|
||||||
|
taskIds = taskIds.stream()
|
||||||
|
.filter(str -> !Objects.equals(removeUserId, str))
|
||||||
|
.collect(Collectors.toList());
|
||||||
if (taskIds != null && taskIds.size() > 0) {
|
if (taskIds != null && taskIds.size() > 0) {
|
||||||
String newTaskIssueUserId = String.join(",", taskIds);
|
String newTaskIssueUserId = String.join(",", taskIds);
|
||||||
stock.setTaskIssueUserId(newTaskIssueUserId);
|
stock.setTaskIssueUserId(newTaskIssueUserId);
|
||||||
|
|||||||
Reference in New Issue
Block a user