Add ability to edit account owner first and last names (#669)

This commit is contained in:
Régis Freyd
2017-11-30 21:00:09 -05:00
committed by GitHub
parent 7e367d67da
commit eb05b61b91
5 changed files with 23 additions and 3 deletions
@@ -40,6 +40,8 @@ class SettingsController extends Controller
{
$request->user()->update(
$request->only([
'first_name',
'last_name',
'email',
'timezone',
'locale',
@@ -79,6 +81,10 @@ class SettingsController extends Controller
$account->offpsrings->each->forceDelete();
$account->relationships->each->forceDelete();
$account->progenitors->each->forceDelete();
$account->contactFields->each->forceDelete();
$account->contactFieldTypes->each->forceDelete();
$account->calls->each->forceDelete();
$account->activityStatistics->each->forceDelete();
$account->forceDelete();
}
@@ -113,6 +119,10 @@ class SettingsController extends Controller
$account->offpsrings->each->forceDelete();
$account->relationships->each->forceDelete();
$account->progenitors->each->forceDelete();
$account->contactFields->each->forceDelete();
$account->contactFieldTypes->each->forceDelete();
$account->activityStatistics->each->forceDelete();
$account->calls->each->forceDelete();
}
return redirect('/settings')