From a4019c9f632c27a2cf2d66138f0eade75027d555 Mon Sep 17 00:00:00 2001 From: snipe Date: Wed, 1 Aug 2018 14:18:37 -0700 Subject: [PATCH] NIcer UI for activated user + email credentials --- resources/lang/en/admin/users/general.php | 1 + resources/views/users/edit.blade.php | 61 +++++++++++++---------- 2 files changed, 37 insertions(+), 25 deletions(-) diff --git a/resources/lang/en/admin/users/general.php b/resources/lang/en/admin/users/general.php index 2dc8bb31ab..ac4f652025 100644 --- a/resources/lang/en/admin/users/general.php +++ b/resources/lang/en/admin/users/general.php @@ -19,6 +19,7 @@ return array( 'ldap_config_text' => 'LDAP configuration settings can be found Admin > Settings. The (optional) selected location will be set for all imported users.', 'print_assigned' => 'Print All Assigned', 'software_user' => 'Software Checked out to :name', + 'send_email_help' => 'You must provide an email address for this user to send them credentials. Emailing credentials can only be done on user creation. Passwords are stored in a one-way hash and cannot be retrieved once saved.', 'view_user' => 'View User :name', 'usercsv' => 'CSV file', 'two_factor_admin_optin_help' => 'Your current admin settings allow selective enforcement of two-factor authentication. ', diff --git a/resources/views/users/edit.blade.php b/resources/views/users/edit.blade.php index 523095bf65..04c532e623 100755 --- a/resources/views/users/edit.blade.php +++ b/resources/views/users/edit.blade.php @@ -335,14 +335,14 @@

{{ trans('general.feature_disabled') }}

@elseif ($user->id === Auth::user()->id) -
+
{{ Form::checkbox('activated', '1', old('activated', $user->activated),['class' => 'minimal', 'disabled'=>'disabled']) }} {{ trans('admin/users/general.activated_help_text') }}

{{ trans('admin/users/general.activated_disabled_help_text') }}

@else
- {{ Form::checkbox('activated', '1', old('activated', $user->activated),['class' => 'minimal' ]) }} + {{ Form::checkbox('activated', '1', old('activated', $user->activated),['class' => 'minimal', 'id' => 'user_activated' ]) }} {{ trans('admin/users/general.activated_help_text') }}
@endif @@ -353,6 +353,26 @@
+ + @if (!$user->id) + + @endif + @if ($snipeSettings->two_factor_enabled!='') @if ($snipeSettings->two_factor_enabled=='1')
@@ -443,21 +463,6 @@
- - @if (!$user->id) -
-
-
-
-
- -
-
-
- @endif @@ -587,18 +592,24 @@