mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/unity.git
synced 2026-08-20 12:54:07 +00:00
- follow the standard coding
This commit is contained in:
@@ -35,8 +35,7 @@ class EntityModule extends BaseController
|
||||
$page = $request->get('page', null);
|
||||
$limit = $request->get('limit', 10);
|
||||
|
||||
$status_default[] = config('constants.entity.status.active');
|
||||
|
||||
|
||||
$query = Entity::query();
|
||||
|
||||
if (strlen($name) > 0) {
|
||||
@@ -46,7 +45,7 @@ class EntityModule extends BaseController
|
||||
if (!empty($status) > 0) {
|
||||
$query->whereIn('status', $status);
|
||||
}else{
|
||||
$query->whereIn('status', $status_default);
|
||||
$query->whereIn('status', [config('constants.entity.status.active')]);
|
||||
}
|
||||
|
||||
$query->where('user_id', Auth::guard('user-api')->user()->id);
|
||||
|
||||
Reference in New Issue
Block a user