You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

50 lines
990 B
Java

package com.ruoyi.common.event;
import lombok.Getter;
import org.springframework.context.ApplicationEvent;
import java.util.Map;
/**
* 短信发送结果事件
*/
@Getter
public class SmsResultEvent extends ApplicationEvent {
private String phones;
private String templateId;
private Map<String, String> param;
/**
* 是否成功
*/
private boolean isSuccess;
/**
* 响应消息
*/
private String message;
/**
* 实际响应体
* <p>
* 可自行转换为 SDK 对应的 SendSmsResponse
*/
private String response;
private Exception exception;
public SmsResultEvent(String phones, String templateId, Map<String, String> param, boolean isSuccess, String message, String response, Exception exception) {
super(phones);
this.phones = phones;
this.templateId = templateId;
this.param = param;
this.isSuccess = isSuccess;
this.message = message;
this.response = response;
this.exception = exception;
}
}