PHP Class OEModule\OphCiExamination\models\Element_OphCiExamination_InjectionManagementComplex

The followings are the available columns in table:
Inheritance: extends SplitEventTypeElement
Afficher le fichier Open project: openeyes/openeyes Class Usage Examples

Protected Properties

Свойство Type Description
$_injection_installed

Méthodes publiques

Méthode Description
answerValidation ( unknown $attribute, array $params ) validate that all the questions for the set diagnosis have been answered.
attributeLabels ( ) : array
canCopy ( )
delete ( ) extends standard delete method to remove any risk assignments made to it.
getAllDisorders ( )
getInjectionQuestionsForDisorderId ( integer $disorder_id, array $answered_question_ids = null ) return the questions for a given disorder id.
getInjectionQuestionsForSide ( string $side ) : OphCiExamination_InjectionManagementComplex_Question[] get the relevant questions for the given side.
getInjectionSide ( ) : integer | null return the side (Eye::BOTH, \Eye::LEFT or \Eye::RIGHT) that should be injected if one should be. null otherwise.
getInjectionTreatments ( $side ) : OphTrIntravitrealinjection_Treatment_Drug[] | null get the treatments list to select from for this element on the given side.
getLeftDiagnosisString ( ) : string get the diagnosis string for the left.
getLeftNoTreatmentReasonName ( ) : string get the no treatment reason name for the left side.
getLetter_string ( ) : string get the string of this element for use in correspondence.
getLevel1Disorders ( ) : Disorder[] Get a list of level 1 disorders for this element (appends any level 1 disorder that has been selected for this element but aren't part of the default list).
getLevel2Disorders ( $disorder ) : Disorder[] retrieve a list of disorders that are defined as level 2 disorders for the given disorder.
getNoTreatmentReasons ( ) : OphCiExamination_InjectionManagementComplex_NoTreatmentReason[] get the list of no treatment reasons that should be used for this element.
getQuestionAnswer ( unknown $side, unknown $question_id ) get the answer that has been set for the $side and $question_id.
getRightDiagnosisString ( ) : string get the diagnosis string for the right.
getRightNoTreatmentReasonName ( ) : string get the no treatment reason name for the right side.
getRiskValues ( ) get the risk ids currently in use by the element.
getRisksForSide ( $side ) : array get the risk options for a given side.
getleft_treatment ( ) : OphTrIntravitrealinjection_Treatment_Drug | null return the treatment drug for the left side if defined.
getright_treatment ( ) : OphTrIntravitrealinjection_Treatment_Drug | null return the treatment drug for the right side if defined.
ifInjectionInstalled ( $attribute, $params ) pass through validation function that will run the 'check' attribute method if the injection module is installed.
injectionInstalled ( ) : boolean returns boolean to indicate if the injection module is installed (and therefore whether we can pick treatments from that module).
model ( $className = __CLASS__ ) : the Returns the static model of the specified AR class.
relations ( ) : array
requiredIfNoTreatment ( $attribute, $params ) checks value defined when no treatment is set on the element.
requiredIfNoTreatmentOther ( $attribute, $params ) checks $attribute defined when the no treatment reason is an 'other' type.
requiredIfSecondary ( $attribute, $params ) check a level 2 diagnosis is provided for level 1 diagnoses that require it (need to check the side as well though).
requiredIfTreatment ( string $attribute, array $params ) simple wrapper around requiredIfSide that checks the no treatment status flag before checking the side required attribute.
rules ( ) : array
search ( ) : CActiveDataProvider Retrieves a list of models based on the current search/filter conditions.
sidedFields ( )
tableName ( ) : string
updateQuestionAnswers ( string $side, array $update_answers ) store the answers for the questions asked for the $side diagnosis.
updateRisks ( string $side, int[] $risk_ids ) update the risks for the given side.

Méthodes protégées

Méthode Description
getDiagnosisString ( string $side ) : string get the diagnosis string for the give side.
getLetterStringForSide ( $side ) : string gets a string of the information contained in this element for the given side.
getNoTreatmentReasonName ( string $side ) : string get the reason for no treatment as a string for given side.

Method Details

answerValidation() public méthode

validate that all the questions for the set diagnosis have been answered.
public answerValidation ( unknown $attribute, array $params )
$attribute unknown
$params array

attributeLabels() public méthode

public attributeLabels ( ) : array
Résultat array customized attribute labels (name=>label)

canCopy() public méthode

public canCopy ( )

delete() public méthode

(non-PHPdoc)
See also: CActiveRecord::delete()
public delete ( )

getAllDisorders() public méthode

public getAllDisorders ( )

getDiagnosisString() protected méthode

get the diagnosis string for the give side.
protected getDiagnosisString ( string $side ) : string
$side string - left or right
Résultat string string

getInjectionQuestionsForDisorderId() public méthode

return the questions for a given disorder id.
public getInjectionQuestionsForDisorderId ( integer $disorder_id, array $answered_question_ids = null )
$disorder_id integer
$answered_question_ids array

getInjectionQuestionsForSide() public méthode

get the relevant questions for the given side.
public getInjectionQuestionsForSide ( string $side ) : OphCiExamination_InjectionManagementComplex_Question[]
$side string - 'left' or 'right'
Résultat OphCiExamination_InjectionManagementComplex_Question[]

getInjectionSide() public méthode

return the side (Eye::BOTH, \Eye::LEFT or \Eye::RIGHT) that should be injected if one should be. null otherwise.
public getInjectionSide ( ) : integer | null
Résultat integer | null

getInjectionTreatments() public méthode

get the treatments list to select from for this element on the given side.
public getInjectionTreatments ( $side ) : OphTrIntravitrealinjection_Treatment_Drug[] | null
$side
Résultat OphTrIntravitrealinjection_Treatment_Drug[] | null

getLeftDiagnosisString() public méthode

get the diagnosis string for the left.
public getLeftDiagnosisString ( ) : string
Résultat string

getLeftNoTreatmentReasonName() public méthode

get the no treatment reason name for the left side.
public getLeftNoTreatmentReasonName ( ) : string
Résultat string

getLetterStringForSide() protected méthode

gets a string of the information contained in this element for the given side.
protected getLetterStringForSide ( $side ) : string
$side
Résultat string

getLetter_string() public méthode

get the string of this element for use in correspondence.
public getLetter_string ( ) : string
Résultat string

getLevel1Disorders() public méthode

Get a list of level 1 disorders for this element (appends any level 1 disorder that has been selected for this element but aren't part of the default list).
public getLevel1Disorders ( ) : Disorder[]
Résultat Disorder[]

getLevel2Disorders() public méthode

retrieve a list of disorders that are defined as level 2 disorders for the given disorder.
public getLevel2Disorders ( $disorder ) : Disorder[]
Résultat Disorder[]

getNoTreatmentReasonName() protected méthode

get the reason for no treatment as a string for given side.
protected getNoTreatmentReasonName ( string $side ) : string
$side string
Résultat string

getNoTreatmentReasons() public méthode

get the list of no treatment reasons that should be used for this element.
public getNoTreatmentReasons ( ) : OphCiExamination_InjectionManagementComplex_NoTreatmentReason[]
Résultat OphCiExamination_InjectionManagementComplex_NoTreatmentReason[]

getQuestionAnswer() public méthode

get the answer that has been set for the $side and $question_id.
public getQuestionAnswer ( unknown $side, unknown $question_id )
$side unknown
$question_id unknown

getRightDiagnosisString() public méthode

get the diagnosis string for the right.
public getRightDiagnosisString ( ) : string
Résultat string

getRightNoTreatmentReasonName() public méthode

get the no treatment reason name for the right side.

getRiskValues() public méthode

get the risk ids currently in use by the element.
public getRiskValues ( )

getRisksForSide() public méthode

get the risk options for a given side.
public getRisksForSide ( $side ) : array
$side
Résultat array

getleft_treatment() public méthode

defines relation to external model, hence not using the yii magic relations definition
public getleft_treatment ( ) : OphTrIntravitrealinjection_Treatment_Drug | null
Résultat OphTrIntravitrealinjection_Treatment_Drug | null

getright_treatment() public méthode

defines relation to external model, hence not using the yii magic relations definition
public getright_treatment ( ) : OphTrIntravitrealinjection_Treatment_Drug | null
Résultat OphTrIntravitrealinjection_Treatment_Drug | null

ifInjectionInstalled() public méthode

pass through validation function that will run the 'check' attribute method if the injection module is installed.
public ifInjectionInstalled ( $attribute, $params )
$attribute
$params

injectionInstalled() public méthode

returns boolean to indicate if the injection module is installed (and therefore whether we can pick treatments from that module).
public injectionInstalled ( ) : boolean
Résultat boolean

model() public static méthode

Returns the static model of the specified AR class.
public static model ( $className = __CLASS__ ) : the
Résultat the static model class

relations() public méthode

public relations ( ) : array
Résultat array relational rules.

requiredIfNoTreatment() public méthode

checks value defined when no treatment is set on the element.
public requiredIfNoTreatment ( $attribute, $params )
$attribute
$params

requiredIfNoTreatmentOther() public méthode

checks $attribute defined when the no treatment reason is an 'other' type.
public requiredIfNoTreatmentOther ( $attribute, $params )
$attribute
$params

requiredIfSecondary() public méthode

check a level 2 diagnosis is provided for level 1 diagnoses that require it (need to check the side as well though).
public requiredIfSecondary ( $attribute, $params )

requiredIfTreatment() public méthode

simple wrapper around requiredIfSide that checks the no treatment status flag before checking the side required attribute.
public requiredIfTreatment ( string $attribute, array $params )
$attribute string
$params array

rules() public méthode

public rules ( ) : array
Résultat array validation rules for model attributes.

sidedFields() public méthode

public sidedFields ( )

tableName() public méthode

public tableName ( ) : string
Résultat string the associated database table name

updateQuestionAnswers() public méthode

store the answers for the questions asked for the $side diagnosis.
public updateQuestionAnswers ( string $side, array $update_answers )
$side string
$update_answers array - associate array of question id to answer value

updateRisks() public méthode

update the risks for the given side.
public updateRisks ( string $side, int[] $risk_ids )
$side string
$risk_ids int[] - array of risk ids to assign to the element

Property Details

$_injection_installed protected_oe property

protected $_injection_installed