Inline fields when updating
This commit is contained in:
parent
c5710b858e
commit
7862b74e99
1 changed files with 4 additions and 3 deletions
|
@ -58,9 +58,10 @@ class ReportTemplatesController extends Controller
|
||||||
// Ignore "options" rules since data does not come in under that key...
|
// Ignore "options" rules since data does not come in under that key...
|
||||||
$validated = $request->validate(Arr::except((new ReportTemplate)->getRules(), 'options'));
|
$validated = $request->validate(Arr::except((new ReportTemplate)->getRules(), 'options'));
|
||||||
|
|
||||||
$reportTemplate->name = $validated['name'];
|
$reportTemplate->update([
|
||||||
$reportTemplate->options = $request->except(['_token', 'name']);
|
'name' => $validated['name'],
|
||||||
$reportTemplate->save();
|
'options' => $request->except(['_token', 'name']),
|
||||||
|
]);
|
||||||
|
|
||||||
session()->flash('success', trans('admin/reports/message.update.success'));
|
session()->flash('success', trans('admin/reports/message.update.success'));
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue