public function index()
 {
     $usertype = Cookie::get('usertype');
     if ($usertype === 'Manager') {
         $user = new UserModel();
         $teacher = new TeacherModel();
         $course = new CourseModel();
         $school = new SchoolModel();
         $userlist = $user->select();
         $teacherlist = $teacher->select();
         $courselist = $course->select();
         $schoollist = $school->select();
         $username = Cookie::get('username');
         $usertype = Cookie::get('usertype');
         $lastlogintime = Cookie::get('lastlogintime');
         $this->assign('userlist', $userlist);
         $this->assign('teacherlist', $teacherlist);
         $this->assign('courselist', $courselist);
         $this->assign('schoollist', $schoollist);
         $this->assign('username', $username);
         $this->assign('usertype', $usertype);
         $this->assign('lastlogintime', $lastlogintime);
         $this->display();
     } elseif ($usertype === 'teacher') {
         $this->assign("jumpUrl", "__APP__/Teacher/login");
     } else {
         $this->assign("jumpUrl", "__APP__/Index/index");
         $this->success("正在转向首页");
     }
 }
 public function test()
 {
     $course = new CourseModel();
     $school = new SchoolModel();
     $courselist = $course->select();
     $schoollist = $school->select();
     $this->assign('schoollist', $schoollist);
     $this->assign('courselist', $courselist);
     $this->display();
 }