本文整理汇总了PHP中Admin::setModelDisplayName方法的典型用法代码示例。如果您正苦于以下问题:PHP Admin::setModelDisplayName方法的具体用法?PHP Admin::setModelDisplayName怎么用?PHP Admin::setModelDisplayName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Admin
的用法示例。
在下文中一共展示了Admin::setModelDisplayName方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: actionEdit
/**
* Edits or adds a lens type.
*
* @param bool|int $id
*
* @throws CHttpException
*/
public function actionEdit($id = false)
{
$admin = new Admin(OphInBiometry_LensType_Lens::model(), $this);
if ($id) {
$admin->setModelId($id);
}
$admin->setModelDisplayName('Lens types');
$admin->setEditFields(array('name' => 'text', 'description' => 'text', 'acon' => 'text', 'active' => 'checkbox'));
$admin->editModel();
}
示例2: actionList
/**
* Lists procedures.
*
* @throws CHttpException
*/
public function actionList()
{
$admin = new Admin(AutomaticExaminationEventLog::model(), $this);
$admin->setModelDisplayName('Examination Event Log(s)');
$admin->setListFields(array('event_id', 'unique_code', 'examination_date', 'import_status.status_value'));
$admin->searchAll();
$admin->getSearch()->addSearchItem('import_success', array('type' => 'dropdown', 'options' => CHtml::listData(ImportStatus::model()->findAll(), 'id', 'status_value')));
$admin->getSearch()->setItemsPerPage($this->itemsPerPage);
$admin->listModel(false);
}
示例3: actionEdit
/**
* Edits or adds a Procedure.
*
* @param bool|int $id
*
* @throws CHttpException
*/
public function actionEdit($id = false)
{
$admin = new Admin(UniqueCodes::model(), $this);
if ($id) {
$admin->setModelId($id);
}
$admin->setModelDisplayName('Unique Codes');
$admin->setEditFields(array('code' => 'label', 'active' => 'checkbox'));
$admin->editModel();
}
示例4: actionEdit
/**
* Edits or adds an operative device.
*
* @param bool|int $id
*
* @throws CHttpException
*/
public function actionEdit($id = false)
{
$admin = new Admin(OperativeDevice::model(), $this);
$admin->setModelDisplayName('Operative Device');
if ($id) {
$admin->setModelId($id);
}
$admin->setEditFields(array('name' => 'text', 'active' => 'checkbox'));
$admin->editModel();
}
示例5: actionEdit
/**
* Edits or adds a Procedure.
*
* @param bool|int $id
*
* @throws CHttpException
*/
public function actionEdit($id = false)
{
$admin = new Admin(FormularyDrugs::model(), $this);
if ($id) {
$admin->setModelId($id);
}
$admin->setModelDisplayName('Formulary Drugs');
$criteria = new CDbCriteria();
$admin->setEditFields(array('id' => 'label', 'name' => 'text', 'type_id' => array('widget' => 'DropDownList', 'options' => CHtml::listData(DrugType::model()->findAll(), 'id', 'name'), 'htmlOptions' => null, 'hidden' => false, 'layoutColumns' => null), 'aliases' => 'text', 'tallman' => 'text', 'form_id' => array('widget' => 'DropDownList', 'options' => CHtml::listData(DrugForm::model()->findAll(), 'id', 'name'), 'htmlOptions' => null, 'hidden' => false, 'layoutColumns' => null), 'dose_unit' => 'text', 'default_dose' => 'text', 'default_route_id' => array('widget' => 'DropDownList', 'options' => CHtml::listData(DrugRoute::model()->findAll(), 'id', 'name'), 'htmlOptions' => array('empty' => '-- Please select --'), 'hidden' => false, 'layoutColumns' => null), 'default_frequency_id' => array('widget' => 'DropDownList', 'options' => CHtml::listData(DrugFrequency::model()->findAll(), 'id', 'name'), 'htmlOptions' => array('empty' => '-- Please select --'), 'hidden' => false, 'layoutColumns' => null), 'default_duration_id' => array('widget' => 'DropDownList', 'options' => CHtml::listData(DrugDuration::model()->findAll(), 'id', 'name'), 'htmlOptions' => array('empty' => '-- Please select --'), 'hidden' => false, 'layoutColumns' => null), 'preservative_free' => 'checkbox', 'active' => 'checkbox', 'allergy_warnings' => array('widget' => 'MultiSelectList', 'relation_field_id' => 'id', 'label' => 'Allergy Warnings', 'options' => CHtml::encodeArray(CHtml::listData(Allergy::model()->findAll($criteria->condition = "name != 'Other'"), 'id', 'name')))));
$admin->editModel();
}
示例6: actionEdit
/**
* Edits or adds a Procedure.
*
* @param bool|int $id
*
* @throws CHttpException
*/
public function actionEdit($id = false)
{
$admin = new Admin(OEModule\OphCiExamination\models\OphCiExamination_Attribute::model(), $this);
$admin->setCustomSaveURL('/oeadmin/ExaminationElementAttributes/update');
if ($id) {
$admin->setModelId($id);
}
$admin->setModelDisplayName('Element Attributes');
$admin->setEditFields(array('id' => 'label', 'name' => 'text', 'label' => 'text', 'attribute_elements' => array('widget' => 'DropDownList', 'options' => CHtml::listData(ElementType::model()->findAll(), 'id', 'name'), 'htmlOptions' => null, 'hidden' => false, 'layoutColumns' => null)));
$admin->editModel();
}