diff --git a/resources/lang/en-US/admin/users/general.php b/resources/lang/en-US/admin/users/general.php index 1fb9e8502c..e04d2b7de0 100644 --- a/resources/lang/en-US/admin/users/general.php +++ b/resources/lang/en-US/admin/users/general.php @@ -15,7 +15,8 @@ return [ 'info' => 'Info', 'restore_user' => 'Click here to restore them.', 'last_login' => 'Last Login', - 'ldap_config_text' => 'LDAP configuration settings can be found Admin > Settings. The (optional) selected location will be set for all imported users.', + 'ldap_config_text' => 'The selected location will be set for ALL imported users. This will overwrite their existing location, and is an unusual use-case, so leaving this blank is typically best.', + 'ldap_sync_intro' => 'Click on the button below to manually sync your LDAP users. To learn more about configuring LDAP sync to run automatically, please see the documentation .', 'print_assigned' => 'Print All Assigned', 'email_assigned' => 'Email List of All Assigned', 'user_notified' => 'User has been emailed a list of their currently assigned items.', diff --git a/resources/lang/en-US/general.php b/resources/lang/en-US/general.php index 733577dd2c..4ffb22e048 100644 --- a/resources/lang/en-US/general.php +++ b/resources/lang/en-US/general.php @@ -618,6 +618,7 @@ return [ 'from' => 'From', 'by' => 'By', 'by_user' => 'By', + 'ldap_sync_location' => 'Sync All Users to This Location (Optional)', 'version' => 'Version', 'build' => 'build', 'use_cloned_image' => 'Clone image from original', diff --git a/resources/views/settings/general.blade.php b/resources/views/settings/general.blade.php index 6926bef235..3762cde739 100644 --- a/resources/views/settings/general.blade.php +++ b/resources/views/settings/general.blade.php @@ -34,7 +34,7 @@
- +
{{ trans('admin/settings/general.legends.scoping') }} diff --git a/resources/views/users/ldap.blade.php b/resources/views/users/ldap.blade.php index 555dc65829..d15bf2c3f4 100644 --- a/resources/views/users/ldap.blade.php +++ b/resources/views/users/ldap.blade.php @@ -16,7 +16,7 @@ @section('content')
-
+
@if ($snipeSettings->ldap_enabled == 0) {{ trans('admin/users/message.ldap_not_configured') }} @else @@ -24,13 +24,19 @@ {{csrf_field()}}
+ +
+ +

+ + {!! trans('admin/users/general.ldap_sync_intro', ['link' => 'https://snipe-it.readme.io/docs/ldap-sync#/']) !!} +

+
+
- -
- @include ('partials.forms.edit.location-select', ['translated_name' => trans('general.location'), 'fieldname' => 'location_id[]', 'multiple' => true]) -
+ @include ('partials.forms.edit.location-select', ['translated_name' => trans('general.ldap_sync_location'), 'help_text' => trans('admin/users/general.ldap_config_text'), 'fieldname' => 'location_id[]', 'multiple' => true])
-

- {{ trans('admin/users/general.ldap_config_text') }} -

-

{{ trans('admin/settings/general.ldap_settings_link') }}

+
diff --git a/routes/web/users.php b/routes/web/users.php index 06a210daa5..a8e252822a 100644 --- a/routes/web/users.php +++ b/routes/web/users.php @@ -2,6 +2,7 @@ use App\Http\Controllers\Users; use Illuminate\Support\Facades\Route; +use Tabuna\Breadcrumbs\Trail; // User Management @@ -13,7 +14,10 @@ Route::group(['prefix' => 'users', 'middleware' => ['auth']], function () { Users\LDAPImportController::class, 'create' ] - )->name('ldap/user'); + )->name('ldap/user') + ->breadcrumbs(fn (Trail $trail) => + $trail->parent('users.index') + ->push(trans('general.ldap_user_sync'), route('ldap/user')));; Route::post( 'ldap',