Skip to content

Commit

Permalink
fix: batchEditFlowNode 3
Browse files Browse the repository at this point in the history
  • Loading branch information
qweqnotallow committed Sep 19, 2024
1 parent 7c7ea71 commit f5449ca
Showing 1 changed file with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1739,8 +1739,8 @@ private String modifyJson(String flowJson, EditFlowRequest editFlowRequest, Long
}
obj.addProperty("modifyTime", modifyTime);
obj.addProperty("modifyUser", username);
flowJsonAddProperty(obj, "title", title);
flowJsonAddProperty(obj, "desc", desc);
flowJsonAddPointProperty(obj, "title", title);
flowJsonAddPointProperty(obj, "desc", desc);
flowJsonAddProperty(obj, "appTag", appTag);
flowJsonAddProperty(obj, "businessTag", businessTag);
flowJsonAddProperty(obj, "ecConfTemplateId", ecConfTemplateId);
Expand All @@ -1752,9 +1752,17 @@ private String modifyJson(String flowJson, EditFlowRequest editFlowRequest, Long
return modifyJson;
}

private void flowJsonAddPointProperty(JsonObject obj, String contentName, String content) {
if (content != null) {
obj.addProperty(contentName, content);
}
}

private void flowJsonAddProperty(JsonObject obj, String contentName, String content) {
if (content != null) {
obj.addProperty(contentName, content);
} else {
obj.remove(contentName);
}
}

Expand Down

0 comments on commit f5449ca

Please sign in to comment.