コード例 #1
0
ファイル: actions.class.php プロジェクト: sgrove/cothinker
 public function executeVote()
 {
     $feature = SuggestedFeaturePeer::retrieveByUuid($this->getRequestParameter('feature'));
     $this->forward404Unless($feature, 'Feature not found, unable to vote');
     if ($this->getUser()->isAuthenticated()) {
         $feature->recommend($this->getUser()->getId());
         $feature->getsfGuardUser()->getProfile()->addKarma(sfConfig::get('app_karma_vote_feature_points'));
     }
     $this->feature = $feature;
 }