service

package
v0.0.0-...-0cac348 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 23, 2020 License: AGPL-3.0 Imports: 47 Imported by: 0

Documentation

Overview

* 2 * @Author: Nico 3 * @Date: 2020/1/31 11:20 4

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Auth

func Auth(input vo.AuthReq) (*vo.AuthResp, errs.SystemErrorInfo)

func AuthOrgRole

func AuthOrgRole(orgId, userId int64, path string, operation string) errs.SystemErrorInfo

func BatchGetUserDetailInfo

func BatchGetUserDetailInfo(userIds []int64) ([]vo.PersonalInfo, errs.SystemErrorInfo)

func CreateOrg

func CreateOrg(req orgvo.CreateOrgReqVo, sourceChannel, sourcePlatform string) (int64, errs.SystemErrorInfo)

func CreateOrgRelationResource

func CreateOrgRelationResource(orgId int64, creatorId int64, sourceChannel, sourcePlatform string, orgName string) errs.SystemErrorInfo

func Departments

func Departments(page uint, size uint, params *vo.DepartmentListReq, orgId int64) (*vo.DepartmentList, errs.SystemErrorInfo)

func GeneralInitOrg

func GeneralInitOrg(initOrgBo bo.InitOrgBo, tx sqlbuilder.Tx) (int64, errs.SystemErrorInfo)

func GetBaseOrgInfo

func GetBaseOrgInfo(sourceChannel string, orgId int64) (*bo.BaseOrgInfoBo, errs.SystemErrorInfo)

func GetBaseOrgInfoByOutOrgId

func GetBaseOrgInfoByOutOrgId(sourceChannel string, outOrgId string) (*bo.BaseOrgInfoBo, errs.SystemErrorInfo)

func GetBaseUserInfo

func GetBaseUserInfo(sourceChannel string, orgId int64, userId int64) (*bo.BaseUserInfoBo, errs.SystemErrorInfo)

func GetBaseUserInfoBatch

func GetBaseUserInfoBatch(sourceChannel string, orgId int64, userIds []int64) ([]bo.BaseUserInfoBo, errs.SystemErrorInfo)

func GetBaseUserInfoByEmpId

func GetBaseUserInfoByEmpId(sourceChannel string, orgId int64, empId string) (*bo.BaseUserInfoBo, errs.SystemErrorInfo)

func GetCtxParameters

func GetCtxParameters(ctx context.Context, key string) (string, error)

func GetCurrentUserWithCond

func GetCurrentUserWithCond(ctx context.Context, orgVerify bool) (*bo.CacheUserInfoBo, errs.SystemErrorInfo)

func GetCurrentUserWithoutOrgVerify

func GetCurrentUserWithoutOrgVerify(ctx context.Context) (*bo.CacheUserInfoBo, errs.SystemErrorInfo)

func GetDingTalkBaseUserInfo

func GetDingTalkBaseUserInfo(orgId int64, userId int64) (*bo.BaseUserInfoBo, errs.SystemErrorInfo)

func GetDingTalkBaseUserInfoByEmpId

func GetDingTalkBaseUserInfoByEmpId(orgId int64, empId string) (*bo.BaseUserInfoBo, errs.SystemErrorInfo)

func GetFsAccessToken

func GetFsAccessToken(orgId, userId int64) (string, errs.SystemErrorInfo)

func GetInviteCode

func GetInviteCode(currentUserId int64, orgId int64, sourcePlatform string) (*orgvo.GetInviteCodeRespVoData, errs.SystemErrorInfo)

func GetInviteInfo

func GetInviteInfo(inviteCode string) (*vo.GetInviteInfoResp, errs.SystemErrorInfo)

func GetJsAPISign

func GetJsAPISign(input vo.JsAPISignReq) (*vo.JsAPISignResp, errs.SystemErrorInfo)

func GetOrgBoList

func GetOrgBoList() ([]bo.OrganizationBo, errs.SystemErrorInfo)

func GetOrgIdListBySourceChannel

func GetOrgIdListBySourceChannel(sourceChannel string, page int, size int) ([]int64, errs.SystemErrorInfo)

通过来源获取组织id列表

func GetOutUserInfoListBySourceChannel

func GetOutUserInfoListBySourceChannel(sourceChannel string, page int, size int) ([]bo.UserOutInfoBo, errs.SystemErrorInfo)

func GetUserConfigInfo

func GetUserConfigInfo(orgId int64, userId int64) (*bo.UserConfigBo, errs.SystemErrorInfo)

func GetUserId

func GetUserId(orgId int64, corpId, sourceChannel, empId string) (*vo.UserIDInfo, errs.SystemErrorInfo)

func GetUserIds

func GetUserIds(orgId int64, corpId, sourceChannel string, empIds []string) ([]*vo.UserIDInfo, errs.SystemErrorInfo)

func GetUserInfo

func GetUserInfo(orgId int64, userId int64, sourceChannel string) (*bo.UserInfoBo, errs.SystemErrorInfo)

func GetUserInfoListByOrg

func GetUserInfoListByOrg(orgId int64) ([]bo.SimpleUserInfoBo, errs.SystemErrorInfo)

func GinContextFromContext

func GinContextFromContext(ctx context.Context) (*gin.Context, error)

func InitDepartment

func InitDepartment(orgId int64, corpId string, sourceChannel string, tx sqlbuilder.Tx) errs.SystemErrorInfo

