From c042d33c233246c4877b8a16f65aeb5ed27560c3 Mon Sep 17 00:00:00 2001 From: linbangquan <1437892690@qq.com> Date: Mon, 15 Jan 2024 20:04:27 +0800 Subject: [PATCH] =?UTF-8?q?[=E4=BF=AE=E5=A4=8D]=20cmdb=E8=8A=82=E7=82=B9-?= =?UTF-8?q?=E6=8A=9B=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 关联 #[1069647498018816]cmdb节点-抛异常 http://192.168.0.96:8090/demo/rdm.html#/bug-detail/939050947543040/939050947543057/1069647498018816 --- .../cmdb/exception/attr/AttrValueIrregularException.java | 2 +- .../framework/cmdb/exception/ci/CiUniqueRuleException.java | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/neatlogic/framework/cmdb/exception/attr/AttrValueIrregularException.java b/src/main/java/neatlogic/framework/cmdb/exception/attr/AttrValueIrregularException.java index 355ac6d..9163560 100644 --- a/src/main/java/neatlogic/framework/cmdb/exception/attr/AttrValueIrregularException.java +++ b/src/main/java/neatlogic/framework/cmdb/exception/attr/AttrValueIrregularException.java @@ -22,7 +22,7 @@ import neatlogic.framework.exception.core.ApiRuntimeException; public class AttrValueIrregularException extends ApiRuntimeException { public AttrValueIrregularException(AttrVo attrVo, String value) { - super("属性“{0}({1})”的值“{2}”不是合法的{3}类型", attrVo.getLabel(), attrVo.getName(), value, attrVo.getTypeText()); + super("模型“{0}({1})”属性“{2}({3})”的值“{4}”不是合法的{3}类型", attrVo.getCiLabel(), attrVo.getCiName(), attrVo.getLabel(), attrVo.getName(), value, attrVo.getTypeText()); } } diff --git a/src/main/java/neatlogic/framework/cmdb/exception/ci/CiUniqueRuleException.java b/src/main/java/neatlogic/framework/cmdb/exception/ci/CiUniqueRuleException.java index e5af26d..0b666e3 100644 --- a/src/main/java/neatlogic/framework/cmdb/exception/ci/CiUniqueRuleException.java +++ b/src/main/java/neatlogic/framework/cmdb/exception/ci/CiUniqueRuleException.java @@ -23,4 +23,8 @@ public class CiUniqueRuleException extends ApiRuntimeException { public CiUniqueRuleException(CiVo ciVo) { super("模型“{0}({1})”存在拥有相同唯一规则属性的配置项", ciVo.getLabel(), ciVo.getName()); } + + public CiUniqueRuleException(CiVo ciVo, String value) { + super("模型“{0}({1})”存在拥有相同唯一规则属性的配置项“{2}”", ciVo.getLabel(), ciVo.getName(), value); + } } -- Gitee