func (r *GormWorkItemLinkTypeRepository) Load(ctx context.Context, spaceID uuid.UUID, ID uuid.UUID) (*WorkItemLinkType, error) {
	log.Info(ctx, map[string]interface{}{
		"wilt_id":  ID,
		"space_id": spaceID,
	}, "Loading work item link type")
	modelLinkType := WorkItemLinkType{}
	db := r.db.Model(&modelLinkType).Where("id=? AND space_id=?", ID, spaceID.String()).First(&modelLinkType)
	if db.RecordNotFound() {
		log.Error(ctx, map[string]interface{}{
			"wilt_id": ID,
		}, "work item link type not found")
		return nil, errors.NewNotFoundError("work item link type", ID.String())
	}
	if db.Error != nil {
		return nil, errors.NewInternalError(db.Error.Error())
	}
	return &modelLinkType, nil
}
// Load returns the work item link type for the given spaceID and ID.
// Returns NotFoundError, ConversionError or InternalError
Load returns the work item link type for the given spaceID and ID.
Returns NotFoundError, ConversionError or InternalError
// Load returns the work item link type for the given spaceID and ID . // Returns NotFoundError ConversionError or InternalError
func (r *GormWorkItemLinkTypeRepository) Load(ctx context.Context, spaceID uuid.UUID, ID uuid.UUID) (*WorkItemLinkType, error) {
	log.Info(ctx, map[string]interface{}{
		"wilt_id":  ID,
		"space_id": spaceID,
	}, "Loading work item link type")
	modelLinkType := WorkItemLinkType{}
	db := r.db.Model(&modelLinkType).Where("id=? AND space_id=?", ID, spaceID.String()).First(&modelLinkType)
	if db.RecordNotFound() {
		log.Error(ctx, map[string]interface{}{
			"wilt_id": ID,
		}, "work item link type not found")
		return nil, errors.NewNotFoundError("work item link type", ID.String())
	}
	if db.Error != nil {
		return nil, errors.NewInternalError(db.Error.Error())
	}
	return &modelLinkType, nil
}
func ( r * GormWorkItemLinkTypeRepository ) Load ( ctx context . Context , spaceID uuid . UUID , ID uuid . UUID ) ( * WorkItemLinkType , error ) { log . Info ( ctx , map [ string ] interface { } { " " : ID , " " : spaceID , } , " " ) modelLinkType := WorkItemLinkType { } db := r . db . Model ( & modelLinkType ) . Where ( " " , ID , spaceID . String ( ) ) . First ( & modelLinkType ) if db . RecordNotFound ( ) { log . Error ( ctx , map [ string ] interface { } { " " : ID , } , " " ) return nil , errors . NewNotFoundError ( " " , ID . String ( ) ) } if db . Error != nil { return nil , errors . NewInternalError ( db . Error . Error ( ) ) } return & modelLinkType , nil }
Load returns the work item link type for the given spaceID and ID.
Load returns the work item link type for the given spaceID and ID .