func InitOrg

func InitOrg(initOrgBo bo.InitOrgBo, tx sqlbuilder.Tx) (int64, errs.SystemErrorInfo)

func IsInWhiteList

func IsInWhiteList(phoneNumber string) bool

func JudgeUserIsAdmin

func JudgeUserIsAdmin(outOrgId string, outUserId string, sourceChannel string) bool

func LarkInit

func LarkInit(orgId, userId int64, sourceChannel string, sourcePlatform string) errs.SystemErrorInfo

初始化lark通用数据

func NeedUpdate

func NeedUpdate(updateFields []string, field string) bool

func OrgInit

func OrgInit(corpId string, permanentCode string, tx sqlbuilder.Tx) (int64, errs.SystemErrorInfo)

func OrgOwnerInit

func OrgOwnerInit(orgId int64, owner int64, tx sqlbuilder.Tx) errs.SystemErrorInfo

func OrgSysConfigInit

func OrgSysConfigInit(tx sqlbuilder.Tx, orgId int64) errs.SystemErrorInfo

func OrgUserList

func OrgUserList(orgId, userId int64, page, size int, input *vo.OrgUserListReq) (*vo.UserOrganizationList, errs.SystemErrorInfo)

func OrganizationInfo

获取组织信息

func PersonalInfo

func PersonalInfo(orgId, userId int64, sourceChannel string) (*vo.PersonalInfo, errs.SystemErrorInfo)

func RemoveOrgMember

func RemoveOrgMember(reqVo orgvo.RemoveOrgMemberReq) (*vo.Void, errs.SystemErrorInfo)

func SendSMSLoginCode

func SendSMSLoginCode(phoneNumber string) errs.SystemErrorInfo

func SwitchUserOrganization

func SwitchUserOrganization(orgId, userId int64, token string) errs.SystemErrorInfo

func TeamInit

func TeamInit(orgId int64, tx sqlbuilder.Tx) (int64, errs.SystemErrorInfo)

func TeamOwnerInit

func TeamOwnerInit(teamId int64, owner int64, tx sqlbuilder.Tx) errs.SystemErrorInfo

func TeamUserInit

func TeamUserInit(orgId int64, teamId int64, userId int64, isRoot bool, tx sqlbuilder.Tx) errs.SystemErrorInfo

func UpdateCacheUserInfoOrgId

func UpdateCacheUserInfoOrgId(token string, orgId int64) errs.SystemErrorInfo

func UpdateOrgMemberCheckStatus

func UpdateOrgMemberCheckStatus(reqVo orgvo.UpdateOrgMemberCheckStatusReq) (*vo.Void, errs.SystemErrorInfo)

更新成员检查状态

func UpdateOrgMemberStatus

func UpdateOrgMemberStatus(reqVo orgvo.UpdateOrgMemberStatusReq) (*vo.Void, errs.SystemErrorInfo)

更新成员状态

func UpdateOrganizationSetting

func UpdateOrganizationSetting(req orgvo.UpdateOrganizationSettingReqVo) (int64, errs.SystemErrorInfo)

对于自己创建的组织,暂时不支持转让

对于加入的企业只有查看全,无操作权

暂时只做基本设置

func UpdateUserConfig

func UpdateUserConfig(orgId, userId int64, input vo.UpdateUserConfigReq) (*vo.UpdateUserConfigResp, errs.SystemErrorInfo)

func UpdateUserDefaultProjectIdConfig

func UpdateUserDefaultProjectIdConfig(orgId, userId int64, input vo.UpdateUserDefaultProjectConfigReq) (*vo.UpdateUserConfigResp, errs.SystemErrorInfo)

func UpdateUserInfo

func UpdateUserInfo(orgId, userId int64, input vo.UpdateUserInfoReq) (*vo.Void, errs.SystemErrorInfo)

func UpdateUserPcConfig

func UpdateUserPcConfig(orgId, userId int64, input vo.UpdateUserPcConfigReq) (*vo.UpdateUserConfigResp, errs.SystemErrorInfo)

func UserAlreadyRegisterHandleHook

func UserAlreadyRegisterHandleHook(req vo.UserLoginReq, userBo bo.UserInfoBo) errs.SystemErrorInfo

func UserAuthCodeLogin

func UserAuthCodeLogin(req vo.UserLoginReq) (*bo.UserInfoBo, errs.SystemErrorInfo)

func UserConfigInfo

func UserConfigInfo(orgId, userId int64) (*vo.UserConfig, errs.SystemErrorInfo)

func UserInitByOrg

func UserInitByOrg(userId string, corpId string, orgId int64, tx sqlbuilder.Tx) (int64, errs.SystemErrorInfo)

func UserOrganizationList

func UserOrganizationList(userId int64) (*vo.UserOrganizationListResp, errs.SystemErrorInfo)

func UserPwdLogin

func UserPwdLogin(req vo.UserLoginReq) (*bo.UserInfoBo, errs.SystemErrorInfo)

用户密码登录

func UserQuit

用户退出

func VerifyCaptcha

func VerifyCaptcha(captchaID, captchaPassword *string, phoneNumber string) errs.SystemErrorInfo

func VerifyOrg

func VerifyOrg(orgId int64, userId int64) bool

func VerifyOrgUsers

func VerifyOrgUsers(orgId int64, userIds []int64) bool

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL