person

package
v0.0.0-...-345574f Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const ProfileNotFound = "profile_not_found"

ProfileNotFound Error Code

Variables

This section is empty.

Functions

This section is empty.

Types

type Controller

type Controller interface {
	PostProfile(ginCtx *gin.Context)
	PutProfile(ginCtx *gin.Context)
	GetProfile(ginCtx *gin.Context)
}

Controller interface

func NewController

func NewController(exec boil.ContextExecutor) Controller

NewController for person repository

type Person

type Person struct {
	ID             string  `json:"id"`
	FirstName      string  `json:"first_name"`
	LastName       string  `json:"last_name"`
	Headline       string  `json:"headline"`
	Company        string  `json:"company"`
	CompanyWebsite string  `json:"website"`
	AvatarURL      string  `json:"avatar_url"`
	Email          string  `json:"email"`
	ProfileType    string  `json:"profile_type"`
	Profile        Profile `json:"profiles,omitempty"`
	Status         string  `json:"status"`
}

Person struct

type Profile

type Profile struct {
	LinkedIn string `json:"linkedin"`
}

Profile struct

type ProfileParams

type ProfileParams struct {
	FirstName      string `json:"first_name"`
	LastName       string `json:"last_name"`
	Headline       string `json:"headline"`
	Company        string `json:"company"`
	CompanyWebsite string `json:"website"`
	AvatarURL      string `json:"avatar_url"`
	Email          string `json:"email"`
	ProfileType    string `json:"profile_type"`
}

ProfileParams struct

type ProfileStatus

type ProfileStatus string

ProfileStatus enum

const (
	Complete   ProfileStatus = "Complete"
	Incomplete ProfileStatus = "Incomplete"
)

ProfileStatus enum constants

func (ProfileStatus) String

func (h ProfileStatus) String() string

type ProfileType

type ProfileType string

ProfileType enum

const (
	Recruiter ProfileType = "Recruiter"
	Seeker    ProfileType = "Seeker"
)

ProfileType enum constants

func (ProfileType) String

func (h ProfileType) String() string

type Repository

type Repository interface {
	GetProfile(ctx context.Context, iamID string) (*models.Person, error)
	CreateProfile(ctx context.Context, iamID string, params ProfileParams) (*models.Person, error)
	EditProfile(ctx context.Context, iamID string, params ProfileParams) (*models.Person, error)
}

Repository interface for person

type Service

type Service interface {
	GetProfile(ctx context.Context, iamID string) (Person, error)
	CreateProfile(ctx context.Context, iamID string, params ProfileParams) (Person, error)
	EditProfile(ctx context.Context, iamID string, params ProfileParams) (Person, error)
}

Service is used to facilitate all otp related activities for any request

Jump to

Keyboard shortcuts

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