當前位置: 首頁>>代碼示例>>PHP>>正文


PHP View::setData方法代碼示例

本文整理匯總了PHP中View::setData方法的典型用法代碼示例。如果您正苦於以下問題:PHP View::setData方法的具體用法?PHP View::setData怎麽用?PHP View::setData使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在View的用法示例。


在下文中一共展示了View::setData方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: index

 public function index()
 {
     //        if (!isset($_GET['p'])) {
     //            $_GET['p'] = 1;
     //        }
     //        if (!isset($_GET['q'])) {
     //            $_GET['q'] = "";
     //        }
     //        if (!isset($_GET['criterio'])) {
     //            $_GET['criterio'] = "detalle_asignacion_tutoria.CodigoSemestre";
     //        }
     //         $obj = new asignaciontutoria();
     //        $data = array();
     //        $data['data'] = $obj->index($_GET['q'], $_GET['p'], $_GET['criterio']);
     //        $data['query'] = $_GET['q'];
     //        $data['pag'] = $this->Pagination(array('rows' => $data['data']['rowspag'], 'url' => 'index.php?controller=alumno&action=index', 'query' => $_GET['q']));
     //        $cols = array("CODIGO", "Docente");
     //         $opt = array("" => "------","CodigoSemestre" => "Semestre");
     //
     //         $data['facultades'] = $this->Select(array('id' => 'CodigoFacultad', 'name' => 'CodigoFacultad', 'table' => 'facultades', 'code' => $obj->CodigoFacultad));
     //         $data['semestreacademico'] = $this->SelectActual(array('id' => 'CodigoSemestre', 'name' => 'CodigoSemestre', 'table' => 'semestreacademico', 'code' => $obj->CodigoSemestre));
     $data['contenido'] = $this->grilla_informativo();
     //        $data['grilla'] = $this->grilla("asignaciontutoria", $cols, $data['data']['rows'], $data['pag'], false, false);
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/contenido/_Index.php');
     $view->setLayout('../template/LayoutInformativo.php');
     $view->render();
 }
開發者ID:AnthonyWainer,項目名稱:sisacreditacion,代碼行數:29,代碼來源:contenidoController.php

示例2: index

 public function index()
 {
     if (!isset($_GET['p'])) {
         $_GET['p'] = 1;
     }
     if (!isset($_GET['q'])) {
         $_GET['q'] = "";
     }
     if (!isset($_GET['criterio'])) {
         $_GET['criterio'] = "evento.tema";
     }
     $obj = new eventoT();
     $data = array();
     $semestre_ultimo = $this->mostrar_semestre_ultimo();
     if ($_SESSION['cargo'] == 'Presidente' && $_SESSION['comicion'] == 'COMISION ESPECIAL DE TUTORIA') {
         $presidente = true;
     }
     $data['data'] = $obj->index($_GET['q'], $_GET['p'], $_GET['criterio'], $semestre_ultimo, $_SESSION['idusuario']);
     $data['query'] = $_GET['q'];
     $cols = array("CODIGO", "Tema", "Tipo Evento", "Fecha", "Hora");
     $opt = array("evento.Tema" => "Tema", "evento.fecha" => "Fecha ", "evento.hora" => "Hora");
     $data['grilla'] = $this->grilla("eventoT", $cols, $data['data']['rows'], $opt, $data['pag'], FALSE, FALSE, false, false, false, false, $presidente);
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/eventoT/_Index.php');
     $view->setLayout('../template/Layout3.php');
     $view->render();
 }
開發者ID:AnthonyWainer,項目名稱:sisacreditacion,代碼行數:28,代碼來源:eventoTController.php

示例3: actionGetAllNews

 public function actionGetAllNews()
 {
     $news = DBModel::getDB()->getAllNews();
     $view = new View();
     $view->setData($news);
     echo $view->render("main.php");
 }
開發者ID:ramiknexus7,項目名稱:news,代碼行數:7,代碼來源:NewsController.php

示例4: index

 public function index()
 {
     if (!isset($_GET['p'])) {
         $_GET['p'] = 1;
     }
     if (!isset($_GET['q'])) {
         $_GET['q'] = "";
     }
     if (!isset($_GET['criterio'])) {
         $_GET['criterio'] = "descripcion";
     }
     $obj = new plancursos();
     $data = array();
     $data['data'] = $obj->index($_GET['q'], $_GET['p'], $_GET['criterio']);
     //SI EXISTE CRITERIO QUE BUSQUE
     $data['query'] = $_GET['q'];
     $data['pag'] = $this->Pagination(array('rows' => $data['data']['rowspag'], 'url' => 'index.php?controller=plancursos&action=index', 'query' => $_GET['q']));
     $cols = array("CODIGO", "Curso", "HP", "HT", "ESCUELA", "FACULTAD");
     //CABECERA DE LOS CAMPOS DE GRILLA
     $opt = array("idplan" => "CODIGO PLAN");
     //BUSQUEDA DE CAMPOS
     $data['plancurricular'] = $this->Select(array('id' => 'CodigoPlan', 'name' => 'CodigoPlan', 'table' => 'v_plan', 'code' => $obj->CodigoPlan));
     $data['grilla'] = $this->grilla("plancursos", $cols, $data['data']['rows'], $opt, $data['pag'], true, true);
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/plancursos/_Index.php');
     $view->setLayout('../template/Layout.php');
     $view->render();
 }
開發者ID:AnthonyWainer,項目名稱:sisacreditacion,代碼行數:29,代碼來源:plancursosController.php

