禅道bug#1599修复

This commit is contained in:
gaoqr
2026-06-04 11:29:17 +08:00
parent c61f994ed5
commit c5a471f5cc
8 changed files with 64 additions and 10 deletions
@@ -0,0 +1,14 @@
package com.cf.imes.framework.common.exception;
import lombok.Data;
/**
* 异常错误数据:用于CommonResult.data
*
* @author Gqr
* @since 2026/6/4 10:40
*/
@Data
public class ErrorData {
private String errorData;
}
@@ -31,12 +31,24 @@ public final class ServiceException extends RuntimeException {
*/
private transient Object[] args;
/**
* 异常需要的回调数据
*/
private ErrorData errorData;
/**
* 空构造方法,避免反序列化问题
*/
public ServiceException() {
}
public ServiceException(ErrorCode errorCode, ErrorData errorData, Object... args) {
this.code = errorCode.getCode();
this.message = errorCode.getMsg();
this.errorData = errorData;
this.args = args;
}
public ServiceException(ErrorCode errorCode, Object... args) {
this.code = errorCode.getCode();
this.message = errorCode.getMsg();