本文整理匯總了PHP中Patient::setName方法的典型用法代碼示例。如果您正苦於以下問題:PHP Patient::setName方法的具體用法?PHP Patient::setName怎麽用?PHP Patient::setName使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Patient
的用法示例。
在下文中一共展示了Patient::setName方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: executeAddPatient
public function executeAddPatient(sfWebRequest $request)
{
if ($request->isMethod('Post')) {
/*$a = new Criteria();
$designation_record = DesignationPeer::DoSelectOne($a);
$department_id = $designation_record->getDepartmentId();*/
$patient = new Patient();
$dob = $this->getRequestParameter('dob[year]') . '-' . $this->getRequestParameter('dob[month]') . '-' . $this->getRequestParameter('dob[day]');
$patient->setName($this->getRequestParameter('name'));
$patient->setCnic($this->getRequestParameter('cnic'));
$patient->setDob($dob);
$patient->setGender($this->getRequestParameter('gender[0]'));
$patient->setContactCell($this->getRequestParameter('contact_cell'));
$patient->setStatus(Constant::RECORD_STATUS_ACTIVE);
$patient->save();
$this->getUser()->setFlash('SUCCESS_MESSAGE', 'Patient Added Successfully');
$this->redirect('Patient/list');
}
// end if
}
示例2: Patient
<?php
require "classes/abstraction/patient.php";
$patient = new Patient();
$patient->setName("bob");
echo $patient->getName() . "<br>";
$patient->setWeight('200');
$patient->setHeight('72');
echo $patient->getWeight() . "<br>";
echo $patient->getHeight() . "<br>";