public function __init() { parent::__init(); $this->status(); $this->project(); $this->hero(); }
/** * 构造函数 */ public function __init() { parent::__init(); $this->model = strtolower(MODULE); $existModel = \Model\ModelManage::findModel($this->model, 'model_name'); /** * 模型熟悉不为前台的 * 则提示模型不存在 */ if ($existModel['model_attr'] != '1') { $this->notfound(); } $this->modelInfo = $existModel; $this->assign('model', $this->model); }