예제 #1
0
파일: Index.class.php 프로젝트: hhz1084/pyz
 public function __construct()
 {
     parent::__construct();
     if (Interceptor::isLogin()) {
         $this->location('/?m=main');
     }
 }
예제 #2
0
 public function __construct()
 {
     Interceptor::init();
     $this->tpl = new Smarty();
     $this->tpl->left_delimiter = '{{';
     $this->tpl->right_delimiter = '}}';
     $this->tpl->setTemplateDir(APP_PATH . 'smarty/template');
     $this->tpl->setCompileDir(APP_PATH . 'smarty/template_c');
     $this->tpl->setCacheDir(APP_PATH . 'smarty/cache');
 }
예제 #3
0
<?php

/**
 * Created by ?.
 * User: willian.manucello
 * Date: 10/8/2015
 * Time: 10:14 AM
 */
require_once 'core/loader/Loader.php';
$load = new Loader("view");
$load->interceptor();
$types = array('administrador', 'usuario', 'bolsista', 'orientador');
$interceptor = new Interceptor();
$interceptor->pages($types);
include 'app/view/header/header.php';
$load->service("Connection");
$load->service("ProcessorSystem");
$load->dao("SystemDao");
$processorS = new ProcessorSystem();
$time = $processorS->getTimeMonitors();
$info = "";
if (isset($_GET["info"])) {
    $info = $_GET["info"];
}
?>
<h3>Tabela de disponibilidade dos monitores para acompanhamento:</h3>
<table class="table table-bordered">
    <tr>
        <td style="width: 10%;">#</td>
        <td style="width: 18%;"><font size="4" color="#556b2f">Segunda</font></td>
        <td style="width: 18%;"><font size="4" color="#556b2f">Terça</font></td>
예제 #4
0
 function testInterceptor()
 {
     $interceptor = new Interceptor();
     $interceptor->clear();
     $options = new HessianOptions();
     $options->interceptors = array($interceptor);
     $options->version = $this->version;
     $this->proxy = new HessianClient($this->url, $options);
     $str = $this->proxy->testConcatString("hello", " hessianphp");
     $file = dirname(__FILE__) . '/logs/payload.bin';
     $this->assertTrue(file_exists($file));
 }
예제 #5
0
        break;
    case "registerAjax":
        $load->model("User");
        $userRegister = new User();
        $userRegister->setLogin(htmlspecialchars($_POST['login']));
        $load->dao("UserDao");
        $userDao = new UserDao();
        if ($userData = $userDao->getUserByLogin($userLogin->getLogin())) {
            echo "true";
        } else {
            exit;
        }
        break;
    default:
        $load->interceptor();
        $interceptor = new Interceptor();
        $interceptor->logout(false);
        $load->dao("SystemDao");
        $sysDao = new SystemDao();
        $system = $sysDao->getInfoSystem();
        $load->view("public", "index");
        break;
}
class ControllerPublic
{
    public function index($credentials = true)
    {
        if ($credentials) {
            header("location: ../../e-jbsm.php?credentials=true");
        } else {
            header("location: ../../e-jbsm.php");