mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-10 23:54:12 -08:00
Merge remote-tracking branch 'origin/develop'
This commit is contained in:
commit
934f43e104
|
@ -62,7 +62,7 @@ class BulkUsersController extends Controller
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return redirect()->back()->with('error', 'No users selected');
|
return redirect()->back()->with('error', trans('general.no_users_selected'));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -79,7 +79,7 @@ class BulkUsersController extends Controller
|
||||||
$this->authorize('update', User::class);
|
$this->authorize('update', User::class);
|
||||||
|
|
||||||
if ((! $request->filled('ids')) || $request->input('ids') <= 0) {
|
if ((! $request->filled('ids')) || $request->input('ids') <= 0) {
|
||||||
return redirect()->back()->with('error', 'No users selected');
|
return redirect()->back()->with('error', trans('general.no_users_selected'));
|
||||||
}
|
}
|
||||||
$user_raw_array = $request->input('ids');
|
$user_raw_array = $request->input('ids');
|
||||||
|
|
||||||
|
@ -166,11 +166,11 @@ class BulkUsersController extends Controller
|
||||||
$this->authorize('update', User::class);
|
$this->authorize('update', User::class);
|
||||||
|
|
||||||
if ((! $request->filled('ids')) || (count($request->input('ids')) == 0)) {
|
if ((! $request->filled('ids')) || (count($request->input('ids')) == 0)) {
|
||||||
return redirect()->back()->with('error', 'No users selected');
|
return redirect()->back()->with('error', trans('general.no_users_selected'));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (config('app.lock_passwords')) {
|
if (config('app.lock_passwords')) {
|
||||||
return redirect()->route('users.index')->with('error', 'Bulk delete is not enabled in this installation');
|
return redirect()->route('users.index')->with('error', trans('general.feature_disabled'));
|
||||||
}
|
}
|
||||||
|
|
||||||
$user_raw_array = request('ids');
|
$user_raw_array = request('ids');
|
||||||
|
@ -266,6 +266,10 @@ class BulkUsersController extends Controller
|
||||||
{
|
{
|
||||||
$this->authorize('update', User::class);
|
$this->authorize('update', User::class);
|
||||||
|
|
||||||
|
if (config('app.lock_passwords')) {
|
||||||
|
return redirect()->route('users.index')->with('error', trans('general.feature_disabled'));
|
||||||
|
}
|
||||||
|
|
||||||
$user_ids_to_merge = $request->input('ids_to_merge');
|
$user_ids_to_merge = $request->input('ids_to_merge');
|
||||||
$user_ids_to_merge = array_diff($user_ids_to_merge, array($request->input('merge_into_id')));
|
$user_ids_to_merge = array_diff($user_ids_to_merge, array($request->input('merge_into_id')));
|
||||||
|
|
||||||
|
|
|
@ -110,7 +110,7 @@
|
||||||
</div> <!--/box-body-->
|
</div> <!--/box-body-->
|
||||||
<div class="box-footer text-right">
|
<div class="box-footer text-right">
|
||||||
<a class="btn btn-link pull-left" href="{{ URL::previous() }}">{{ trans('button.cancel') }}</a>
|
<a class="btn btn-link pull-left" href="{{ URL::previous() }}">{{ trans('button.cancel') }}</a>
|
||||||
<button type="submit" class="btn btn-success"><i class="fas fa-check icon-white" aria-hidden="true"></i> {{ trans('button.submit') }}</button>
|
<button type="submit" class="btn btn-success"{{ (config('app.lock_passwords') ? ' disabled' : '') }}><i class="fas fa-check icon-white" aria-hidden="true"></i> {{ trans('button.submit') }}</button>
|
||||||
</div><!-- /.box-footer -->
|
</div><!-- /.box-footer -->
|
||||||
|
|
||||||
@foreach ($users as $user)
|
@foreach ($users as $user)
|
||||||
|
|
Loading…
Reference in a new issue