|
|
@@ -87,6 +87,56 @@ func (a Api) SignOut(ctx context.Context, q *pb.DefaultRequest) (*pb.DefaultRepl
|
|
|
|
|
|
// ----------------------- 商家信息管理 ---------------------------------------------
|
|
|
|
|
|
+// AcrossUserSimpleQuery 可跨店会员简单查询
|
|
|
+func (a Api) AcrossUserSimpleQuery(ctx context.Context, r *pb.StandardRequest) (*pb.StandardReply, error) {
|
|
|
+ // 获取token,并验证签名函数
|
|
|
+ token, q, sign := a.webToGoVerify(ctx, r)
|
|
|
+ rs := service.User{}.AcrossUserSimpleQuery(token, q.ShopID, q.JsonStr, sign)
|
|
|
+
|
|
|
+ rst := a.toWebFunc(rs)
|
|
|
+ return rst, nil
|
|
|
+}
|
|
|
+
|
|
|
+// VipUserSimpleQuery 会员简单查询
|
|
|
+func (a Api) VipUserSimpleQuery(ctx context.Context, r *pb.StandardRequest) (*pb.StandardReply, error) {
|
|
|
+ // 获取token,并验证签名函数
|
|
|
+ token, q, sign := a.webToGoVerify(ctx, r)
|
|
|
+ rs := service.User{}.AcrossUserSimpleQuery(token, q.ShopID, q.JsonStr, sign)
|
|
|
+ rst := a.toWebFunc(rs)
|
|
|
+ return rst, nil
|
|
|
+}
|
|
|
+
|
|
|
+// TempVipUserSimpleQuery 临时会员简单查询
|
|
|
+func (a Api) TempVipUserSimpleQuery(ctx context.Context, r *pb.StandardRequest) (*pb.StandardReply, error) {
|
|
|
+ // 获取token,并验证签名函数
|
|
|
+ token, q, sign := a.webToGoVerify(ctx, r)
|
|
|
+ rs := service.User{}.TempVipUserSimpleQuery(token, q.ShopID, q.JsonStr, sign)
|
|
|
+ rst := a.toWebFunc(rs)
|
|
|
+ return rst, nil
|
|
|
+}
|
|
|
+
|
|
|
+// ClassSimpleQuery 课目简单查询
|
|
|
+func (a Api) ClassSimpleQuery(ctx context.Context, r *pb.StandardRequest) (*pb.StandardReply, error) {
|
|
|
+ // 获取token,并验证签名函数
|
|
|
+ token, q, sign := a.webToGoVerify(ctx, r)
|
|
|
+
|
|
|
+ rs := service.Class{}.ClassSimpleQuery(token, q.ShopID, q.JsonStr, sign)
|
|
|
+ rst := a.toWebFunc(rs)
|
|
|
+ return rst, nil
|
|
|
+}
|
|
|
+
|
|
|
+// SelectHrSensors 心率带简单查询
|
|
|
+func (a Api) SelectHrSensors(ctx context.Context, r *pb.StandardRequest) (*pb.StandardReply, error) {
|
|
|
+ // 获取token,并验证签名函数
|
|
|
+ token, q, sign := a.webToGoVerify(ctx, r)
|
|
|
+
|
|
|
+ rs := service.Hr{}.SelectHrSensors(token, q.ShopID, q.JsonStr, sign)
|
|
|
+ rst := a.toWebFunc(rs)
|
|
|
+ return rst, nil
|
|
|
+}
|
|
|
+
|
|
|
+// ----------------------- 商家信息管理 ---------------------------------------------
|
|
|
+
|
|
|
func (a Api) ManageableShopList(ctx context.Context, r *pb.ShopListRequest) (*pb.ShopListReply, error) {
|
|
|
token := a.getToken(ctx)
|
|
|
|
|
|
@@ -944,10 +994,10 @@ func (a Api) UnBindHrSensor(ctx context.Context, r *pb.StandardRequest) (*pb.Sta
|
|
|
|
|
|
// ----------------------- 微信管理 ---------------------------------------------
|
|
|
|
|
|
-// GenVerifyImageByWinXin 微信登陆获取图片验证码
|
|
|
-func (Api) GenVerifyImageByWinXin(ctx context.Context, q *pb.GenVerifyImageRequest) (*pb.GenVerifyImageReply, error) {
|
|
|
- height := int(q.Height)
|
|
|
- width := int(q.Width)
|
|
|
+// GenVerifyImageByWeiXin 微信登陆获取图片验证码
|
|
|
+func (Api) GenVerifyImageByWeiXin(ctx context.Context, r *pb.GenVerifyImageRequest) (*pb.GenVerifyImageReply, error) {
|
|
|
+ height := int(r.Height)
|
|
|
+ width := int(r.Width)
|
|
|
|
|
|
id, pic := service.VerifyCode{}.GenImage(height, width)
|
|
|
|
|
|
@@ -957,6 +1007,15 @@ func (Api) GenVerifyImageByWinXin(ctx context.Context, q *pb.GenVerifyImageReque
|
|
|
}, nil
|
|
|
}
|
|
|
|
|
|
+// GenPhoneVerifyCodeByWeiXin 微信登陆获取短信验证码
|
|
|
+func (a Api) GenPhoneVerifyCodeByWeiXin(ctx context.Context, r *pb.GenPhoneVerifyCodeRequest) (*pb.DefaultReply, error) {
|
|
|
+ //service.VerifyCode{}.GetPhoneVFCode(
|
|
|
+ // a.getSysToken(ctx),
|
|
|
+ // in.Account, in.Ip, in.Code, in.TemplateCode, in.VerifyType, time.Duration(in.ExpireDurationNano))
|
|
|
+
|
|
|
+ return &pb.DefaultReply{}, nil
|
|
|
+}
|
|
|
+
|
|
|
// VipUserWeiXinLogin 微信登陆
|
|
|
func (a Api) VipUserWeiXinLogin(ctx context.Context, r *pb.StandardRequest) (*pb.StandardReply, error) {
|
|
|
// 获取token,并验证签名函数
|