Explorar el Código

Merge remote-tracking branch 'origin/yb/1.1'

Roc hace 3 años
padre
commit
aa0e89a7e4
Se han modificado 2 ficheros con 5 adiciones y 5 borrados
  1. 1 1
      logic/user/user.go
  2. 4 4
      services/sms.go

+ 1 - 1
logic/user/user.go

@@ -46,7 +46,7 @@ func SendSmsCode(openid, mobile, areaNum string) (err error, errMsg string) {
 		}
 		err = item.Create()
 	} else {
-		err = errors.New("发送失败,Err:" + err.Error())
+		err = errors.New("短信发送失败")
 	}
 	return
 }

+ 4 - 4
services/sms.go

@@ -10,10 +10,10 @@ import (
 )
 
 // SendSmsCode 发送国内短信
-func SendSmsCode(mobile, vcode string) bool {
+func SendSmsCode(mobile, vCode string) bool {
 	flag := false
 	tplId := "65692"
-	result, err := sendSms(mobile, tplId, vcode)
+	result, err := sendSms(mobile, tplId, vCode)
 	if err != nil {
 		fmt.Println("发送短信失败")
 		return false
@@ -64,9 +64,9 @@ func sendSms(mobile, tplId, code string) (rs []byte, err error) {
 }
 
 // SendSmsCodeGj 发送国际短信
-func SendSmsCodeGj(mobile, vcode, areaNum string) bool {
+func SendSmsCodeGj(mobile, vCode, areaNum string) bool {
 	flag := false
-	result, err := sendSmsGj(mobile, vcode, areaNum)
+	result, err := sendSmsGj(mobile, vCode, areaNum)
 	if err != nil {
 		fmt.Println("发送短信失败")
 		return false