本文整理汇总了PHP中ControllerBase::importarJsSearch方法的典型用法代码示例。如果您正苦于以下问题:PHP ControllerBase::importarJsSearch方法的具体用法?PHP ControllerBase::importarJsSearch怎么用?PHP ControllerBase::importarJsSearch使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ControllerBase
的用法示例。
在下文中一共展示了ControllerBase::importarJsSearch方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: buscarCCPorLineaAction
/**
* Searches for centrocosto
*/
public function buscarCCPorLineaAction($centroCosto_id)
{
parent::importarJsSearch();
$numberPage = 1;
$numberPage = $this->request->getQuery("page", "int");
$centrocosto = Centrocosto::find(array("centroCosto_lineaId=:linea_id: AND centroCosto_habilitado=1", 'bind' => array('linea_id' => $centroCosto_id)));
if (count($centrocosto) == 0) {
$this->flash->notice("No se encontraron resultados en la busqueda");
return $this->dispatcher->forward(array("controller" => "centrocosto", "action" => "index"));
}
$paginator = new Paginator(array("data" => $centrocosto, "limit" => 10000, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
$this->view->pick('centrocosto/search');
}
示例2: buscarLineaPorIdAction
/**
* Buscar la linea correspondiente a un ID enviado por GET
* @return bool
*/
public function buscarLineaPorIdAction()
{
if (!$this->request->isGet()) {
return $this->redireccionar('linea/index');
}
parent::importarJsSearch();
$numberPage = 1;
$numberPage = $this->request->getQuery("page", "int");
$linea = Linea::find(array('linea_id=:linea_id:', 'bind' => array('linea_id' => $this->request->get('linea_id')), 'order by' => 'linea_nombre ASC'));
if (count($linea) == 0) {
$this->flash->notice("No se encontraron resultados en la búsqueda");
return $this->dispatcher->forward(array("controller" => "linea", "action" => "index"));
}
$paginator = new Paginator(array("data" => $linea, "limit" => 10000, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
$this->view->pick('linea/search');
}
示例3: searchAction
/**
* Searches for archivo
*/
public function searchAction()
{
parent::importarJsSearch();
$numberPage = 1;
if ($this->request->isPost()) {
$query = Criteria::fromInput($this->di, "Archivo", $_POST);
$this->persistent->parameters = $query->getParams();
} else {
$numberPage = $this->request->getQuery("page", "int");
}
$parameters = $this->persistent->parameters;
if (!is_array($parameters)) {
$parameters = array();
}
$parameters["order"] = "archivo_id";
$archivo = Archivo::find($parameters);
if (count($archivo) == 0) {
$this->flash->notice("No se encontraron resultados");
return $this->dispatcher->forward(array("controller" => "archivo", "action" => "index"));
}
$paginator = new Paginator(array("data" => $archivo, "limit" => 10000, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
}
示例4: verOrdenesAction
public function verOrdenesAction($planillaId)
{
parent::importarJsSearch();
$numberPage = 1;
$orden = Orden::findByOrden_planillaId($planillaId);
if (count($orden) == 0) {
$this->flash->notice("La planilla seleccionada no contiene ordenes cargadas.");
return $this->dispatcher->forward(array("controller" => "planilla", "action" => "search"));
}
$tabla = $this->generarTablaDeOrdenes($orden);
$paginator = new Paginator(array("data" => $tabla, "limit" => 100000, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
$planilla = Planilla::findFirstByPlanilla_id($planillaId);
if ($planilla) {
$this->view->planilla = $planilla;
}
$this->view->pick('orden/search');
}