public function getInjectionTreatments($side)
{
if ($this->injectionInstalled()) {
# Note that this will namespaced to modules at some point.
$treatments = \OphTrIntravitrealinjection_Treatment_Drug::model()->active()->findAll();
if ($current_id = $this->{$side . '_treatment_id'}) {
$treatment_list = array();
foreach ($treatments as $treatment) {
if ($treatment->id == $current_id) {
return $treatments;
}
$treatment_list[] = $treatment;
}
$treatment_list[] = $this->{$side . '_treatment'};
$treatments = $treatment_list;
}
return $treatments;
}
}