From 366c1c889615dd7293294d0f08f0943d4f3d7f0d Mon Sep 17 00:00:00 2001 From: admin <1628672303@qq.com> Date: Wed, 24 May 2023 09:56:09 +0800 Subject: [PATCH] 5-24 --- .../skillType/controller/SkillTypeController.java | 3 ++- .../modules/taskSkill/entity/TaskSkillConstant.java | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/taskSkill/entity/TaskSkillConstant.java diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/skillType/controller/SkillTypeController.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/skillType/controller/SkillTypeController.java index 8ca30a8..6cc8c91 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/skillType/controller/SkillTypeController.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/skillType/controller/SkillTypeController.java @@ -12,6 +12,7 @@ import org.jeecg.common.system.base.controller.JeecgController; import org.jeecg.common.system.query.QueryGenerator; import org.jeecg.modules.skillType.entity.SkillType; import org.jeecg.modules.skillType.service.ISkillTypeService; +import org.jeecg.modules.taskSkill.entity.TaskSkillConstant; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; import org.springframework.web.servlet.ModelAndView; @@ -68,7 +69,7 @@ public class SkillTypeController extends JeecgController add(@RequestBody SkillType skillType) { if (skillType.getSupertypeId() == null){ - skillType.setSupertypeId("-1"); + skillType.setSupertypeId(TaskSkillConstant.skill_superType); } skillTypeService.save(skillType); return Result.OK("添加成功!"); diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/taskSkill/entity/TaskSkillConstant.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/taskSkill/entity/TaskSkillConstant.java new file mode 100644 index 0000000..e012178 --- /dev/null +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/taskSkill/entity/TaskSkillConstant.java @@ -0,0 +1,11 @@ +package org.jeecg.modules.taskSkill.entity; + +/** + * @author admin + */ +public interface TaskSkillConstant { + /** + * 任务技能类型的父类型默认值 + */ + public final String skill_superType="-1"; +}