Added filter by status type

This commit is contained in:
snipe 2016-08-23 15:51:59 -07:00
parent 11dc20de61
commit 85f3e7e3d4

View file

@ -1588,7 +1588,7 @@ class AssetsController extends Controller
* @since [v2.0]
* @return String JSON
*/
public function getDatatable($status = null)
public function getDatatable(Request $request, $status = null, $status_id = null)
{
@ -1640,6 +1640,12 @@ class AssetsController extends Controller
}
if ($request->has('status_id')) {
$assets->where('status_id','=', e($request->get('status_id')));
}
$allowed_columns = [
'id',
'name',