From 0855a4ca66f005170bf527fd449c13031284681f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=8F=E8=90=8C=E6=96=B0?= <13658798+jjhyyds@user.noreply.gitee.com> Date: Thu, 25 Jul 2024 17:33:14 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AC=AC=E4=B8=80=E6=AC=A1=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../backend/service/impl/chapter/ChapterServiceImpl.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/teaching/backend/service/impl/chapter/ChapterServiceImpl.java b/src/main/java/com/teaching/backend/service/impl/chapter/ChapterServiceImpl.java index b9abb53..573f920 100644 --- a/src/main/java/com/teaching/backend/service/impl/chapter/ChapterServiceImpl.java +++ b/src/main/java/com/teaching/backend/service/impl/chapter/ChapterServiceImpl.java @@ -194,19 +194,18 @@ public class ChapterServiceImpl extends ServiceImpl impl } catch (Exception e) { throw new RuntimeException("复制数据出错", e); } - System.out.println(chapter); String pid = chapter.getPid(); if (pid == null || pid.isEmpty()) { - System.out.println("这是新增的一个父节点"); + chapter.setCreateTime(LocalDateTime.now()); chapter.setUpdateTime(LocalDateTime.now()); this.save(chapter); } else { - System.out.println("这是新增的一个子节点"); + Chapter parentChapter = this.getById(pid); if (parentChapter != null) {