OphTrOperationbooking_Operation_Name_Rule::model PHP Method

model() public static method

Returns the static model of the specified AR class.
public static model ( $className = __CLASS__ ) : the
return the static model class
    public static function model($className = __CLASS__)
    {
        return parent::model($className);
    }

Usage Example

 public function getTextOperationName()
 {
     if ($rule = OphTrOperationbooking_Operation_Name_Rule::model()->find('theatre_id=?', array($this->booking->session->theatre_id))) {
         return $this->getPatient()->childPrefix . $rule->name;
     }
     if ($rule = OphTrOperationbooking_Operation_Name_Rule::model()->find('theatre_id is null')) {
         return $this->getPatient()->childPrefix . $rule->name;
     }
     return $this->getPatient()->childPrefix . 'operation';
 }
All Usage Examples Of OphTrOperationbooking_Operation_Name_Rule::model