The followings are the available columns in table:
Inheritance: extends BaseEventTypeElement
Esempio n. 1
0
 */
if ($this->checkPrintAccess()) {
    $this->event_actions[] = EventAction::button('Print', 'print', array(), array('class' => 'button small'));
    $this->event_actions[] = EventAction::button('Print for visually impaired', 'print_va', array(), array('class' => 'button small'));
}
$this->beginContent('//patient/event_container');
?>

	<?php 
if ($this->event->delete_pending) {
    ?>
		<div class="alert-box alert with-icon">
			This event is pending deletion and has been locked.
		</div>
	<?php 
} elseif (Element_OphTrConsent_Type::model()->find('event_id=?', array($this->event->id))->draft) {
    ?>
		<div class="alert-box alert with-icon">
			This consent form is a draft and can still be edited
		</div>
	<?php 
}
?>

	<?php 
$this->renderOpenElements($this->action->id);
?>

	<?php 
// The "print" value is set by the controller and comes from the user session
?>
Esempio n. 2
0
 public function actionMarkPrinted($id)
 {
     if ($type = Element_OphTrConsent_Type::model()->find('event_id=?', array($id))) {
         $type->print = 0;
         $type->draft = 0;
         if (!$type->save()) {
             throw new Exception('Unable to mark consent form printed: ' . print_r($type->getErrors(), true));
         }
     }
 }
Esempio n. 3
0
 public function canUpdate($event_id)
 {
     $type = Element_OphTrConsent_Type::model()->find('event_id=?', array($event_id));
     return $type->isEditable();
 }