diff --git a/.all-contributorsrc b/.all-contributorsrc index bc4231a02..8ea582b9b 100644 --- a/.all-contributorsrc +++ b/.all-contributorsrc @@ -3208,6 +3208,15 @@ "contributions": [ "code" ] + }, + { + "login": "swift2512", + "name": "swift2512", + "avatar_url": "https://avatars.githubusercontent.com/u/3755203?v=4", + "profile": "https://github.com/swift2512", + "contributions": [ + "bug" + ] } ] } diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index e7d0eac03..f821c1f17 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -52,7 +52,7 @@ Thanks goes to all of these wonderful people ([emoji key](https://github.com/ken | [
bilias](https://github.com/bilias)
[💻](https://github.com/snipe/snipe-it/commits?author=bilias "Code") | [
coach1988](https://github.com/coach1988)
[💻](https://github.com/snipe/snipe-it/commits?author=coach1988 "Code") | [
MrM](https://github.com/mauro-miatello)
[💻](https://github.com/snipe/snipe-it/commits?author=mauro-miatello "Code") | [
koiakoia](https://github.com/koiakoia)
[💻](https://github.com/snipe/snipe-it/commits?author=koiakoia "Code") | [
Mustafa Online](https://github.com/mustafa-online)
[💻](https://github.com/snipe/snipe-it/commits?author=mustafa-online "Code") | [
franceslui](https://github.com/franceslui)
[💻](https://github.com/snipe/snipe-it/commits?author=franceslui "Code") | [
Q4kK](https://github.com/Q4kK)
[💻](https://github.com/snipe/snipe-it/commits?author=Q4kK "Code") | | [
squintfox](https://github.com/squintfox)
[💻](https://github.com/snipe/snipe-it/commits?author=squintfox "Code") | [
Jeff Clay](https://github.com/jeffclay)
[💻](https://github.com/snipe/snipe-it/commits?author=jeffclay "Code") | [
Phil J R](https://github.com/PP-JN-RL)
[💻](https://github.com/snipe/snipe-it/commits?author=PP-JN-RL "Code") | [
i_virus](https://www.corelight.com/)
[💻](https://github.com/snipe/snipe-it/commits?author=chandanchowdhury "Code") | [
Paul Grime](https://github.com/gitgrimbo)
[💻](https://github.com/snipe/snipe-it/commits?author=gitgrimbo "Code") | [
Lee Porte](https://leeporte.co.uk)
[💻](https://github.com/snipe/snipe-it/commits?author=LeePorte "Code") | [
BRYAN ](https://github.com/bryanlopezinc)
[💻](https://github.com/snipe/snipe-it/commits?author=bryanlopezinc "Code") [⚠️](https://github.com/snipe/snipe-it/commits?author=bryanlopezinc "Tests") | | [
U-H-T](https://github.com/U-H-T)
[💻](https://github.com/snipe/snipe-it/commits?author=U-H-T "Code") | [
Matt Tyree](https://github.com/Tyree)
[📖](https://github.com/snipe/snipe-it/commits?author=Tyree "Documentation") | [
Florent Bervas](http://spoontux.net)
[💻](https://github.com/snipe/snipe-it/commits?author=FlorentDotMe "Code") | [
Daniel Albertsen](https://ditscheri.com)
[💻](https://github.com/snipe/snipe-it/commits?author=dbakan "Code") | [
r-xyz](https://github.com/r-xyz)
[💻](https://github.com/snipe/snipe-it/commits?author=r-xyz "Code") | [
Steven Mainor](https://github.com/DrekiDegga)
[💻](https://github.com/snipe/snipe-it/commits?author=DrekiDegga "Code") | [
arne-kroeger](https://github.com/arne-kroeger)
[💻](https://github.com/snipe/snipe-it/commits?author=arne-kroeger "Code") | -| [
Glukose1](https://github.com/Glukose1)
[💻](https://github.com/snipe/snipe-it/commits?author=Glukose1 "Code") | [
Scarzy](https://github.com/Scarzy)
[💻](https://github.com/snipe/snipe-it/commits?author=Scarzy "Code") | [
setpill](https://github.com/setpill)
[💻](https://github.com/snipe/snipe-it/commits?author=setpill "Code") | +| [
Glukose1](https://github.com/Glukose1)
[💻](https://github.com/snipe/snipe-it/commits?author=Glukose1 "Code") | [
Scarzy](https://github.com/Scarzy)
[💻](https://github.com/snipe/snipe-it/commits?author=Scarzy "Code") | [
setpill](https://github.com/setpill)
[💻](https://github.com/snipe/snipe-it/commits?author=setpill "Code") | [
swift2512](https://github.com/swift2512)
[🐛](https://github.com/snipe/snipe-it/issues?q=author%3Aswift2512 "Bug reports") | This project follows the [all-contributors](https://github.com/kentcdodds/all-contributors) specification. Contributions of any kind welcome! diff --git a/app/Http/Controllers/Users/BulkUsersController.php b/app/Http/Controllers/Users/BulkUsersController.php index 1a8f84b7a..12dc14e29 100644 --- a/app/Http/Controllers/Users/BulkUsersController.php +++ b/app/Http/Controllers/Users/BulkUsersController.php @@ -30,7 +30,7 @@ class BulkUsersController extends Controller * @author [A. Gianotto] [] * @since [v1.7] * @param Request $request - * @return \Illuminate\Contracts\View\View + * @return \Illuminate\Contracts\View\View | \Illuminate\Http\RedirectResponse * @throws \Illuminate\Auth\Access\AuthorizationException */ public function edit(Request $request) @@ -116,6 +116,8 @@ class BulkUsersController extends Controller ->conditionallyAddItem('remote') ->conditionallyAddItem('ldap_import') ->conditionallyAddItem('activated') + ->conditionallyAddItem('start_date') + ->conditionallyAddItem('end_date') ->conditionallyAddItem('autoassign_licenses'); @@ -146,7 +148,14 @@ class BulkUsersController extends Controller $this->update_array['company_id'] = null; } - + if ($request->input('null_start_date')=='1') { + $this->update_array['start_date'] = null; + } + + if ($request->input('null_end_date')=='1') { + $this->update_array['end_date'] = null; + } + if (! $manager_conflict) { $this->conditionallyAddItem('manager_id'); } diff --git a/resources/lang/en-US/general.php b/resources/lang/en-US/general.php index 4ebf1b897..309222867 100644 --- a/resources/lang/en-US/general.php +++ b/resources/lang/en-US/general.php @@ -419,7 +419,7 @@ return [ 'bulk_soft_delete' =>'Also soft-delete these users. Their asset history will remain intact unless/until you purge deleted records in the Admin Settings.', 'bulk_checkin_delete_success' => 'Your selected users have been deleted and their items have been checked in.', 'bulk_checkin_success' => 'The items for the selected users have been checked in.', - 'set_to_null' => 'Delete values for this asset|Delete values for all :asset_count assets ', + 'set_to_null' => 'Delete values for this selection|Delete values for all :selection_count selections ', 'set_users_field_to_null' => 'Delete :field values for this user|Delete :field values for all :user_count users ', 'na_no_purchase_date' => 'N/A - No purchase date provided', 'assets_by_status' => 'Assets by Status', diff --git a/resources/views/hardware/bulk.blade.php b/resources/views/hardware/bulk.blade.php index d36513e88..644637ff2 100755 --- a/resources/views/hardware/bulk.blade.php +++ b/resources/views/hardware/bulk.blade.php @@ -48,7 +48,7 @@
@@ -67,11 +67,11 @@
- +
@@ -86,7 +86,7 @@
@@ -189,7 +189,7 @@
diff --git a/resources/views/users/bulk-edit.blade.php b/resources/views/users/bulk-edit.blade.php index e1d3b4201..723503576 100644 --- a/resources/views/users/bulk-edit.blade.php +++ b/resources/views/users/bulk-edit.blade.php @@ -218,6 +218,43 @@
@endif + + + + +
+ +
+
+ + +
+ {!! $errors->first('start_date', ' :message') !!} +
+
+ +
+
+ + +
+ +
+
+ + +
+ {!! $errors->first('end_date', ' :message') !!} +
+
+ +