123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- package logic
- import (
- "app.yhyue.com/moapp/jybase/common"
- "bp.jydev.jianyu360.cn/BaseService/jyMicroservices/jyBXCore/rpc/type/bxcore"
- "context"
- "net/http"
- "bp.jydev.jianyu360.cn/BaseService/jyMicroservices/jyBXCore/api/internal/svc"
- "bp.jydev.jianyu360.cn/BaseService/jyMicroservices/jyBXCore/api/internal/types"
- "github.com/zeromicro/go-zero/core/logx"
- )
- type ParticipatePersonsLogic struct {
- logx.Logger
- ctx context.Context
- svcCtx *svc.ServiceContext
- r *http.Request
- }
- func NewParticipatePersonsLogic(ctx context.Context, svcCtx *svc.ServiceContext, r *http.Request) *ParticipatePersonsLogic {
- return &ParticipatePersonsLogic{
- Logger: logx.WithContext(ctx),
- ctx: ctx,
- svcCtx: svcCtx,
- r: r,
- }
- }
- func (l *ParticipatePersonsLogic) ParticipatePersons(req *types.ParticipatePersonsReq) (resp *types.CommonResp, err error) {
- defer common.Catch()
- res, err := l.svcCtx.BxCore.ParticipatePersons(l.ctx, &bxcore.ParticipatePersonsReq{
- EntId: req.EntId,
- EntUserId: req.EntUserId,
- PositionId: req.PositionId,
- PositionType: req.PositionType,
- MgoUserId: req.MgoUserId,
- AppId: req.AppId,
- UserId: req.UserId,
- NewUserId: req.NewUserId,
- AccountId: req.AccountId,
- ProjectId: req.ProjectId, //项目信息id 移动需要
- EntAccountId: req.EntAccountId,
- Phone: req.Phone,
- })
- if err != nil {
- return &types.CommonResp{
- Err_code: -1,
- Err_msg: "查询失败",
- Data: map[string]interface{}{},
- }, nil
- }
- return &types.CommonResp{
- Err_code: res.ErrCode,
- Err_msg: res.ErrMsg,
- Data: res.Data,
- }, nil
- return
- }
|