From ae505ef44ddb3217874e78ee45dae1b424346d3c Mon Sep 17 00:00:00 2001 From: snipe Date: Wed, 31 Aug 2022 19:20:35 -0700 Subject: [PATCH 01/18] Literally have no idea how this ever worked Signed-off-by: snipe --- app/Http/Controllers/ReportsController.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/Http/Controllers/ReportsController.php b/app/Http/Controllers/ReportsController.php index 57dd87d813..c2e5ad789c 100644 --- a/app/Http/Controllers/ReportsController.php +++ b/app/Http/Controllers/ReportsController.php @@ -757,7 +757,7 @@ class ReportsController extends Controller if ($request->filled('username')) { // Only works if we're checked out to a user, not anything else. if ($asset->checkedOutToUser()) { - $row[] = ($asset->assignedto) ? $asset->assignedto->username : ''; + $row[] = ($asset->assignedTo) ? $asset->assignedTo->username : ''; } else { $row[] = ''; // Empty string if unassigned } @@ -766,7 +766,7 @@ class ReportsController extends Controller if ($request->filled('employee_num')) { // Only works if we're checked out to a user, not anything else. if ($asset->checkedOutToUser()) { - $row[] = ($asset->assignedto) ? $asset->assignedto->employee_num : ''; + $row[] = ($asset->assignedTo) ? $asset->assignedTo->employee_num : ''; } else { $row[] = ''; // Empty string if unassigned } @@ -774,7 +774,7 @@ class ReportsController extends Controller if ($request->filled('manager')) { if ($asset->checkedOutToUser()) { - $row[] = (($asset->assignedto) && ($asset->assignedto->manager)) ? $asset->assignedto->manager->present()->fullName : ''; + $row[] = (($asset->assignedTo) && ($asset->assignedTo->manager)) ? $asset->assignedTo->manager->present()->fullName : ''; } else { $row[] = ''; // Empty string if unassigned } @@ -782,7 +782,7 @@ class ReportsController extends Controller if ($request->filled('department')) { if ($asset->checkedOutToUser()) { - $row[] = (($asset->assignedto) && ($asset->assignedto->department)) ? $asset->assignedto->department->name : ''; + $row[] = (($asset->assignedTo) && ($asset->assignedTo->department)) ? $asset->assignedTo->department->name : ''; } else { $row[] = ''; // Empty string if unassigned } @@ -790,7 +790,7 @@ class ReportsController extends Controller if ($request->filled('title')) { if ($asset->checkedOutToUser()) { - $row[] = ($asset->assignedto) ? $asset->assignedto->jobtitle : ''; + $row[] = ($asset->assignedTo) ? $asset->assignedTo->jobtitle : ''; } else { $row[] = ''; // Empty string if unassigned } From 66e64cb13623474cb0e45961e3956b8568c28074 Mon Sep 17 00:00:00 2001 From: Ikko Ashimine Date: Thu, 6 Oct 2022 11:53:13 +0900 Subject: [PATCH 02/18] Fix typo in Dockerfile.fpm-alpine enviroment -> environment --- Dockerfile.fpm-alpine | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile.fpm-alpine b/Dockerfile.fpm-alpine index 868e4dbae1..3bb4566ffa 100644 --- a/Dockerfile.fpm-alpine +++ b/Dockerfile.fpm-alpine @@ -75,14 +75,14 @@ RUN set -eux; \ rm snipeit.tar.gz; \ # Install composer php dependencies if [ "$ENVIRONMENT" = "production" ]; then \ - echo "production enviroment detected!"; \ + echo "production environment detected!"; \ composer update \ --no-cache \ --no-dev \ --optimize-autoloader \ --working-dir=/var/www/html; \ else \ - echo "development enviroment detected!"; \ + echo "development environment detected!"; \ apk add --no-cache \ ${DEV_PACKAGES}; \ composer update \ @@ -100,4 +100,4 @@ COPY --chown=www-data:www-data docker/docker-secrets.env /var/www/html/.env COPY --chmod=655 docker/docker-entrypoint.sh /usr/local/bin/docker-snipeit-entrypoint COPY docker/column-statistics.cnf /etc/mysql/conf.d/column-statistics.cnf ENTRYPOINT [ "/usr/local/bin/docker-snipeit-entrypoint" ] -CMD [ "/usr/local/bin/docker-php-entrypoint", "php-fpm" ] \ No newline at end of file +CMD [ "/usr/local/bin/docker-php-entrypoint", "php-fpm" ] From 4fa01350c3cb1b887631ef4fa16c5b1aef33c45f Mon Sep 17 00:00:00 2001 From: Godfrey M Date: Tue, 11 Oct 2022 12:00:15 -0700 Subject: [PATCH 03/18] adds shortcuts for listing, creating, and saving --- resources/views/accessories/index.blade.php | 2 +- resources/views/components/index.blade.php | 2 +- resources/views/consumables/index.blade.php | 2 +- resources/views/hardware/index.blade.php | 2 +- resources/views/layouts/default.blade.php | 12 ++++++------ resources/views/licenses/index.blade.php | 2 +- .../views/partials/asset-bulk-actions.blade.php | 2 +- resources/views/partials/forms/edit/submit.blade.php | 2 +- resources/views/users/edit.blade.php | 2 +- resources/views/users/index.blade.php | 2 +- 10 files changed, 15 insertions(+), 15 deletions(-) diff --git a/resources/views/accessories/index.blade.php b/resources/views/accessories/index.blade.php index 52e970e9f3..3b82bfdb63 100755 --- a/resources/views/accessories/index.blade.php +++ b/resources/views/accessories/index.blade.php @@ -8,7 +8,7 @@ @section('header_right') @can('create', \App\Models\Accessory::class) - {{ trans('general.create') }} + {{ trans('general.create') }} @endcan @stop diff --git a/resources/views/components/index.blade.php b/resources/views/components/index.blade.php index e92d49a017..0442b5de06 100644 --- a/resources/views/components/index.blade.php +++ b/resources/views/components/index.blade.php @@ -8,7 +8,7 @@ @section('header_right') @can('create', \App\Models\Component::class) - {{ trans('general.create') }} + {{ trans('general.create') }} @endcan @stop diff --git a/resources/views/consumables/index.blade.php b/resources/views/consumables/index.blade.php index 5bf82ccb9d..b654aa884d 100644 --- a/resources/views/consumables/index.blade.php +++ b/resources/views/consumables/index.blade.php @@ -8,7 +8,7 @@ @section('header_right') @can('create', \App\Models\Consumable::class) - {{ trans('general.create') }} + {{ trans('general.create') }} @endcan @stop diff --git a/resources/views/hardware/index.blade.php b/resources/views/hardware/index.blade.php index 6c4cb69361..ef095c1cef 100755 --- a/resources/views/hardware/index.blade.php +++ b/resources/views/hardware/index.blade.php @@ -45,7 +45,7 @@ {{ trans('admin/hardware/general.custom_export') }} @can('create', \App\Models\Asset::class) - {{ trans('general.create') }} + {{ trans('general.create') }} @endcan @stop diff --git a/resources/views/layouts/default.blade.php b/resources/views/layouts/default.blade.php index ac29b3bb69..bd9b8d9d64 100644 --- a/resources/views/layouts/default.blade.php +++ b/resources/views/layouts/default.blade.php @@ -131,7 +131,7 @@