✏️ 正在编辑: CallcenterFiltroAtendimentos.php
路径:
/srv/systems_dir/yuppiecred/application/forms/CallcenterFiltroAtendimentos.php
提示:
您可以编辑任何文件(包括二进制文件),但请注意不当修改可能导致文件损坏。
<?php class Form_CallcenterFiltroAtendimentos extends Core_Form { public function init() { $usuario = Yuppie_Auth::getIdentity(); $campanhas = Core_Combos::getCallcenterCampanhasAtivas(); $this->setAction($this->getView()->url(array( 'controller' => 'callcenter-relatorios', 'action' => 'atendimentos' ), null, true)); $this->setName('f_filtro_callcenter_atendimentos'); $this->addMultiOptionElement('campanha_id', 'Campanha:', 'multi_callcenter', $campanhas); if ($usuario->grupo == 'Supervisor'){ $this->addElement('hidden', 'gerente_id', [ 'class' => 'invisivel', 'value' => $usuario->id ]); } $select = new Zend_Form_Element_Select('rota_id'); $select->setLabel('Rotas:') ->addMultiOptions(Core_Combos::getRotasOptions()); $this->addElement($select); $this->addElement('select', 'usuario', [ 'label' => 'Operador:', "multiOptions" => Core_Combos::getCallcenterOperadoresOptions(true) ]); $this->getElement('usuario')->addDecorator('Label', ['tag' => 'dt', 'tagClass' => 'clear']); $this->addElement('text', 'cpf', [ 'label' => 'CPF:', 'onkeypress' => 'mascara(this, fcpf)', 'maxlength' => 14, 'validators' => [new Validators_Cpf()] ]); $status = Core_Combos::getCallcenterStatusOptions(); $this->addElement('select', 'status_anterior', [ 'label' => 'Status Histórico:', "multiOptions" => $status ]); $this->getElement('status_anterior')->addDecorator('Label', ['tag' => 'dt', 'tagClass' => 'clear']); $select = new Zend_Form_Element_Select('status_atual'); $select->setLabel('Status Atual:') ->addMultiOptions($status); $this->addElement($select); $this->addElement(Form_DatePicker::getDatePicker('data_inicial', 'Data/Hora: De:')); $this->getElement('data_inicial') ->addDecorator('Label', array( 'tag' => 'dt', 'tagClass' => 'clear' )); $this->addElement('text', 'hora_inicial', [ 'label' => 'Hora inicial:', 'onkeypress' => 'mascara(this, hora)', 'maxlength' => 5, ]); $this->getElement('hora_inicial')->removeDecorator('Label'); $this->addElement(Form_DatePicker::getDatePicker('data_final', 'até:')); $this->addElement('text', 'hora_final', array( 'label' => 'Hora final:', 'onkeypress' => 'mascara(this, hora)', 'maxlength' => 5, )); $this->getElement('hora_final')->removeDecorator('Label'); $this->addElement('submit', 'btn_filtrar', array( 'label' => 'Buscar', 'class' => 'bt_find' )); } public function isValid($data) { $valid = parent::isValid($data); if (empty($data)){ $valid = false; $helper = Zend_Controller_Action_HelperBroker::getStaticHelper(); $helper->flashMessenger(array('alert' => 'Você deve informar ao menos um filtro.')); } return $valid; } }
💾 保存文件
← 返回文件管理器