<?php
/**
 * @copyright   Copyright (c) 2017 https://www.sapixx.com All rights reserved.
 * @license     Licensed (http://www.apache.org/licenses/LICENSE-2.0).
 * @author      pillar<ltmn@qq.com>
 * 文章内容
 */
namespace app\smartbc\controller\home;
use app\common\controller\Api;
use app\smartbc\model\SmartbcConfig;

class Article extends Api{

    /**
     * 服务协议
     * @return void
     */
    public function sla(){
        $info = SmartbcConfig::getConfig($this->miniapp_id);
        if(empty($info)){
            $this->error('资源不存在');
        }
        $view['title'] = '服务协议';
        $view['sla']   = $info->sla;
        $this->view->engine->layout(false);
        return view('home/article/rules')->assign($view);
    }
}