1686817401a:1:{s:18:"staff/contents.htm";a:10:{s:8:"fileName";s:18:"staff/contents.htm";s:7:"content";s:1481:"title = "Content List"
url = "/staff/contents/:slug"
layout = "staff"
is_hidden = 0

[contentType]
slug="{{ :slug }}"

==
<?php
    use Levaral\StaffContentManagement\Models\StaffContentManagementContent;
    use Levaral\StaffContentManagement\Models\StaffContentManagementType;

    function onStart()
    {
        if(!$this->user){
            return redirect('/staff/login');
        }

    }

    function onEnd()
    {
        $this['content_type_id'] = null;
        if(!isset($this->contentType) || !$this->contentType){
            return redirect('/staff/management');
        }

        if(isset($this->contentType) && $this->contentType){
            $this->page['title']= $this->contentType->title;
            $this['content_type_id'] = $this->contentType->id;
        }
        $this->prepareVars();
    }

    function onLoadMoreFeeds() {
        $this->prepareVars();
    }

    function prepareVars() {
        $options = post('Filter', [
         'page' => 1,
         'content_type_id' => $this['content_type_id']
        ]);
        $this['contentList'] = StaffContentManagementContent::listFrontEnd($options);
        $this['pageNumber'] =  $this['contentList']->currentPage() + 1;
        $this['lastPage'] = $this['contentList']->lastPage();
        $this['content_type_id'] = $options['content_type_id'];
    }
?>
==

{% if contentType.slug == 'staff-notices' %}
    {% partial 'staff/notices' %}
{% else %}
    {% partial 'staff/circulars' %}
{% endif %}
";s:5:"mtime";i:1547717801;s:6:"markup";s:137:"{% if contentType.slug == 'staff-notices' %}
    {% partial 'staff/notices' %}
{% else %}
    {% partial 'staff/circulars' %}
{% endif %}";s:4:"code";s:1207:"    use Levaral\StaffContentManagement\Models\StaffContentManagementContent;
    use Levaral\StaffContentManagement\Models\StaffContentManagementType;

    function onStart()
    {
        if(!$this->user){
            return redirect('/staff/login');
        }

    }

    function onEnd()
    {
        $this['content_type_id'] = null;
        if(!isset($this->contentType) || !$this->contentType){
            return redirect('/staff/management');
        }

        if(isset($this->contentType) && $this->contentType){
            $this->page['title']= $this->contentType->title;
            $this['content_type_id'] = $this->contentType->id;
        }
        $this->prepareVars();
    }

    function onLoadMoreFeeds() {
        $this->prepareVars();
    }

    function prepareVars() {
        $options = post('Filter', [
         'page' => 1,
         'content_type_id' => $this['content_type_id']
        ]);
        $this['contentList'] = StaffContentManagementContent::listFrontEnd($options);
        $this['pageNumber'] =  $this['contentList']->currentPage() + 1;
        $this['lastPage'] = $this['contentList']->lastPage();
        $this['content_type_id'] = $options['content_type_id'];
    }";s:5:"title";s:12:"Content List";s:3:"url";s:21:"/staff/contents/:slug";s:6:"layout";s:5:"staff";s:9:"is_hidden";s:1:"0";s:11:"contentType";a:1:{s:4:"slug";s:11:"{{ :slug }}";}}}