public function postEdittask() { $basictask = BasicTask::find(Input::get('id')); $cause = RefFailureCause::where('id', '!=', $basictask->cause_id)->where('active', '=', 1)->where('project_id', '=', Session::get('project_id'))->get(); $type = RefTaskType::where('id', '!=', $basictask->type_id)->where('active', '=', 1)->where('project_id', '=', Session::get('project_id'))->get(); $list = RefTaskList::where('id', '!=', $basictask->list_id)->where('active', '=', 1)->where('project_id', '=', Session::get('project_id'))->get(); $basic = BasicTask::with('tasklist', 'cause', 'type')->where('id', '=', Input::get('id'))->where('active', '=', 1)->where('project_id', '=', Session::get('project_id'))->get(); return View::make('basic_data_setup.task.edit')->with('basics', $basic)->with('types', $type)->with('lists', $list)->with('causes', $cause); }