<?php
/**
 * Created by PhpStorm.
 * User: xmy 280564871@qq.com
 * Date: 2017/4/19
 * Time: 13:47
 */

namespace Open\Controller;


use Open\Model\DocumentModel;

class DocumentController extends BaseController{

	public function _initialize()
	{
		$this->assign("title_head","document");
		parent::_initialize(); // TODO: Change the autogenerated stub
	}

	public function index($id=0){
		$model = new DocumentModel();
		$data = $model->getLeftLists();
		$content = $model->getContent($id);
		!empty($id) || $content = $model->getDetailByName("New");
		$this->assign("content",$content);
		$this->assign("data",$data);
		$this->display();
	}
}