1 Star 0 Fork 0

Sin/rpcinterface

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
sms.go 1.24 KB
一键复制 编辑 原始数据 按行查看 历史
编号9527 提交于 2020-04-27 15:59 . 短信
package public
import (
"context"
"git.900sui.cn/kc/rpcinterface/client"
"git.900sui.cn/kc/rpcinterface/interface/public"
)
//注意:此服务只能任务服务调用
type Sms struct {
client.Baseclient
}
func (s *Sms) Init() *Sms {
s.ServiceName = "rpc_public"
s.ServicePath = "Sms"
return s
}
//添加短信验证码任务到mq队列
func ( s *Sms ) SendCaptcha2Mq( ctx context.Context, args *public.SendCaptchaParams, reply *bool ) error {
return s.Call( ctx, "SendCaptcha2Mq", args, reply )
}
//发送短信验证码,供MQ消费者调用
func ( s *Sms ) SendCaptcha( ctx context.Context, args *public.SendCaptchaParams, reply *bool ) error {
return s.Call( ctx, "SendCaptcha", args, reply )
}
//验证短信验证码
func ( s *Sms ) CheckCaptcha( ctx context.Context, args *public.CheckCaptchaParams, reply *bool ) error {
return s.Call( ctx, "CheckCaptcha", args, reply )
}
//添加短信任务到MQ队列
func ( s *Sms ) SendSms2Mq( ctx context.Context, args *public.SendSmsParams, reply *bool ) error {
return s.Call( ctx, "SendSms2Mq", args, reply )
}
//发送短信,供MQ消费者调用
func ( s *Sms ) SendSms( ctx context.Context, args *public.SendSmsParams, reply *bool ) error {
return s.Call( ctx, "SendSms", args, reply )
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/shijun123456/rpcinterface.git
git@gitee.com:shijun123456/rpcinterface.git
shijun123456
rpcinterface
rpcinterface
7a7348490b61

搜索帮助

23e8dbc6 1850385 7e0993f3 1850385