本文整理汇总了PHP中ControllerBase::importarJsTable方法的典型用法代码示例。如果您正苦于以下问题:PHP ControllerBase::importarJsTable方法的具体用法?PHP ControllerBase::importarJsTable怎么用?PHP ControllerBase::importarJsTable使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ControllerBase
的用法示例。
在下文中一共展示了ControllerBase::importarJsTable方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: searchAction
/**
* Searches for equipopozo
*/
public function searchAction($yacimientoId = null)
{
parent::importarJsTable();
$numberPage = 1;
if ($yacimientoId != null) {
$equipopozo = Equipopozo::find(array('equipoPozo_yacimientoId=:yacimiento_id:', 'bind' => array('yacimiento_id' => $yacimientoId)));
} else {
if ($this->request->isPost()) {
//$query = parent::fromInput($this->di, 'Equipopozo', $this->request->getPost());
$query = Criteria::fromInput($this->di, "Equipopozo", $_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"] = "equipoPozo_id";
$equipopozo = Equipopozo::find($parameters);
}
if (count($equipopozo) == 0) {
$this->flash->notice("No se encontraron resultados en la busqueda");
return $this->dispatcher->forward(array("controller" => "equipopozo", "action" => "index"));
}
$paginator = new Paginator(array("data" => $equipopozo, "limit" => 25, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
}
示例2: searchAction
/**
* Buscando las planillas.
* SI el usuario tiene rol de administrador podra ver todas las planillas.
* Sino se veran las Habilitadas unicamente
*/
public function searchAction()
{
parent::importarJsTable();
$numberPage = 1;
if ($this->request->isPost()) {
$query = Criteria::fromInput($this->di, "Planilla", $_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"] = "planilla_id DESC";
$planilla = Planilla::find($parameters);
if (count($planilla) == 0) {
$this->flash->notice("No se encontraron resultados");
return $this->dispatcher->forward(array("controller" => "planilla", "action" => "index"));
}
$paginator = new Paginator(array("data" => $planilla, "limit" => 10000, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
$miSesion = $this->session->get('auth');
if ($miSesion['rol_nombre'] == 'ADMIN') {
$this->view->admin = 1;
} else {
$this->view->admin = 0;
}
}
示例3: searchAction
/**
* Searches for operadora
*/
public function searchAction($yacimientoId = null)
{
parent::importarJsTable();
$numberPage = 1;
if ($yacimientoId != null) {
$operadora = Operadora::find(array('operadora_yacimientoId=:yacimiento_id:', 'bind' => array('yacimiento_id' => $yacimientoId)));
} else {
if ($this->request->isPost()) {
$query = Criteria::fromInput($this->di, "Operadora", $_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"] = "operadora_id";
$operadora = Operadora::find($parameters);
}
if (count($operadora) == 0) {
$this->flash->notice("No se han encontrado resultados");
return $this->dispatcher->forward(array("controller" => "operadora", "action" => "index"));
}
$paginator = new Paginator(array("data" => $operadora, "limit" => 25, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
}
示例4: buscarLineasPorClienteAction
/**
* Busca todas las lineas de un cliente especifico. Se utiliza en las tablas.
*/
public function buscarLineasPorClienteAction($cliente_id)
{
parent::importarJsTable();
$numberPage = 1;
$numberPage = $this->request->getQuery("page", "int");
$linea = Linea::find(array('linea_clienteId=:cliente_id: AND linea_habilitado=1', 'bind' => array('cliente_id' => $cliente_id), 'order by' => 'linea_nombre ASC'));
if (count($linea) == 0) {
$this->flash->notice("No se encontraron resultados en la busqueda");
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');
}
示例5: searchAction
/**
* Searches for concatenado
*/
public function searchAction()
{
parent::importarJsTable();
$numberPage = 1;
if ($this->request->isPost()) {
$query = Criteria::fromInput($this->di, "Concatenado", $_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"] = "concatenado_id";
$concatenado = Concatenado::find($parameters);
if (count($concatenado) == 0) {
$this->flash->notice("La búsqueda no encontró ningún resultado");
return $this->dispatcher->forward(array("controller" => "concatenado", "action" => "index"));
}
$paginator = new Paginator(array("data" => $concatenado, "limit" => 10000, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
}
示例6: searchAction
/**
* Searches for cliente
*/
public function searchAction()
{
parent::importarJsTable();
$numberPage = 1;
if ($this->request->isPost()) {
$query = Criteria::fromInput($this->di, "Cliente", $_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"] = "cliente_id";
$cliente = Cliente::find($parameters);
if (count($cliente) == 0) {
$this->flash->notice("The search did not find any cliente");
return $this->dispatcher->forward(array("controller" => "cliente", "action" => "index"));
}
$paginator = new Paginator(array("data" => $cliente, "limit" => 30, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
}
示例7: searchAction
/**
* Searches for tipoEquipo
*/
public function searchAction()
{
parent::importarJsTable();
$numberPage = 1;
if ($this->request->isPost()) {
$query = Criteria::fromInput($this->di, "Tipoequipo", $_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"] = "tipoEquipo_id";
$tipoEquipo = Tipoequipo::find($parameters);
if (count($tipoEquipo) == 0) {
$this->flash->notice("No se encontraron registros");
return $this->dispatcher->forward(array("controller" => "tipoequipo", "action" => "index"));
}
$paginator = new Paginator(array("data" => $tipoEquipo, "limit" => 10000, "page" => $numberPage));
$this->view->page = $paginator->getPaginate();
}
示例8: searchAction
/**
* Searches for orden
*/
public function searchAction()
{
parent::importarJsTable();
$numberPage = 1;
if ($this->request->isPost()) {
$buscarOrden = $this->generarCriterioBusqueda($_POST);
$query = Criteria::fromInput($this->di, "Orden", $buscarOrden);
$this->persistent->parameters = $query->getParams();
} else {
$numberPage = $this->request->getQuery("page", "int");
}
$parameters = $this->persistent->parameters;
if (!is_array($parameters)) {
$parameters = array();
}
$parameters["order"] = "orden_id";
$orden = Orden::find($parameters);
if (count($orden) == 0) {
$this->flash->notice("No se han encontrado resultados.");
return $this->dispatcher->forward(array("controller" => "orden", "action" => "index"));
}
$tabla = $this->generarTablaDeOrdenes($orden);
$paginator = new Paginator(array("data" => $tabla, "limit" => 100000, "page" => $numberPage));
$planilla = Planilla::findFirstByPlanilla_id($tabla[0]['orden_planillaId']);
if ($planilla) {
$this->view->planilla = $planilla;
}
$this->view->page = $paginator->getPaginate();
}