26 lines
451 B
Go
26 lines
451 B
Go
package request
|
|
|
|
import "errors"
|
|
|
|
// 获取本机手机号
|
|
type GetLocalMobileRequest struct {
|
|
YiDunAccessToken string
|
|
YiDunToken string
|
|
}
|
|
|
|
// 参数合法性检验
|
|
func (request *GetLocalMobileRequest) CheckParameter() (err error) {
|
|
|
|
if len(request.YiDunAccessToken) == 0 {
|
|
err = errors.New("YiDunAccessToken不能为空")
|
|
return
|
|
}
|
|
|
|
if len(request.YiDunToken) == 0 {
|
|
err = errors.New("YiDunToken不能为空")
|
|
return
|
|
}
|
|
|
|
return
|
|
}
|