AlbumRepositoryInterface
extends
HasSponsor, HasFeature, MediaAlbumRepositoryInterface, HasSponsorInFeed
in
Interface Album.
Tags
Table of Contents
Methods
- approve() : Content
- createAlbum() : Album
- deleteAlbum() : mixed
- disableSponsor() : void
- enableSponsor() : void
- feature() : bool
- findFeature() : Paginator
- findSponsor() : Paginator
- getAlbumById() : Album|null
- getAlbumsForForm() : array<int, mixed>
- getDefaultUserAlbums() : Collection
- getRandomSponsoredItems() : Collection
- getSponsoredItem() : Content
- isDefaultUserAlbum() : bool
- isFeature() : bool
- isFeedSponsored() : bool
- isPending() : bool
- isSponsor() : bool
- model() : string
- removeAvatarFromAlbum() : void
- removeCoverFromAlbum() : void
- sponsor() : bool
- sponsorInFeed() : bool
- unsponsor() : bool
- unsponsorInFeed() : bool
- updateAlbum() : Album
- updateAlbumCover() : void
- uploadMedias() : array<string|int, mixed>
- viewAlbum() : mixed
- viewAlbumItems() : Paginator
- viewAlbums() : Paginator
Methods
approve()
public
approve(User $context, int $id) : Content
Parameters
- $context : User
- $id : int
Tags
Return values
ContentcreateAlbum()
public
createAlbum(User $context, User $owner, array<string, mixed> $attributes) : Album
Parameters
Tags
Return values
AlbumdeleteAlbum()
public
deleteAlbum(User $context, int $id) : mixed
Parameters
- $context : User
- $id : int
Tags
disableSponsor()
public
disableSponsor(Content $content) : void
Parameters
- $content : Content
enableSponsor()
public
enableSponsor(Content $content) : void
Parameters
- $content : Content
feature()
public
feature(User $context, int $id, int $feature) : bool
Parameters
- $context : User
- $id : int
- $feature : int
Tags
Return values
boolfindFeature()
public
findFeature([int $limit = 4 ]) : Paginator
Parameters
- $limit : int = 4
Return values
PaginatorfindSponsor()
public
findSponsor([int $limit = 4 ]) : Paginator
Parameters
- $limit : int = 4
Return values
PaginatorgetAlbumById()
public
getAlbumById(int $id) : Album|null
Parameters
- $id : int
Return values
Album|nullgetAlbumsForForm()
public
getAlbumsForForm(User $context, User $owner) : array<int, mixed>
Parameters
Return values
array<int, mixed>getDefaultUserAlbums()
public
getDefaultUserAlbums(int $ownerId[, array<string|int, mixed> $types = [] ]) : Collection
Parameters
- $ownerId : int
- $types : array<string|int, mixed> = []
Return values
CollectiongetRandomSponsoredItems()
public
getRandomSponsoredItems(User $context, int $limit[, array<string|int, mixed>|null $loadedItemIds = null ]) : Collection
Parameters
- $context : User
- $limit : int
- $loadedItemIds : array<string|int, mixed>|null = null
Return values
CollectiongetSponsoredItem()
public
getSponsoredItem(array<string|int, int> $notInIds[, int|null $sponsorStart = null ][, array<string|int, mixed> $with = [] ]) : Content
Parameters
- $notInIds : array<string|int, int>
- $sponsorStart : int|null = null
- $with : array<string|int, mixed> = []
Return values
Content —| null
isDefaultUserAlbum()
public
isDefaultUserAlbum(int $id[, int $ownerId = 0 ]) : bool
Parameters
- $id : int
- $ownerId : int = 0
Return values
boolisFeature()
public
isFeature(Content $model) : bool
Parameters
- $model : Content
Return values
boolisFeedSponsored()
public
isFeedSponsored(Content $model) : bool
Parameters
- $model : Content
Return values
boolisPending()
public
isPending(Content $model) : bool
Parameters
- $model : Content
Return values
boolisSponsor()
public
isSponsor(Content $model) : bool
Parameters
- $model : Content
Return values
boolmodel()
public
model() : string
Return values
stringremoveAvatarFromAlbum()
public
removeAvatarFromAlbum(Album $album, Photo $photo) : void
Parameters
removeCoverFromAlbum()
public
removeCoverFromAlbum(Album $album, Photo $photo) : void
Parameters
sponsor()
public
sponsor(User $context, int $id, int $sponsor) : bool
Parameters
- $context : User
- $id : int
- $sponsor : int
Tags
Return values
boolsponsorInFeed()
public
sponsorInFeed(User $context, int $id, int $newValue) : bool
Parameters
- $context : User
- $id : int
- $newValue : int
Tags
Return values
boolunsponsor()
public
unsponsor(User $context, int $id) : bool
Parameters
- $context : User
- $id : int
Return values
boolunsponsorInFeed()
public
unsponsorInFeed(User $context, int $id) : bool
Parameters
- $context : User
- $id : int
Return values
boolupdateAlbum()
public
updateAlbum(User $context, int $id, array<string, mixed> $attributes) : Album
Parameters
- $context : User
- $id : int
- $attributes : array<string, mixed>
Tags
Return values
AlbumupdateAlbumCover()
public
updateAlbumCover(Album $album[, int $photoId = 0 ]) : void
Parameters
- $album : Album
- $photoId : int = 0
uploadMedias()
public
uploadMedias(User $context, int $id, array<string|int, mixed> $attributes) : array<string|int, mixed>
Parameters
- $context : User
- $id : int
- $attributes : array<string|int, mixed>
Return values
array<string|int, mixed>viewAlbum()
public
viewAlbum(User $context, int $id) : mixed
Parameters
- $context : User
- $id : int
Tags
viewAlbumItems()
public
viewAlbumItems(User $context, int $id[, array<string, mixed> $attributes = [] ]) : Paginator
Parameters
- $context : User
- $id : int
- $attributes : array<string, mixed> = []
Tags
Return values
PaginatorviewAlbums()
public
viewAlbums(User $context, User $owner[, array<string, mixed> $attributes = [] ]) : Paginator