Create components from the dashboard
This commit is contained in:
@@ -11,8 +11,6 @@ class DashboardController extends Controller {
|
||||
|
||||
public function createIncidentAction() {
|
||||
$_incident = Input::get('incident');
|
||||
$_incident['user_id'] = Auth::user()->id;
|
||||
|
||||
$incident = Incident::create($_incident);
|
||||
|
||||
return Redirect::back()->with('incident', $incident);
|
||||
@@ -31,6 +29,13 @@ class DashboardController extends Controller {
|
||||
]);
|
||||
}
|
||||
|
||||
public function createComponentAction() {
|
||||
$_component = Input::get('component');
|
||||
$component = Component::create($_component);
|
||||
|
||||
return Redirect::back()->with('component', $component);
|
||||
}
|
||||
|
||||
/**
|
||||
* Shows the incidents view.
|
||||
* @return \Illuminate\View\View
|
||||
|
||||
Reference in New Issue
Block a user