@@ 23-27 (lines=5) @@ | ||
20 | { |
|
21 | if (! is_null($id)) { |
|
22 | $item = $model->getRepository()->find($id); |
|
23 | if (is_null($item) || ! $model->isEditable($item)) { |
|
24 | return new JsonResponse([ |
|
25 | 'message' => trans('lang.message.access_denied'), |
|
26 | ], 403); |
|
27 | } |
|
28 | ||
29 | return $model->fireEdit($id); |
|
30 | } |
@@ 28-32 (lines=5) @@ | ||
25 | { |
|
26 | if (! is_null($id)) { |
|
27 | $item = $model->getRepository()->find($id); |
|
28 | if (is_null($item) || ! $model->isEditable($item)) { |
|
29 | return new JsonResponse([ |
|
30 | 'message' => trans('lang.message.access_denied'), |
|
31 | ], 403); |
|
32 | } |
|
33 | ||
34 | $form = $model->fireEdit($id); |
|
35 | } else { |