示例5: save

 public function save()
 {
     $obj = new asistenciaalumno();
     if ($_POST['identificador_editar'] == true) {
         $p = $obj->update($_POST);
         if ($p[0]) {
             die("<script> window.location='index.php?controller=asistenciaalumno'; </script>");
         } else {
             $data = array();
             $view = new View();
             $data['msg'] = $p[1];
             $data['url'] = 'index.php?controller=asistenciaalumno';
             $view->setData($data);
             $view->setTemplate('../view/_Error_App.php');
             $view->setLayout('../template/Layout.php');
             $view->render();
         }
     } else {
         $p = $obj->insert($_POST);
         if ($p[0]) {
             header('Location:index.php?controller=asistenciaalumno');
         } else {
             $data = array();
             $view = new View();
             $data['msg'] = $p[1];
             $data['url'] = 'index.php?controller=asistenciaalumno';
             $view->setData($data);
             $view->setTemplate('../view/_Error_App.php');
             $view->setLayout('../template/Layout.php');
             $view->render();
         }
     }
 }
開發者ID:ewo1991,項目名稱:sisacreditacion,代碼行數:33,代碼來源:asistenciaalumnoController.php

示例6: index

 public function index()
 {
     $data['semestreacademico'] = $this->cinco_ultimos_semestres(array('id' => 'CodigoSemestre', 'name' => 'CodigoSemestre', 'table' => 'semestreacademico', 'code' => $obj->CodigoSemestre));
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/misasistenciasAlumno/_Index.php');
     $view->setLayout('../template/Layout.php');
     $view->render();
 }
開發者ID:ewo1991,項目名稱:sisacreditacion,代碼行數:9,代碼來源:misasistenciasAlumnoController.php

示例7: index

 public function index()
 {
     $data = array();
     $data['semestreacademico'] = $this->Select1(array('id' => 'semestreacademico', 'name' => 'semestreacademico', 'filtro' => $_SESSION['idusuario']));
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/alumnoproyecto/_Index.php');
     $view->setLayout('../template/Layout.php');
     $view->render();
 }
開發者ID:ewo1991,項目名稱:sisacreditacion,代碼行數:10,代碼來源:alumnoproyectosController.php

示例8: orror

 public function orror()
 {
     $data = array();
     $data['str'] = $_GET['str'];
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/_ErrorConexion.php');
     $view->setLayout('../template/Layout.php');
     $view->render();
 }
開發者ID:AnthonyWainer,項目名稱:sisacreditacion,代碼行數:10,代碼來源:BaseDatosController.php

示例9: index

 public function index()
 {
     $data = array();
     $data['sucursal'] = $this->Select(array('id' => 'idsucursal', 'name' => 'idsucursal', 'table' => 'sucursal'));
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/_seleccion.php');
     $view->setLayout('../template/Layout.php');
     $view->render();
 }
開發者ID:ewo1991,項目名稱:sisacreditacion,代碼行數:10,代碼來源:seleccionController.php

示例10: index

 public function index()
 {
     $obj = new reporteasistencias();
     $data = array();
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/reporteasistencias/_Index.php');
     $view->setLayout('../template/Layout.php');
     $view->render();
 }
開發者ID:ewo1991,項目名稱:sisacreditacion,代碼行數:10,代碼來源:reporteasistenciasController.php

示例11: verBiblio

 public function verBiblio($p)
 {
     $bib = new bibliografia();
     $data = array();
     $data['rows2'] = $bib->getBibliografia($_POST);
     $data['rows5'] = $bib->getTipoBibliografia();
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/bibliografia/_biblio.php');
     echo $view->renderPartial();
 }
開發者ID:AnthonyWainer,項目名稱:sisacreditacion,代碼行數:11,代碼來源:bibliografiaController.php

示例12: Modulos

 public function Modulos()
 {
     $data = array();
     $objpermisos = new Permisos();
     $data['mod'] = $objpermisos->Modulos($_GET['idperfil']);
     $data['idperfil'] = $_GET['idperfil'];
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/Permisos/_Modulos.php');
     echo $view->renderPartial();
 }
開發者ID:ewo1991,項目名稱:sisacreditacion,代碼行數:11,代碼來源:PermisosController.php

示例13: insertarDetalle_asistencia_alumnos

 public function insertarDetalle_asistencia_alumnos()
 {
     $obj = new solicitudes_ps();
     $obj->InsertDet_asistencia_alumnos($_REQUEST);
     header('Location: index.php?controller=solicitudes_ps');
     $data = array();
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/_Error_App.php');
     echo $view->renderPartial();
 }
開發者ID:AnthonyWainer,項目名稱:sisacreditacion,代碼行數:11,代碼來源:solicitudes_psController.php

示例14: Index

 public function Index()
 {
     $Index = new Index();
     $data = array();
     $data['html'] = $Index->index();
     $view = new View();
     $view->setData($data);
     $view->setTemplate('../view/_Index.php');
     $view->setLayout('../template/Layout.php');
     $view->render();
 }
開發者ID:AnthonyWainer,項目名稱:sisacreditacion,代碼行數:11,代碼來源:IndexController.php

示例15: save

 public function save()
 {
     $obj = new asistenciaalumnoGeneral();
     $p = $obj->update($_REQUEST['idevento'], $_REQUEST['codigoalumno'], $_SESSION['idusuario'], $_REQUEST['asistencia']);
     if ($p[0]) {
         die("<script> window.location='index.php?controller=asistenciaalumnoGeneral'; </script>");
     } else {
         $data = array();
         $view = new View();
         $data['msg'] = $p[1];
         $data['url'] = 'index.php?controller=asistenciaalumnoGeneral';
         $view->setData($data);
         $view->setTemplate('../view/_Error_App.php');
         $view->setLayout('../template/Layout3.php');
         $view->render();
     }
 }
開發者ID:AnthonyWainer,項目名稱:sisacreditacion,代碼行數:17,代碼來源:asistenciaalumnoGeneralController.php


注:本文中的View::setData方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。