当前位置: 首页>>代码示例>>PHP>>正文


PHP RoleModel::select方法代码示例

本文整理汇总了PHP中RoleModel::select方法的典型用法代码示例。如果您正苦于以下问题:PHP RoleModel::select方法的具体用法?PHP RoleModel::select怎么用?PHP RoleModel::select使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在RoleModel的用法示例。


在下文中一共展示了RoleModel::select方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getFormCadastre

 public function getFormCadastre()
 {
     $departmentModel = new DepartmentModel();
     $departmentData = $departmentModel->fetchAll($departmentModel->getAllActiveDepartment());
     $roleModel = new RoleModel();
     $roleData = $roleModel->fetchAll($roleModel->select());
     $departmentSupervisorModel = new DepartmentsupervisorModel();
     $departmentSupervisorData = $departmentSupervisorModel->fetchAll($departmentSupervisorModel->getAllSupervisor());
     $companyModel = new CompanyModel();
     $companyData = $companyModel->fetchAll();
     $Arraycompany = array();
     $Arraycompany['0'] = 'Selecione';
     foreach ($companyData as $company) {
         $Arraycompany[$company->cdcompany] = $company->nmfantasyname;
     }
     $this->_nmagenda = new Zend_Form_Element_Text('nmagenda');
     $this->_nmagenda->setLabel("Nome da Agenda");
     $this->_nmagenda->setRequired(true);
     $this->_nmagenda->setDecorators($this->_decoratorsRequired);
     $this->_nmagenda->setAttrib("id", "agenda_nmagendas");
     $this->_nmagenda->setAttrib("class", "alpha nameagenda");
     $this->_nmagenda->setRequired(true);
     $this->_cdcompany = new Zend_Form_Element_Select('cdcompany');
     $this->_cdcompany->setRegisterInArrayValidator(false);
     $this->_cdcompany->addMultiOptions($Arraycompany);
     $this->_cdcompany->setLabel("Empresa");
     $this->_cdcompany->setDecorators($this->_decoratorsRequired);
     $this->_cdcompany->setAttrib("id", "user_cdcompany");
     $this->_cdcompany->setAttrib("class", "alpha");
     $this->_cdcompany->setRequired(true);
     $this->_cdphysicallocation = new Zend_Form_Element_Select('cdphysicallocation');
     $this->_cdphysicallocation->setRegisterInArrayValidator(false);
     $this->_cdphysicallocation->setLabel("Localização Física");
     $this->_cdphysicallocation->addMultiOptions(array('0' => 'Selecione'));
     $this->_cdphysicallocation->setDecorators($this->_decoratorsRequired);
     $this->_cdphysicallocation->setAttrib("id", "company_physicallocation");
     $this->_cdphysicallocation->setAttrib("class", "alpha");
     $this->_cdphysicallocation->setRequired(true);
     $this->_gridhours = new Zend_Form_Element_Select('gridhours');
     $this->_gridhours->setRegisterInArrayValidator(false);
     $this->_gridhours->addMultiOptions(array('1' => 'Sim', '2' => 'Não'));
     $this->_gridhours->setLabel("Grade de Horário");
     $this->_gridhours->setDecorators($this->_decoratorsDefault);
     $this->_gridhours->setAttrib("id", "user_gridhours");
     $this->_gridhours->setRequired(false);
 }
开发者ID:robertsonmello,项目名称:projetos,代码行数:46,代码来源:AgendaForm.php

