12345678910111213141516171819202122 |
- package service
- import (
- "demo/api/v1/common"
- )
- type AuthService struct{}
- func NewAuthService() *AuthService {
- return &AuthService{}
- }
- func (as *AuthService) Login(req *common.LoginReq) *common.LoginRes {
- // 假设成功返回
- return &common.LoginRes{
- Message: "Login successful",
- Data: map[string]interface{}{
- "email": req.Email,
- "password": req.Password,
- },
- }
- }
|