Beispiel #1
0
 private function changeIsreview($repid)
 {
     $report = Report::model()->fetchByPk($repid);
     if (!empty($report) && UserUtil::checkIsUpUid($report["uid"], Ibos::app()->user->uid)) {
         if ($report["stamp"] == 0) {
             $stamp = $this->getAutoReviewStamp();
             Report::model()->modify($repid, array("isreview" => 1, "stamp" => $stamp));
             ReportStats::model()->scoreReport($report["repid"], $report["uid"], $stamp);
         } else {
             Report::model()->modify($repid, array("isreview" => 1));
         }
     }
 }
Beispiel #2
0
 private function changeIsreview($diaryid)
 {
     $diary = Diary::model()->fetchByPk($diaryid);
     if (!empty($diary) && UserUtil::checkIsUpUid($diary["uid"], Ibos::app()->user->uid)) {
         if ($diary["stamp"] == 0) {
             $stamp = $this->getAutoReviewStamp();
             Diary::model()->modify($diaryid, array("isreview" => 1, "stamp" => $stamp));
             DiaryStats::model()->scoreDiary($diary["diaryid"], $diary["uid"], $stamp);
         } else {
             Diary::model()->modify($diaryid, array("isreview" => 1));
         }
     }
 }