PHP Class MessagesController, vanilla

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

Méthodes publiques

Свойство Type Description
$ConversationModel ConversationModel
$Form Gdn_Form
$Offset The current offset of the paged data set. Defined and used by $this->Index and $this->All.
$RecipientData A dataset of users taking part in this discussion. Used by $this->Index.
$Uses Models to include.

Méthodes publiques

Méthode Description
add ( string $Recipient = '', string $Subject = '' ) Start a new conversation.
addMessage ( integer $ConversationID = '' ) Add a message to a conversation.
all ( string $Page = '' ) Show all conversations for the currently authenticated user.
bookmark ( integer $ConversationID = '', string $TransientKey = '' ) Allows users to bookmark conversations.
clear ( integer $ConversationID = false, string $TransientKey = '' ) Clear the message history for a specific conversation & user.
getNew ( $ConversationID, null $LastMessageID = null )
inbox ( string $Page = '' ) Show bookmarked conversations for the current user.
index ( integer $ConversationID = false, integer $Offset, integer $Limit = '' ) Shows all uncleared messages within a conversation for the viewing user
initialize ( ) Highlight route and include JS, CSS, and modules used by all methods.
leave ( integer $conversationID ) Leave a conversation that a user is participating in.
popin ( )

Method Details

add() public méthode

Start a new conversation.
Since: 2.0.0
public add ( string $Recipient = '', string $Subject = '' )
$Recipient string Username of the recipient.
$Subject string Subject of the message.

addMessage() public méthode

Add a message to a conversation.
Since: 2.0.0
public addMessage ( integer $ConversationID = '' )
$ConversationID integer Unique ID of the conversation.

all() public méthode

Show all conversations for the currently authenticated user.
Since: 2.0.0
public all ( string $Page = '' )
$Page string The page number argument.

bookmark() public méthode

Allows users to bookmark conversations.
public bookmark ( integer $ConversationID = '', string $TransientKey = '' )
$ConversationID integer Unique ID of conversation to view.
$TransientKey string Single-use hash to prove intent.

clear() public méthode

Clear the message history for a specific conversation & user.
public clear ( integer $ConversationID = false, string $TransientKey = '' )
$ConversationID integer Unique ID of conversation to clear.
$TransientKey string The CSRF token.

getNew() public méthode

public getNew ( $ConversationID, null $LastMessageID = null )
$ConversationID
$LastMessageID null

inbox() public méthode

Show bookmarked conversations for the current user.
public inbox ( string $Page = '' )
$Page string The page number string.

index() public méthode

Shows all uncleared messages within a conversation for the viewing user
Since: 2.0.0
public index ( integer $ConversationID = false, integer $Offset, integer $Limit = '' )
$ConversationID integer Unique ID of conversation to view.
$Offset integer Number to skip.
$Limit integer Number to show.

initialize() public méthode

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

leave() public méthode

Leave a conversation that a user is participating in.
public leave ( integer $conversationID )
$conversationID integer The ID of the conversation to leave.

popin() public méthode

public popin ( )

Property Details

$ConversationModel public_oe property

public ConversationModel $ConversationModel
Résultat ConversationModel

$Form public_oe property

public Gdn_Form $Form
Résultat Gdn_Form

$Offset public_oe property

The current offset of the paged data set. Defined and used by $this->Index and $this->All.
public $Offset

$RecipientData public_oe property

A dataset of users taking part in this discussion. Used by $this->Index.
public $RecipientData

$Uses public_oe property

Models to include.
public $Uses