@@ -100,9 +100,9 @@ |
||
| 100 | 100 | } |
| 101 | 101 | }); |
| 102 | 102 | }); |
| 103 | + } else { |
|
| 104 | + $latest->orWhere($columns, 'like', "%" . $criteria['search'] . "%"); |
|
| 103 | 105 | } |
| 104 | - else |
|
| 105 | - $latest->orWhere($columns, 'like', "%" . $criteria['search'] . "%"); |
|
| 106 | 106 | } |
| 107 | 107 | } |
| 108 | 108 | unset($criteria['search']); |
@@ -319,9 +319,10 @@ |
||
| 319 | 319 | } |
| 320 | 320 | |
| 321 | 321 | if ($entity) { |
| 322 | - if($appendEntity) |
|
| 323 | - return response()->json( ['status' => true, 'message' => __('repository-generator.success'), 'data' => $entity], |
|
| 322 | + if($appendEntity) { |
|
| 323 | + return response()->json( ['status' => true, 'message' => __('repository-generator.success'), 'data' => $entity], |
|
| 324 | 324 | JsonResponse::HTTP_OK); |
| 325 | + } |
|
| 325 | 326 | return response()->json(null, JsonResponse::HTTP_NO_CONTENT); |
| 326 | 327 | } |
| 327 | 328 | |