PHP Class OEModule\PatientTicketing\models\Queue

The followings are the available columns in table:
Inheritance: extends BaseActiveRecordVersioned
Show file Open project: openeyes/openeyes Class Usage Examples

Protected Properties

Property Type Description
$FIELD_PREFIX used to prevent form field name conflicts
$auto_update_relations

Public Methods

Method Description
addTicket ( Ticket $ticket, CWebUser $user, Firm $firm, $data ) Add the given ticket to the Queue for the user and firm.
afterValidate ( ) assignment field validation.
behaviors ( )
closing ( ) A scope to return queues that don't have outcomes.
getCurrentTicketCount ( ) : array Get the number of tickets that are currently assigned to this queue.
getDependentQueueIds ( array $dependent_ids = [] ) : array Get the ids of queues that depend solely on this queue for tickets to be assigned to them.
getFormFields ( ) : array(array('id' Function to return a list of the fields that we are expecting an assignment form to contain for this queue.
getOutcomeData ( boolean $json = true ) : array | string Get simple data structure of possible outcomes for this Queue.
getQueueSet ( ) : QueueSet Get the QueueSet this Queue belongs to.
getRelatedEventTypes ( $json = true )
getRootQueue ( ) : Queue[] | Queue Get the root queue for this particular queue (Note: this assumes that all queues are only in one path, if that model changes this will not work).
model ( $className = __CLASS__ ) : OphTrOperationnote_GlaucomaTube_PlatePosition Returns the static model of the specified AR class.
notClosing ( ) A scope to only return queues that have active outcomes.
relations ( ) : array
rules ( ) : array
search ( ) : CActiveDataProvider Retrieves a list of models based on the current search/filter conditions.
tableName ( ) : string
validJSON ( $attribute ) Checks the given attribute is valid JSON.

Protected Methods

Method Description
getAssignmentFieldDefinitions ( ) : array Returns the fields that have been defined for this Queue when a ticket is assigned to it.

Private Methods

Method Description
mergeRootQueues ( $root, $candidates ) : array Helper method for handling the construction of the root node set.

Method Details

addTicket() public method

Add the given ticket to the Queue for the user and firm.
public addTicket ( Ticket $ticket, CWebUser $user, Firm $firm, $data )
$ticket Ticket
$user CWebUser
$firm Firm
$data

afterValidate() public method

assignment field validation.
public afterValidate ( )

behaviors() public method

public behaviors ( )

closing() public method

A scope to return queues that don't have outcomes.
public closing ( )

getAssignmentFieldDefinitions() protected method

Returns the fields that have been defined for this Queue when a ticket is assigned to it.
protected getAssignmentFieldDefinitions ( ) : array
return array

getCurrentTicketCount() public method

Get the number of tickets that are currently assigned to this queue.
public getCurrentTicketCount ( ) : array
return array

getDependentQueueIds() public method

Get the ids of queues that depend solely on this queue for tickets to be assigned to them.
public getDependentQueueIds ( array $dependent_ids = [] ) : array
$dependent_ids array
return array

getFormFields() public method

Function to return a list of the fields that we are expecting an assignment form to contain for this queue.
public getFormFields ( ) : array(array('id'
return array(array('id'

getOutcomeData() public method

Get simple data structure of possible outcomes for this Queue.
public getOutcomeData ( boolean $json = true ) : array | string
$json boolean
return array | string

getQueueSet() public method

Get the QueueSet this Queue belongs to.
public getQueueSet ( ) : QueueSet
return QueueSet

getRelatedEventTypes() public method

public getRelatedEventTypes ( $json = true )

getRootQueue() public method

Get the root queue for this particular queue (Note: this assumes that all queues are only in one path, if that model changes this will not work).
public getRootQueue ( ) : Queue[] | Queue
return Queue[] | Queue

model() public static method

Returns the static model of the specified AR class.
public static model ( $className = __CLASS__ ) : OphTrOperationnote_GlaucomaTube_PlatePosition
return OphTrOperationnote_GlaucomaTube_PlatePosition the static model class

notClosing() public method

NOTE: didn't seem to be able to do this with relation definitions.
public notClosing ( )

relations() public method

public relations ( ) : array
return array relational rules.

rules() public method

public rules ( ) : array
return array validation rules for model attributes.

tableName() public method

public tableName ( ) : string
return string the associated database table name

validJSON() public method

Checks the given attribute is valid JSON.
public validJSON ( $attribute )
$attribute

Property Details

$FIELD_PREFIX protected static property

used to prevent form field name conflicts
protected static $FIELD_PREFIX

$auto_update_relations protected property

protected $auto_update_relations