| | |
| | | package com.hz.sms.dto; |
| | | |
| | | |
| | | import com.hx.util.StringUtils; |
| | | import lombok.Data; |
| | | |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | |
| | | |
| | | @Data |
| | | public class SmsGeneralSendDto { |
| | | |
| | | /*标识*/ |
| | | /* 标识 (记录sms_general_item表数据的id)*/ |
| | | private String id; |
| | | /* 账号*/ |
| | | private String account; |
| | | /* 密码*/ |
| | | private String password; |
| | | /*签名*/ |
| | | private String sign; |
| | | /* 定时短信时间,格式为yyyyMMddHHmm,值小于或等于当前时间则立即发送,默认立即发送*/ |
| | | private String timestamp; |
| | | /*短信内容*/ |
| | | private String msg; |
| | | /*手机号码*/ |
| | | private String phone; |
| | | /*定时发送短信时间*/ |
| | | private String sendtime; |
| | | private String sendTime; |
| | | /*如需状态报告则传true*/ |
| | | private String report = "false"; |
| | | private String report; |
| | | /*下发短信号码扩展码*/ |
| | | private String extend; |
| | | /*该条短信在您业务系统内的ID*/ |
| | | private String uid; |
| | | /*短信类型*/ |
| | | private Integer smsType; |
| | | /* 发送模式 (0: 立即发送; 1:异步发送)*/ |
| | | private Integer sendModel; |
| | | |
| | | |
| | | public SmsGeneralSendDto() { |
| | | } |
| | | |
| | | public SmsGeneralSendDto(String id, String msg, String phone, String sendtime, String report, String extend, String uid) { |
| | | this.id = id; |
| | | this.msg = msg; |
| | | this.phone = phone; |
| | | this.sendtime = sendtime; |
| | | this.report = report; |
| | | this.extend = extend; |
| | | this.uid = uid; |
| | | } |
| | | |
| | | public String getId() { |
| | | return id; |
| | | } |
| | | |
| | | public void setId(String id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | public String getMsg() { |
| | | return msg; |
| | | } |
| | | |
| | | public void setMsg(String msg) { |
| | | this.msg = msg; |
| | | } |
| | | |
| | | public String getPhone() { |
| | | return phone; |
| | | } |
| | | |
| | | public void setPhone(String phone) { |
| | | this.phone = phone; |
| | | } |
| | | |
| | | public String getSendtime() { |
| | | return sendtime; |
| | | } |
| | | public Date getDateSendTime(){ |
| | | try { |
| | | Date dateSendTime = new SimpleDateFormat("yyyyMMddHHmm").parse(sendtime); |
| | | Date dateSendTime = new SimpleDateFormat("yyyyMMddHHmm").parse(sendTime); |
| | | return dateSendTime; |
| | | }catch (Exception e){ |
| | | return null; |
| | | } |
| | | } |
| | | |
| | | public void setSendtime(String sendtime) { |
| | | this.sendtime = sendtime; |
| | | } |
| | | |
| | | public String getReport() { |
| | | if (!StringUtils.isEmpty(report) && !"true".equals(report)){ |
| | | return null; |
| | | } |
| | | return report; |
| | | } |
| | | |
| | | public void setReport(String report) { |
| | | this.report = report; |
| | | } |
| | | |
| | | public String getExtend() { |
| | | return extend; |
| | | } |
| | | |
| | | public void setExtend(String extend) { |
| | | this.extend = extend; |
| | | } |
| | | |
| | | public String getUid() { |
| | | return uid; |
| | | } |
| | | |
| | | public void setUid(String uid) { |
| | | this.uid = uid; |
| | | } |
| | | |
| | | } |