/**
  * 收藏
  * @return string
  * @throws Exception
  */
 public function actionCollection()
 {
     $request = Yii::$app->request;
     if ($request->isAjax) {
         $session = Yii::$app->session;
         $testLibraryId = $request->post('testLibraryId');
         $user = $session->get('user');
         return Collection::saveOrDelete($user['userId'], $testLibraryId);
     } else {
         throw new Exception("非法提交");
     }
 }