mirror of
https://github.com/snipe/snipe-it.git
synced 2025-03-05 20:52:15 -08:00
parent
f5ba2106cd
commit
876ff2ef72
|
@ -235,8 +235,12 @@ class LicensesController extends Controller
|
||||||
}
|
}
|
||||||
|
|
||||||
$order = $request->input('order') === 'asc' ? 'asc' : 'desc';
|
$order = $request->input('order') === 'asc' ? 'asc' : 'desc';
|
||||||
|
|
||||||
$total = $seats->count();
|
$total = $seats->count();
|
||||||
|
|
||||||
|
if($total < $offset){
|
||||||
|
$offset = 0;
|
||||||
|
}
|
||||||
|
|
||||||
$seats = $seats->skip($offset)->take($limit)->get();
|
$seats = $seats->skip($offset)->take($limit)->get();
|
||||||
|
|
||||||
if ($seats) {
|
if ($seats) {
|
||||||
|
|
Loading…
Reference in a new issue