示例2: __construct

 public function __construct()
 {
     parent::__construct();
     $departmentModel = new DepartmentModel();
     $departmentData = $departmentModel->fetchAll($departmentModel->getAllActiveDepartment());
     $roleModel = new RoleModel();
     $roleData = $roleModel->fetchAll($roleModel->select());
     //        $departmentSupervisorModel = new DepartmentsupervisorModel();
     //        $userData = $departmentSupervisorModel->fetchAll($departmentSupervisorModel->getAllSupervisor());
     $this->_nmuserimage = new Zend_Form_Element_Hidden('nmuserimage');
     $this->_nmuserimage->setDecorators($this->_decoratorsDefaultRight);
     $this->_nmuserimage->setAttrib("id", "user_nmuserimage");
     $this->_cdusergslab = new Zend_Form_Element_Hidden('cdusergslab');
     $this->_cdusergslab->setDecorators($this->_decoratorsDefault);
     $this->_cdusergslab->setAttrib("id", "user_cdusergslab");
     $this->_idusergslab = new Zend_Form_Element_Text('idusergslab');
     $this->_idusergslab->setLabel("Login");
     $this->_idusergslab->setRequired(true);
     $this->_idusergslab->setDecorators($this->_decoratorsRequired);
     $this->_idusergslab->setAttrib("id", "user_idusergslab");
     $this->_idusergslab->setAttrib("class", "alpha");
     $this->_nmpassword = new Zend_Form_Element_Password('nmpassword');
     $this->_nmpassword->setLabel("Senha");
     $this->_nmpassword->setRequired(true);
     $this->_nmpassword->setAttrib("id", "user_nmpassword");
     $this->_nmpassword->setDecorators($this->_decoratorsRequired);
     $this->_confirmpassword = new Zend_Form_Element_Password('confirmpassword');
     $this->_confirmpassword->setLabel("Confirmar Senha");
     $this->_confirmpassword->setRequired(true);
     $this->_confirmpassword->setAttrib("id", "user_confirmpassword");
     $this->_confirmpassword->setDecorators($this->_decoratorsRequired);
     $this->_idemployeeregister = new Zend_Form_Element_Text('idemployeeregister');
     $this->_idemployeeregister->setLabel("Matrícula");
     $this->_idemployeeregister->setDecorators($this->_decoratorsDefault);
     $this->_idemployeeregister->setAttrib("id", "user_idemployeeregister");
     $this->_idemployeeregister->setAttrib("class", "numeric");
     $this->_nmusergslab = new Zend_Form_Element_Text('nmusergslab');
     $this->_nmusergslab->setLabel("Nome Completo");
     $this->_nmusergslab->setDecorators($this->_decoratorsRequired);
     $this->_nmusergslab->setAttrib("id", "user_nmusergslab");
     $this->_nmusergslab->setAttrib("class", "alpha");
     $this->_nmusergslab->setRequired(true);
     $this->_nmmail = new Zend_Form_Element_Text('nmmail');
     $this->_nmmail->setLabel("E-mail");
     $this->_nmmail->setDecorators($this->_decoratorsDefault);
     $this->_nmmail->setAttrib("id", "user_nmmail");
     $this->_nmmail->setAttrib("class", "required_email");
     $this->_nmmail->setRequired(false);
     $this->_idcep = new Zend_Form_Element_Text('idcep');
     $this->_idcep->setLabel("CEP");
     $this->_idcep->setDecorators($this->_decoratorsDefault);
     $this->_idcep->setAttrib("id", "user_idcep");
     $this->_idcep->setAttrib("class", "numeric");
     $this->_idrg = new Zend_Form_Element_Text('idrg');
     $this->_idrg->setLabel("RG");
     $this->_idrg->setDecorators($this->_decoratorsDefault);
     $this->_idrg->setAttrib("id", "user_idrg");
     $this->_idrg->setAttrib("class", "numeric");
     $this->_idrg->setRequired(false);
     $this->_idcpf = new Zend_Form_Element_Text('idcpf');
     $this->_idcpf->setLabel("CPF");
     $this->_idcpf->setDecorators($this->_decoratorsDefault);
     $this->_idcpf->setAttrib("id", "user_idcpf");
     $this->_idcpf->setAttrib("class", "mask_cpf");
     $this->_idcpf->setRequired(false);
     $this->_nmstreet = new Zend_Form_Element_Text('nmstreet');
     $this->_nmstreet->setLabel("Rua");
     $this->_nmstreet->setDecorators($this->_decoratorsRequired);
     $this->_nmstreet->setAttrib("id", "user_nmstreet");
     $this->_nmstreet->setRequired(true);
     $this->_nrnumber = new Zend_Form_Element_Text('nrnumber');
     $this->_nrnumber->setLabel("Número");
     $this->_nrnumber->setRequired(true);
     $this->_nrnumber->setDecorators($this->_decoratorsRequired);
     $this->_nrnumber->setAttrib("id", "user_nrnumber");
     $this->_nrnumber->setAttrib("class", "numeric");
     $this->_idcity = new Zend_Form_Element_Text('idcity');
     $this->_idcity->setLabel("Cidade");
     $this->_idcity->setRequired(true);
     $this->_idcity->setDecorators($this->_decoratorsRequired);
     $this->_idcity->setAttrib("id", "user_idcity");
     $this->_idcity->setAttrib("class", "alpha");
     $this->_idstate = new Zend_Form_Element_Select('idstate');
     $this->_idstate->setRegisterInArrayValidator(false);
     $this->_idstate->addMultiOption("", "UF");
     $this->_idstate->addMultiOption("AC", "AC");
     $this->_idstate->addMultiOption("AL", "AL");
     $this->_idstate->addMultiOption("AP", "AP");
     $this->_idstate->addMultiOption("AM", "AM");
     $this->_idstate->addMultiOption("BA", "BA");
     $this->_idstate->addMultiOption("CE", "CE");
     $this->_idstate->addMultiOption("SP", "SP");
     $this->_idstate->addMultiOption("DF", "DF");
     $this->_idstate->addMultiOption("ES", "ES");
     $this->_idstate->addMultiOption("GO", "GO");
     $this->_idstate->addMultiOption("MA", "MA");
     $this->_idstate->addMultiOption("MT", "MT");
     $this->_idstate->addMultiOption("MS", "MS");
     $this->_idstate->addMultiOption("MG", "MG");
     $this->_idstate->addMultiOption("PA", "PA");
//.........这里部分代码省略.........
开发者ID:robertsonmello,项目名称:projetos,代码行数:101,代码来源:UserForm.php


注:本文中的RoleModel::select方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。