/**
  * @param $entry
  * @param $token
  */
 private function createNewActivationForEntry($entry, $token)
 {
     $activation = new Activation();
     $activation->code = $token;
     $activation->entry_id = $entry->id;
     $activation->completed = 0;
     $activation->save();
 }
示例#2
0
 private function markActivationAsCompleted($token, $entry)
 {
     $activation = Activation::where('code', $token)->whereEntryId($entry->id)->first();
     $activation->completed = 1;
     $activation->save();
 }