signup
This commit is contained in:
parent
a7ea0ee3c3
commit
6b891496b1
|
@ -6,11 +6,25 @@ import (
|
|||
"git.loafle.net/overflow/overflow_server_app/server"
|
||||
|
||||
"github.com/valyala/fasthttp"
|
||||
"git.loafle.net/overflow/overflow_server_app/backend"
|
||||
)
|
||||
|
||||
func CheckEmail(sctx *server.ServerContext, ctx *fasthttp.RequestCtx) {
|
||||
msg := sctx.Value("key1")
|
||||
//msg := sctx.Value("key1")
|
||||
|
||||
fmt.Fprintf(ctx, "Welcome!!!!: %s \n", msg)
|
||||
grpcPool := sctx.Value("grpc").(backend.Pool)
|
||||
c, err := grpcPool.Get()
|
||||
if nil != err {
|
||||
|
||||
}
|
||||
defer c.Close()
|
||||
|
||||
fmt.Fprintf(ctx, "avail: %d\n", grpcPool.Available())
|
||||
|
||||
signinId := string(ctx.FormValue("signinId"))
|
||||
params := []string{signinId}
|
||||
|
||||
r, err := c.Exec("MemberService", "read", params)
|
||||
|
||||
fmt.Fprintf(ctx, "Welcome!!!!: %s \n", r)
|
||||
}
|
||||
|
|
28
module/member/confirm_pw.go
Normal file
28
module/member/confirm_pw.go
Normal file
|
@ -0,0 +1,28 @@
|
|||
package member
|
||||
|
||||
import (
|
||||
"github.com/valyala/fasthttp"
|
||||
"git.loafle.net/overflow/overflow_server_app/server"
|
||||
"git.loafle.net/overflow/overflow_server_app/backend"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
func ConfirmPW(sctx *server.ServerContext, ctx *fasthttp.RequestCtx) {
|
||||
grpcPool := sctx.Value("grpc").(backend.Pool)
|
||||
c, err := grpcPool.Get()
|
||||
if nil != err {
|
||||
|
||||
}
|
||||
defer c.Close()
|
||||
|
||||
fmt.Fprintf(ctx, "avail: %d\n", grpcPool.Available())
|
||||
|
||||
signinId := string(ctx.FormValue("signinId"))
|
||||
signinPw := string(ctx.FormValue("signinPw"))
|
||||
|
||||
params := []string{signinId, signinPw}
|
||||
|
||||
r, err := c.Exec("MemberService", "confirmPw", params)
|
||||
|
||||
fmt.Fprintf(ctx, "Confirm PW !!!!: %s\n", r)
|
||||
}
|
|
@ -6,11 +6,29 @@ import (
|
|||
"git.loafle.net/overflow/overflow_server_app/server"
|
||||
|
||||
"github.com/valyala/fasthttp"
|
||||
"git.loafle.net/overflow/overflow_server_app/backend"
|
||||
)
|
||||
|
||||
func ForgotPassword(sctx *server.ServerContext, ctx *fasthttp.RequestCtx) {
|
||||
msg := sctx.Value("key1")
|
||||
//msg := sctx.Value("key1")
|
||||
//
|
||||
//fmt.Fprintf(ctx, "Welcome!!!!: %s \n", msg)
|
||||
|
||||
fmt.Fprintf(ctx, "Welcome!!!!: %s \n", msg)
|
||||
grpcPool := sctx.Value("grpc").(backend.Pool)
|
||||
c, err := grpcPool.Get()
|
||||
if nil != err {
|
||||
|
||||
}
|
||||
defer c.Close()
|
||||
|
||||
fmt.Fprintf(ctx, "avail: %d\n", grpcPool.Available())
|
||||
|
||||
signinId := string(ctx.FormValue("signinId"))
|
||||
signinPw := string(ctx.FormValue("signinPw"))
|
||||
|
||||
params := []string{signinId, signinPw}
|
||||
|
||||
r, err := c.Exec("MemberService", "forgotPassword", params)
|
||||
|
||||
fmt.Fprintf(ctx, "Password Change!!!!: %s\n", r)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user