<?php

namespace app\admin\controller;

use app\admin\common\AdminController;

/**
 * Description of Login
 *
 * @author sgq
 */
class Index extends AdminController {

    public function index() {
        $vars["user"] = [
            "name" => $this->user["name"],
            "rolename" => $this->user["rolename"],
            "avatar" => $this->user["avatar"],
            "sex" => $this->user["sex"]
        ];
        $menus = \app\common\api\MenuApi::getMenuListByRoleid($this->user["roleid"]);
        $vars["menus"] = $menus;
        return view("", $vars);
    }

}
