/** * 所有菜单tree */ public function treeList() { $list = $this->find()->where(['status' => 1])->orderBy('sort')->asArray()->all(); return \common\helpers\Functions::list_to_tree_menu($list); }