Esempio n. 1
0
</head>

<body class="home" >

<!-- **Wrapper** -->
<div id="wrapper">

    <!-- **Header** -->
    <div id="header">
        <div class="container">

            <!-- **Logo** -->
            <div id="logo">
                <a href="/" title="">
                    <?php 
$logo = App\Content::whereType('logo')->orderBy('created_at', 'desc')->get()->first();
?>
                    @if(!empty($logo))
                         <img src="/uploads/logo/{{ $logo->logo }}" alt="" title="" />
                    @else
                        {!! HTML::image('images/logo_text-_white.png') !!}
                    @endif
                </a>
                <!--<a href="index.html"><h1 class="logo">Teleaus<span class="logo-h">></span></h1></a> -->
            </div><!-- **Logo - End** -->

            <div class="float-right">
                <!-- **Social icons** -->
                <div class="social-icons">
                    <a target="_blank" href="https://www.facebook.com/teleaus" title="" class="facebook"> </a>
                    <a target="_blank" href="https://twitter.com/teleaus" title="" class="twitter"> </a>
Esempio n. 2
0
<?php

// Redirect if does content not found
if (!($content = App\Content::where('seo_slug', \Route::input('slug'))->first())) {
    header('Location: ' . url('page/404'));
    die;
}
// Save visit
$request = \Request::instance();
$user = \Auth::user();
$visit = new App\Visit(['http_url' => $request->fullUrl(), 'http_method' => $request->method(), 'http_path' => $request->path(), 'ip' => $request->ip(), 'content_id' => $content->id, 'user_id' => empty($user) ? null : $user->id]);
$visit->save();
return ['content' => App\Content::where('seo_slug', \Route::input('slug'))->first()];
Esempio n. 3
0
 function create()
 {
     if (!empty($_POST)) {
         $_tree = model('WikiTree');
         $in['text'] = $_POST['title'];
         $id = intval($_GET['id']);
         if ($id == 0) {
             $in['pid'] = 0;
             $in['project_id'] = $_COOKIE['wiki_project_id'];
         } else {
             $cnode = $_tree->get($id)->get();
             //作为父页面
             if (isset($_GET['parent'])) {
                 $in['pid'] = $id;
             } else {
                 $in['pid'] = empty($cnode) ? 0 : $cnode['pid'];
             }
             if (!empty($_POST['link'])) {
                 $in['link'] = trim($_POST['link']);
             }
             $in['project_id'] = $cnode['project_id'];
         }
         $_POST['id'] = $_tree->put($in);
         App\Content::newPage($_POST);
         $this->reflushPage('增加成功');
     } else {
         $form['comment'] = Swoole\Form::radio('close_comment', array('0' => '开启', '1' => '关闭'), 0, false, null, 'radio-inline');
         $form['order_by_time'] = Swoole\Form::radio('order_by_time', array('0' => '手工排序', '1' => '按添加时间自动排序'), 0, false, null, 'radio-inline');
         $this->swoole->tpl->assign("form", $form);
         $this->swoole->tpl->display("wiki/create.html");
     }
 }
Esempio n. 4
0
<?php

$events = array();
foreach (App\Content::with('event')->get() as $row) {
    if (!$row->event) {
        continue;
    }
    $events[] = array('id' => $row->id, 'title' => $row->title, 'url' => url($row->seo_slug), 'class' => 'event-info', 'start' => strtotime($row->event->start) . '000', 'end' => strtotime($row->event->end) . '000');
}
return ['json' => json_encode($events)];
Esempio n. 5
0
 function tree()
 {
     $this->swoole->tpl->assign("tree", json_encode(App\Content::getTree($this->project_id)));
     $this->swoole->tpl->display("wiki/tree.html");
 }
Esempio n. 6
0
                    @endif
                </div>
                @endforeach

            </div><!-- Layer Slider -->
        </div><!-- Layer Slider Container -->

    </div><!-- **Home Slider BG - End** -->
</div><!-- **Home Slider - End** -->

<!-- **Welcome Text** -->
<div class="welcome-text">
    <div class="container">
        <div class="text">
            <?php 
$text = App\Content::whereType('text')->orderBy('created_at', 'desc')->get()->first();
?>
            @if(!empty($text->title))
                <h1> {{ $text->title }}  </h1>
            @else
                <h1>DEVELOP OR PLAN WITH TELEAUS SOLUTIONS</h1>
            @endif
            @if(!empty($text->subtitle))
               <h4> {{ $text->subtitle }} </h4>
            @else
               <h4> Our people empowered by innovation </h4>
            @endif
        </div>
        <a href="/enquery" title="" class="button medium grey"> Contact Us </a>
    </div>
</div><!-- **Welcome Text End** -->
Esempio n. 7
0
<?php

return ['user' => \Auth::user(), 'brand' => App\Brand::where('active', 1)->first(), 'contents' => App\Content::all()];