mirror of
https://github.com/snipe/snipe-it.git
synced 2025-01-12 06:17:28 -08:00
adds a checkbox to exclude archived assets from custom reports
This commit is contained in:
parent
78d5c37267
commit
75844c5942
|
@ -642,6 +642,9 @@ class ReportsController extends Controller
|
|||
if (($request->filled('next_audit_start')) && ($request->filled('next_audit_end'))) {
|
||||
$assets->whereBetween('assets.next_audit_date', [$request->input('next_audit_start'), $request->input('next_audit_end')]);
|
||||
}
|
||||
if($request->filled('exclude_archived')){
|
||||
$assets->where('archived', '=', 0);
|
||||
}
|
||||
$assets->orderBy('assets.id', 'ASC')->chunk(20, function ($assets) use ($handle, $customfields, $request) {
|
||||
|
||||
$executionTime = microtime(true) - $_SERVER['REQUEST_TIME_FLOAT'];
|
||||
|
|
|
@ -101,6 +101,7 @@ return [
|
|||
'employee_number' => 'Employee Number',
|
||||
'email_domain_help' => 'This is used to generate email addresses when importing',
|
||||
'error' => 'Error',
|
||||
'exclude_archived' => 'Exclude Archived Assets',
|
||||
'example' => 'Example: ',
|
||||
'filastname_format' => 'First Initial Last Name (jsmith@example.com)',
|
||||
'firstname_lastname_format' => 'First Name Last Name (jane.smith@example.com)',
|
||||
|
|
|
@ -340,11 +340,14 @@
|
|||
</div>
|
||||
|
||||
<div class="col-md-9 col-md-offset-3">
|
||||
<label>
|
||||
{{ Form::checkbox('exclude_archived', '1') }}
|
||||
{{ trans('general.exclude_archived') }}
|
||||
</label>
|
||||
<label>
|
||||
{{ Form::checkbox('use_bom', '1') }}
|
||||
{{ trans('general.bom_remark') }}
|
||||
</label>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
Loading…
Reference in a new issue