123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- package auth
- import (
- "bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/medical"
- "context"
- "bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
- "bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/types"
- "github.com/zeromicro/go-zero/core/logx"
- )
- type UserAuthInfoSaveLogic struct {
- logx.Logger
- ctx context.Context
- svcCtx *svc.ServiceContext
- }
- func NewUserAuthInfoSaveLogic(ctx context.Context, svcCtx *svc.ServiceContext) *UserAuthInfoSaveLogic {
- return &UserAuthInfoSaveLogic{
- Logger: logx.WithContext(ctx),
- ctx: ctx,
- svcCtx: svcCtx,
- }
- }
- func (l *UserAuthInfoSaveLogic) UserAuthInfoSave(req *types.UserInfoReq) (*types.CommonRes, error) {
- // todo: add your logic here and delete this line
- resp, err := l.svcCtx.Medical.UserAuthInfoSave(l.ctx, &medical.UserInfo{
- UserId: req.NewUserId,
- Appid: req.AppId,
- Name: req.Name,
- Phone: req.Phone,
- Mail: req.Mail,
- Position: req.Position,
- Department: req.Department,
- EntName: req.EntName,
- OperationType: req.OperationType,
- })
- if err != nil {
- return nil, err
- }
- return &types.CommonRes{
- Error_msg: resp.ErrorMsg,
- Error_code: int(resp.ErrorCode),
- Data: resp.Data,
- }, nil
- }
|