コード例 #1
0
ファイル: ActivityRepository.php プロジェクト: sibasbo/sibas
 public function getActivities()
 {
     $selectOption = $this->getSelectOption();
     $activities = Activity::select('id', 'category', 'occupation')->orderBy('id', 'asc')->get();
     $activities = $selectOption->merge($activities->toArray());
     return $activities;
 }
コード例 #2
0
 /**
  * Remove the specified resource from storage.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function destroy($id)
 {
     \Sibas\Entities\Activity::where('id', $id)->delete();
     return redirect()->route('adActivitiesList')->with('delete', 'message');
 }