PHP Class DiscussionsController, vanilla

Inheritance: extends ProjectController
Afficher le fichier Open project: vanilla/vanilla Class Usage Examples

Méthodes publiques

Свойство Type Description
$Category Category object. Used to limit which discussions are returned to a particular category.
$CategoryID Unique identifier for category.
$ShowOptions Value indicating if discussion options should be displayed when rendering the discussion view.
$Uses to include.

Protected Properties

Свойство Type Description
$categoryIDs Limit the discussions to just this list of categories, checked for view permission.

Méthodes publiques

Méthode Description
bookmarked ( $Page = '0' ) Display discussions the user has bookmarked.
bookmarkedPopin ( )
getCategoryIDs ( ) : array
getCommentCounts ( ) Takes a set of discussion identifiers and returns their comment counts in the same order.
index ( integer $Page = false ) Default all discussions view: chronological by most recent comment.
initialize ( ) Highlight route and include JS, CSS, and modules used by all methods.
mine ( $Page = 'p1' ) Display discussions started by the user.
promoted ( ) Endpoint for the PromotedContentModule's data.
setCategoryIDs ( array $categoryIDs )
sort ( string $Target = '' ) Set user preference for sorting discussions.
table ( integer $Page = '0' ) "Table" layout for discussions. Mimics more traditional forum discussion layout.
unread ( $Page = '0' )
userBookmarkCount ( $UserID = false )

Method Details

bookmarked() public méthode

Display discussions the user has bookmarked.
Since: 2.0.0
public bookmarked ( $Page = '0' )

bookmarkedPopin() public méthode

public bookmarkedPopin ( )

getCategoryIDs() public méthode

public getCategoryIDs ( ) : array
Résultat array

getCommentCounts() public méthode

Takes a set of discussion identifiers and returns their comment counts in the same order.
public getCommentCounts ( )

index() public méthode

Default all discussions view: chronological by most recent comment.
Since: 2.0.0
public index ( integer $Page = false )
$Page integer Multiplied by PerPage option to determine offset.

initialize() public méthode

Always called by dispatcher before controller's requested method.
Since: 2.0.0
public initialize ( )

mine() public méthode

Display discussions started by the user.
Since: 2.0.0
public mine ( $Page = 'p1' )

promoted() public méthode

Parameters & values must be lowercase and via GET.
See also: PromotedContentModule
public promoted ( )

setCategoryIDs() public méthode

public setCategoryIDs ( array $categoryIDs )
$categoryIDs array

sort() public méthode

Set user preference for sorting discussions.
public sort ( string $Target = '' )
$Target string The target to redirect to.

table() public méthode

"Table" layout for discussions. Mimics more traditional forum discussion layout.
public table ( integer $Page = '0' )
$Page integer Multiplied by PerPage option to determine offset.

unread() public méthode

Deprecation: since 2.3
public unread ( $Page = '0' )

userBookmarkCount() public méthode

public userBookmarkCount ( $UserID = false )

Property Details

$Category public_oe property

Category object. Used to limit which discussions are returned to a particular category.
public $Category

$CategoryID public_oe property

Unique identifier for category.
public $CategoryID

$ShowOptions public_oe property

Value indicating if discussion options should be displayed when rendering the discussion view.
public $ShowOptions

$Uses public_oe property

to include.
public $Uses

$categoryIDs protected_oe property

Limit the discussions to just this list of categories, checked for view permission.
protected $categoryIDs