public function actionRepcomment()
 {
     if (Yii::$app->request->isPost || Yii::$app->request->isPjax) {
         $request = Yii::$app->request;
         if (!is_null(Yii::$app->request->post('action'))) {
             switch (Yii::$app->request->post('action')) {
                 case 'delete':
                     PostsService::deleteComment(PostsService::getPostById(Yii::$app->request->post('post_id')));
                     ScoreService::revokeScoresByElemId(Yii::$app->request->post('post_id'), components\EScoreElem::post_comment());
                     break;
                 case 'revoke':
                     ScoreService::revokeScoresByElemId(Yii::$app->request->post('post_id'), components\EScoreElem::post_comment());
                     break;
             }
         }
     }
     $data = ScoreService::getElementsByScoreType(components\EScoreType::report());
     $table = [];
     //die(var_dump($data));
     //$pagination = new Pagination(['totalCount' => count($data), 'pageSize'=>30]);
     foreach ($data as $var) {
         /* @var $var components\Score*/
         if ($var->getElementType() == components\EScoreElem::post_comment()) {
             $table[] = PostsService::getCommentById($var->getElementId());
         }
     }
     return $this->render('repcomment', ['comments' => $table]);
 }