public function indexAction() { if (isset($this->_session->messages)) { $this->view->messages = $this->_session->messages; } $this->_form = new WebVista_Form(array('name' => 'patient-new')); $this->_form->setAction(Zend_Registry::get('baseUrl') . "patient-new.raw/add-process"); $this->_patient = new Patient(); $this->_patient->defaultProvider = (int) Zend_Auth::getInstance()->getIdentity()->personId; $this->_address = new Address(); $this->_phoneNumber = new PhoneNumber(); $this->_form->loadORM($this->_patient, "Patient"); $this->_form->setWindow('windowNewPatientId'); //$this->_form->registrationLocationId->setValue($this->_location->locationId); $this->view->form = $this->_form; $this->view->statesList = Address::getStatesList(); $this->view->phoneTypes = PhoneNumber::getListPhoneTypes(); $this->view->addressTypes = Address::getListAddressTypes(); $this->render(); }
public function detailsAction() { $patientId = (int) $this->_getParam('patientId'); $this->_patient = new Patient(); $this->_patient->person_id = $patientId; $this->_patient->populate(); $facilityIterator = new FacilityIterator(); $facilityIterator->setFilter(array('Practice')); $this->_form = new WebVista_Form(array('name' => 'patient-details')); $this->_form->setAction(Zend_Registry::get('baseUrl') . "patient.raw/process-details"); $this->_form->loadORM($this->_patient, "Patient"); $this->_form->setWindow('windowPatientDetailsId'); $this->view->form = $this->_form; $this->view->facilityIterator = $facilityIterator; $this->view->reasons = PatientNote::listReasons(); $this->view->statesList = Address::getStatesList(); $this->view->phoneTypes = PhoneNumber::getListPhoneTypes(); $this->view->addressTypes = Address::getListAddressTypes(); $this->render(); }
public function editCompanyAction() { $id = (int) $this->_getParam('id'); $this->_company = new Company(); if ($id > 0) { $this->_company->companyId = $id; $this->_company->populate(); } $this->_form = new WebVista_Form(array('name' => 'edit-company')); $this->_form->setAction(Zend_Registry::get('baseUrl') . 'insurance-manager.raw/process-edit-company'); $this->_form->loadORM($this->_company, 'company'); $this->_form->setWindow('winEditCompanyId'); $this->view->form = $this->_form; $this->view->email = $this->_company->_companyEmail; $this->view->statesList = Address::getStatesList(); $this->view->phoneTypes = PhoneNumber::getListPhoneTypes(); $this->view->addressTypes = Address::getListAddressTypes(); $this->render('edit-company'); }
public function editAction() { $personId = (int) $this->_getParam('personId'); if (isset($this->_session->messages)) { $this->view->messages = $this->_session->messages; } $this->_form = new WebVista_Form(array('name' => 'person-detail')); $this->_form->setAction(Zend_Registry::get('baseUrl') . "admin-persons.raw/edit-process"); $this->_person = new Person(); $this->_person->person_id = $personId; $this->_person->populate(); $this->_form->loadORM($this->_person, "Person"); //var_dump($this->_form); $this->view->form = $this->_form; $this->view->person = $this->_person; $practices = array('' => ''); $facilityIterator = new FacilityIterator(); $facilityIterator->setFilter(array('Practice')); foreach ($facilityIterator as $practice) { $practices[$practice->id] = $practice->name; } $this->view->practices = $practices; $genders = array('' => ''); $gender = Enumeration::getEnumArray('Gender', 'key'); foreach ($gender as $key => $value) { $genders[$key] = $value; } $this->view->genders = $genders; $maritalStatuses = array('' => ''); $maritalStatus = Enumeration::getEnumArray('Marital Status', 'key'); foreach ($maritalStatus as $key => $value) { $maritalStatuses[$key] = $value; } $this->view->maritalStatuses = $maritalStatuses; $this->view->statesList = Address::getStatesList(); $this->view->phoneTypes = PhoneNumber::getListPhoneTypes(); $this->view->addressTypes = Address::getListAddressTypes(); $identifierTypes = array('' => ''); $identifierType = Enumeration::getEnumArray('Identifier Type', 'key'); foreach ($identifierType as $key => $value) { $identifierTypes[$key] = $value; } $this->view->identifierTypes = $identifierTypes; //Person::getListIdentifierTypes(); $this->render('edit-person'); }