Easily update component status when editing incident. Closes #721

This commit is contained in:
James Brooks
2015-06-15 16:27:42 +01:00
parent d5c4561fd1
commit fa3b80e3af
2 changed files with 24 additions and 0 deletions

View File

@@ -323,6 +323,13 @@ class IncidentController extends AbstractController
->with('errors', $incident->getErrors());
}
$componentStatus = array_pull($incidentData, 'component_status');
if ($incident->component) {
$incident->component->update([
'status' => $componentStatus,
]);
}
segment_track('Dashboard', [
'event' => 'Edited Incident',
'success' => true,