diff --git a/.github/autolabeler.yml b/.github/autolabeler.yml index 9320437c78..a27d5fe5fc 100644 --- a/.github/autolabeler.yml +++ b/.github/autolabeler.yml @@ -1,18 +1,22 @@ -frontend: ["*.js", "*.css", "*.vue", "*.scss", "*.less", "*.blade.*", "*livewire*"] +frontend: ["*.js", "*.css", "*.vue", "*.scss", "*.less", "*.blade.*", "resources/views/livewire/*"] skins: ["*.js", "*.css", "*.scss", "*.less"] css: ["*.css","*.scss", "*.less"] -backend: ["/app/*", "*.php"] +javascript: ["*.js", "package.json", "package.lock"] +backend: ["/app/*", "composer.json", "composer.lock"] +translations: ["/resources/lang"] +livewire: ["/app/Http/Livewire/*", "resources/views/livewire/*"] backups: ["*backup*"] restore: ["*restore*"] saml: ["*saml*"] scim: ["*scim*"] custom fields: ["*fields*", "*fieldsets*"] -dependencies: ["composer.json"] +dependencies: ["composer.json", "composer.lock", "package.json", "package.lock"] consumables: ["*consumables*"] -api: ["/app/Http/Controllers/api/*"] +api: ["/app/Http/Controllers/Api/*"] notifications: ["/app/Notifications/*"] -importer: ["/app/Importer/*"] +importer: ["/app/Importer/*","/app/Http/Livewire/Importer.php", "resources/views/livewire/importer.php"] cli / artisan: ["/app/Console/*"] -LDAP: ["*LDAP*", "/app/Console/Commands/Ldap*","/app/Models/Ldap.php"] +LDAP: ["*Ldap*", "/app/Console/Commands/Ldap*","/app/Models/Ldap.php"] docker: ["*docker/*", "Dockerfile", "Dockerfile.alpine", "Dockerfile.fpm-alpine", ".dockerignore", ".env.docker"] +tests: ["/tests/*", "/stubs"] config: .github diff --git a/Dockerfile b/Dockerfile index b572ff6896..4a240d7e83 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:20.04 +FROM ubuntu:22.04 LABEL maintainer="Brady Wetherington " # No need to add `apt-get clean` here, reference: @@ -14,16 +14,16 @@ RUN export DEBIAN_FRONTEND=noninteractive; \ apt-utils \ apache2 \ apache2-bin \ -libapache2-mod-php7.4 \ -php7.4-curl \ -php7.4-ldap \ -php7.4-mysql \ -php7.4-gd \ -php7.4-xml \ -php7.4-mbstring \ -php7.4-zip \ -php7.4-bcmath \ -php7.4-redis \ +libapache2-mod-php8.1 \ +php8.1-curl \ +php8.1-ldap \ +php8.1-mysql \ +php8.1-gd \ +php8.1-xml \ +php8.1-mbstring \ +php8.1-zip \ +php8.1-bcmath \ +php8.1-redis \ php-memcached \ patch \ curl \ @@ -40,7 +40,7 @@ autoconf \ libc-dev \ pkg-config \ libmcrypt-dev \ -php7.4-dev \ +php8.1-dev \ ca-certificates \ unzip \ dnsutils \ @@ -50,16 +50,16 @@ dnsutils \ RUN curl -L -O https://github.com/pear/pearweb_phars/raw/master/go-pear.phar RUN php go-pear.phar -RUN pecl install mcrypt-1.0.3 +RUN pecl install mcrypt -RUN bash -c "echo extension=/usr/lib/php/20190902/mcrypt.so > /etc/php/7.4/mods-available/mcrypt.ini" +RUN bash -c "echo extension=/usr/lib/php/20210902/mcrypt.so > /etc/php/8.1/mods-available/mcrypt.ini" RUN phpenmod mcrypt RUN phpenmod gd RUN phpenmod bcmath -RUN sed -i 's/variables_order = .*/variables_order = "EGPCS"/' /etc/php/7.4/apache2/php.ini -RUN sed -i 's/variables_order = .*/variables_order = "EGPCS"/' /etc/php/7.4/cli/php.ini +RUN sed -i 's/variables_order = .*/variables_order = "EGPCS"/' /etc/php/8.1/apache2/php.ini +RUN sed -i 's/variables_order = .*/variables_order = "EGPCS"/' /etc/php/8.1/cli/php.ini RUN useradd -m --uid 1000 --gid 50 docker diff --git a/Dockerfile.alpine b/Dockerfile.alpine index 93dba995a0..62a928f8ad 100644 --- a/Dockerfile.alpine +++ b/Dockerfile.alpine @@ -1,34 +1,34 @@ -FROM alpine:3.14.2 +FROM alpine:3.17.3 # Apache + PHP RUN apk add --no-cache \ apache2 \ - php7 \ - php7-common \ - php7-apache2 \ - php7-curl \ - php7-ldap \ - php7-mysqli \ - php7-gd \ - php7-xml \ - php7-mbstring \ - php7-zip \ - php7-ctype \ - php7-tokenizer \ - php7-pdo_mysql \ - php7-openssl \ - php7-bcmath \ - php7-phar \ - php7-json \ - php7-iconv \ - php7-fileinfo \ - php7-simplexml \ - php7-session \ - php7-dom \ - php7-xmlwriter \ - php7-xmlreader \ - php7-sodium \ - php7-redis \ - php7-pecl-memcached \ + php81 \ + php81-common \ + php81-apache2 \ + php81-curl \ + php81-ldap \ + php81-mysqli \ + php81-gd \ + php81-xml \ + php81-mbstring \ + php81-zip \ + php81-ctype \ + php81-tokenizer \ + php81-pdo_mysql \ + php81-openssl \ + php81-bcmath \ + php81-phar \ + php81-json \ + php81-iconv \ + php81-fileinfo \ + php81-simplexml \ + php81-session \ + php81-dom \ + php81-xmlwriter \ + php81-xmlreader \ + php81-sodium \ + php81-redis \ + php81-pecl-memcached \ curl \ wget \ vim \ @@ -41,7 +41,7 @@ COPY docker/column-statistics.cnf /etc/mysql/conf.d/column-statistics.cnf # Where apache's PID lives RUN mkdir -p /run/apache2 && chown apache:apache /run/apache2 -RUN sed -i 's/variables_order = .*/variables_order = "EGPCS"/' /etc/php7/php.ini +RUN sed -i 's/variables_order = .*/variables_order = "EGPCS"/' /etc/php81/php.ini COPY docker/000-default-2.4.conf /etc/apache2/conf.d/default.conf # Enable mod_rewrite diff --git a/Dockerfile.fpm-alpine b/Dockerfile.fpm-alpine index 3bb4566ffa..77302524d4 100644 --- a/Dockerfile.fpm-alpine +++ b/Dockerfile.fpm-alpine @@ -1,8 +1,8 @@ ARG ENVIRONMENT=production -ARG SNIPEIT_RELEASE=5.1.3 -ARG PHP_VERSION=7.4.16 -ARG PHP_ALPINE_VERSION=3.13 -ARG COMPOSER_VERSION=2.0.11 +ARG SNIPEIT_RELEASE=6.1.0 +ARG PHP_VERSION=8.2 +ARG PHP_ALPINE_VERSION=3.17 +ARG COMPOSER_VERSION=2 # Cannot use arguments with 'COPY --from' workaround # https://github.com/moby/moby/issues/34482#issuecomment-454716952 @@ -52,7 +52,7 @@ RUN { \ # Install php extensions inside docker containers easily # https://github.com/mlocati/docker-php-extension-installer -COPY --from=mlocati/php-extension-installer:1.2.19 /usr/bin/install-php-extensions /usr/local/bin/ +COPY --from=mlocati/php-extension-installer:2.1.15 /usr/bin/install-php-extensions /usr/local/bin/ RUN set -eux; \ install-php-extensions \ bcmath \ diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.php index 65a13edb2e..3b1ffb9b31 100644 --- a/app/Exceptions/Handler.php +++ b/app/Exceptions/Handler.php @@ -10,7 +10,7 @@ use ArieTimmerman\Laravel\SCIMServer\Exceptions\SCIMException; use Log; use Throwable; use JsonException; - +use Carbon\Exceptions\InvalidFormatException; class Handler extends ExceptionHandler { @@ -30,6 +30,7 @@ class Handler extends ExceptionHandler \League\OAuth2\Server\Exception\OAuthServerException::class, JsonException::class, SCIMException::class, //these generally don't need to be reported + InvalidFormatException::class, ]; /** @@ -69,21 +70,34 @@ class Handler extends ExceptionHandler // Invalid JSON exception // TODO: don't understand why we have to do this when we have the invalidJson() method, below, but, well, whatever if ($e instanceof JsonException) { - return response()->json(Helper::formatStandardApiResponse('error', null, 'invalid JSON'), 422); + return response()->json(Helper::formatStandardApiResponse('error', null, 'Invalid JSON'), 422); } + // Handle SCIM exceptions if ($e instanceof SCIMException) { - return response()->json(Helper::formatStandardApiResponse('error', null, 'invalid SCIM Request'), 400); + return response()->json(Helper::formatStandardApiResponse('error', null, 'Invalid SCIM Request'), 400); } - // Handle Ajax requests that fail because the model doesn't exist + // Handle standard requests that fail because Carbon cannot parse the date on validation (when a submitted date value is definitely not a date) + if ($e instanceof InvalidFormatException) { + return redirect()->back()->withInput()->with('error', trans('validation.date', ['attribute' => 'date'])); + } + + // Handle API requests that fail if ($request->ajax() || $request->wantsJson()) { + // Handle API requests that fail because Carbon cannot parse the date on validation (when a submitted date value is definitely not a date) + if ($e instanceof InvalidFormatException) { + return response()->json(Helper::formatStandardApiResponse('error', null, trans('validation.date', ['attribute' => 'date'])), 200); + } + + // Handle API requests that fail because the model doesn't exist if ($e instanceof \Illuminate\Database\Eloquent\ModelNotFoundException) { $className = last(explode('\\', $e->getModel())); return response()->json(Helper::formatStandardApiResponse('error', null, $className . ' not found'), 200); } + // Handle API requests that fail because of an HTTP status code and return a useful error message if ($this->isHttpException($e)) { $statusCode = $e->getStatusCode(); @@ -103,6 +117,8 @@ class Handler extends ExceptionHandler } + + if ($this->isHttpException($e) && (isset($statusCode)) && ($statusCode == '404' )) { return response()->view('layouts/basic', [ 'content' => view('errors/404') diff --git a/app/Http/Controllers/Accessories/AccessoryCheckoutController.php b/app/Http/Controllers/Accessories/AccessoryCheckoutController.php index 6144bb6f92..1ea036e6ed 100644 --- a/app/Http/Controllers/Accessories/AccessoryCheckoutController.php +++ b/app/Http/Controllers/Accessories/AccessoryCheckoutController.php @@ -25,11 +25,16 @@ class AccessoryCheckoutController extends Controller public function create($accessoryId) { // Check if the accessory exists - if (is_null($accessory = Accessory::find($accessoryId))) { + if (is_null($accessory = Accessory::withCount('users as users_count')->find($accessoryId))) { // Redirect to the accessory management page with error return redirect()->route('accessories.index')->with('error', trans('admin/accessories/message.not_found')); } + // Make sure there is at least one available to checkout + if ($accessory->numRemaining() <= 0){ + return redirect()->route('accessories.index')->with('error', trans('admin/accessories/message.checkout.unavailable')); + } + if ($accessory->category) { $this->authorize('checkout', $accessory); @@ -55,17 +60,23 @@ class AccessoryCheckoutController extends Controller public function store(Request $request, $accessoryId) { // Check if the accessory exists - if (is_null($accessory = Accessory::find($accessoryId))) { + if (is_null($accessory = Accessory::withCount('users as users_count')->find($accessoryId))) { // Redirect to the accessory management page with error return redirect()->route('accessories.index')->with('error', trans('admin/accessories/message.user_not_found')); } $this->authorize('checkout', $accessory); - if (! $user = User::find($request->input('assigned_to'))) { + if (!$user = User::find($request->input('assigned_to'))) { return redirect()->route('accessories.checkout.show', $accessory->id)->with('error', trans('admin/accessories/message.checkout.user_does_not_exist')); } + // Make sure there is at least one available to checkout + if ($accessory->numRemaining() <= 0){ + return redirect()->route('accessories.index')->with('error', trans('admin/accessories/message.checkout.unavailable')); + } + + // Update the accessory data $accessory->assigned_to = e($request->input('assigned_to')); diff --git a/app/Http/Controllers/Api/AccessoriesController.php b/app/Http/Controllers/Api/AccessoriesController.php index dc2130e986..91a6c5596b 100644 --- a/app/Http/Controllers/Api/AccessoriesController.php +++ b/app/Http/Controllers/Api/AccessoriesController.php @@ -80,12 +80,9 @@ class AccessoriesController extends Controller $accessories->where('notes','=',$request->input('notes')); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($accessories) && ($request->get('offset') > $accessories->count())) ? $accessories->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $accessories->count()) ? $accessories->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort_override = $request->input('sort'); diff --git a/app/Http/Controllers/Api/AssetMaintenancesController.php b/app/Http/Controllers/Api/AssetMaintenancesController.php index e38d5382fa..7e8ecdb114 100644 --- a/app/Http/Controllers/Api/AssetMaintenancesController.php +++ b/app/Http/Controllers/Api/AssetMaintenancesController.php @@ -55,12 +55,9 @@ class AssetMaintenancesController extends Controller } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($maintenances) && ($request->get('offset') > $maintenances->count())) ? $maintenances->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $maintenances->count()) ? $maintenances->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $allowed_columns = [ 'id', diff --git a/app/Http/Controllers/Api/AssetModelsController.php b/app/Http/Controllers/Api/AssetModelsController.php index 5e9b3ad78d..a9ef48adc0 100644 --- a/app/Http/Controllers/Api/AssetModelsController.php +++ b/app/Http/Controllers/Api/AssetModelsController.php @@ -78,12 +78,9 @@ class AssetModelsController extends Controller $assetmodels->TextSearch($request->input('search')); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($assetmodels) && ($request->get('offset') > $assetmodels->count())) ? $assetmodels->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $assetmodels->count()) ? $assetmodels->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'models.created_at'; diff --git a/app/Http/Controllers/Api/AssetsController.php b/app/Http/Controllers/Api/AssetsController.php index bad1947966..343593a038 100644 --- a/app/Http/Controllers/Api/AssetsController.php +++ b/app/Http/Controllers/Api/AssetsController.php @@ -199,13 +199,9 @@ class AssetsController extends Controller $request->filled('order_number') ? $assets = $assets->where('assets.order_number', '=', e($request->get('order_number'))) : ''; - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($assets) && ($request->get('offset') > $assets->count())) ? $assets->count() : $request->get('offset', 0); - - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $assets->count()) ? $assets->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; diff --git a/app/Http/Controllers/Api/CategoriesController.php b/app/Http/Controllers/Api/CategoriesController.php index 91b0d7f7dc..2781fa101f 100644 --- a/app/Http/Controllers/Api/CategoriesController.php +++ b/app/Http/Controllers/Api/CategoriesController.php @@ -67,8 +67,6 @@ class CategoriesController extends Controller $categories = $categories->withCount('showableAssets as assets_count'); } - - if ($request->filled('search')) { $categories = $categories->TextSearch($request->input('search')); } @@ -93,14 +91,9 @@ class CategoriesController extends Controller $categories->where('checkin_email', '=', $request->input('checkin_email')); } - - - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($categories) && ($request->get('offset') > $categories->count())) ? $categories->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $categories->count()) ? $categories->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'assets_count'; diff --git a/app/Http/Controllers/Api/CompaniesController.php b/app/Http/Controllers/Api/CompaniesController.php index 11f5845674..d6c8f6e76e 100644 --- a/app/Http/Controllers/Api/CompaniesController.php +++ b/app/Http/Controllers/Api/CompaniesController.php @@ -48,12 +48,10 @@ class CompaniesController extends Controller } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($companies) && ($request->get('offset') > $companies->count())) ? $companies->count() : $request->get('offset', 0); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $companies->count()) ? $companies->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'created_at'; diff --git a/app/Http/Controllers/Api/ComponentsController.php b/app/Http/Controllers/Api/ComponentsController.php index 473fbf1482..24eb1044b8 100644 --- a/app/Http/Controllers/Api/ComponentsController.php +++ b/app/Http/Controllers/Api/ComponentsController.php @@ -12,6 +12,7 @@ use App\Http\Requests\ImageUploadRequest; use App\Events\CheckoutableCheckedIn; use App\Events\ComponentCheckedIn; use App\Models\Asset; +use Illuminate\Support\Facades\Validator; class ComponentsController extends Controller { @@ -45,7 +46,7 @@ class ComponentsController extends Controller $components = Company::scopeCompanyables(Component::select('components.*') - ->with('company', 'location', 'category', 'assets')); + ->with('company', 'location', 'category', 'assets', 'supplier')); if ($request->filled('search')) { $components = $components->TextSearch($request->input('search')); @@ -63,6 +64,10 @@ class ComponentsController extends Controller $components->where('category_id', '=', $request->input('category_id')); } + if ($request->filled('supplier_id')) { + $components->where('supplier_id', '=', $request->input('supplier_id')); + } + if ($request->filled('location_id')) { $components->where('location_id', '=', $request->input('location_id')); } @@ -71,14 +76,10 @@ class ComponentsController extends Controller $components->where('notes','=',$request->input('notes')); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($components) && ($request->get('offset') > $components->count())) ? $components->count() : $request->get('offset', 0); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $components->count()) ? $components->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); - - $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort_override = $request->input('sort'); $column_sort = in_array($sort_override, $allowed_columns) ? $sort_override : 'created_at'; @@ -93,6 +94,9 @@ class ComponentsController extends Controller case 'company': $components = $components->OrderCompany($order); break; + case 'supplier': + $components = $components->OrderSupplier($order); + break; default: $components = $components->orderBy($column_sort, $order); break; @@ -225,20 +229,30 @@ class ComponentsController extends Controller public function checkout(Request $request, $componentId) { // Check if the component exists - if (is_null($component = Component::find($componentId))) { + if (!$component = Component::find($componentId)) { return response()->json(Helper::formatStandardApiResponse('error', null, trans('admin/components/message.does_not_exist'))); } $this->authorize('checkout', $component); + $validator = Validator::make($request->all(), [ + 'asset_id' => 'required|exists:assets,id', + 'assigned_qty' => "required|numeric|min:1|digits_between:1,".$component->numRemaining(), + ]); + + if ($validator->fails()) { + return response()->json(Helper::formatStandardApiResponse('error', $validator->errors())); + + } + + // Make sure there is at least one available to checkout + if ($component->numRemaining() <= $request->get('assigned_qty')) { + return response()->json(Helper::formatStandardApiResponse('error', null, trans('admin/components/message.checkout.unavailable', ['remaining' => $component->numRemaining(), 'requested' => $request->get('assigned_qty')]))); + } if ($component->numRemaining() >= $request->get('assigned_qty')) { - if (!$asset = Asset::find($request->input('assigned_to'))) { - return response()->json(Helper::formatStandardApiResponse('error', null, trans('admin/hardware/message.does_not_exist'))); - } - - // Update the accessory data + $asset = Asset::find($request->input('assigned_to')); $component->assigned_to = $request->input('assigned_to'); $component->assets()->attach($component->id, [ @@ -255,7 +269,7 @@ class ComponentsController extends Controller return response()->json(Helper::formatStandardApiResponse('success', null, trans('admin/components/message.checkout.success'))); } - return response()->json(Helper::formatStandardApiResponse('error', null, 'Not enough components remaining: '.$component->numRemaining().' remaining, '.$request->get('assigned_qty').' requested.')); + return response()->json(Helper::formatStandardApiResponse('error', null, trans('admin/components/message.checkout.unavailable', ['remaining' => $component->numRemaining(), 'requested' => $request->get('assigned_qty')]))); } /** diff --git a/app/Http/Controllers/Api/ConsumablesController.php b/app/Http/Controllers/Api/ConsumablesController.php index fc6620df48..bac9440dca 100644 --- a/app/Http/Controllers/Api/ConsumablesController.php +++ b/app/Http/Controllers/Api/ConsumablesController.php @@ -75,6 +75,10 @@ class ConsumablesController extends Controller $consumables->where('manufacturer_id', '=', $request->input('manufacturer_id')); } + if ($request->filled('supplier_id')) { + $consumables->where('supplier_id', '=', $request->input('supplier_id')); + } + if ($request->filled('location_id')) { $consumables->where('location_id','=',$request->input('location_id')); } @@ -84,12 +88,9 @@ class ConsumablesController extends Controller } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($consumables) && ($request->get('offset') > $consumables->count())) ? $consumables->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $consumables->count()) ? $consumables->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $allowed_columns = ['id', 'name', 'order_number', 'min_amt', 'purchase_date', 'purchase_cost', 'company', 'category', 'model_number', 'item_no', 'manufacturer', 'location', 'qty', 'image']; $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; @@ -111,6 +112,9 @@ class ConsumablesController extends Controller case 'company': $consumables = $consumables->OrderCompany($order); break; + case 'supplier': + $components = $consumables->OrderSupplier($order); + break; default: $consumables = $consumables->orderBy($column_sort, $order); break; @@ -154,7 +158,7 @@ class ConsumablesController extends Controller public function show($id) { $this->authorize('view', Consumable::class); - $consumable = Consumable::findOrFail($id); + $consumable = Consumable::with('users')->findOrFail($id); return (new ConsumablesTransformer)->transformConsumable($consumable); } @@ -253,33 +257,39 @@ class ConsumablesController extends Controller public function checkout(Request $request, $id) { // Check if the consumable exists - if (is_null($consumable = Consumable::find($id))) { + if (!$consumable = Consumable::with('users')->find($id)) { return response()->json(Helper::formatStandardApiResponse('error', null, trans('admin/consumables/message.does_not_exist'))); } $this->authorize('checkout', $consumable); - if ($consumable->qty > 0) { + // Make sure there is at least one available to checkout + if ($consumable->numRemaining() <= 0) { + return response()->json(Helper::formatStandardApiResponse('error', null, trans('admin/consumables/message.checkout.unavailable'))); + \Log::debug('No enough remaining'); + } - // Check if the user exists - $assigned_to = $request->input('assigned_to'); - if (is_null($user = User::find($assigned_to))) { - // Return error message - return response()->json(Helper::formatStandardApiResponse('error', null, 'No user found')); - } + // Check if the user exists - @TODO: this should probably be handled via validation, not here?? + if (!$user = User::find($request->input('assigned_to'))) { + // Return error message + return response()->json(Helper::formatStandardApiResponse('error', null, 'No user found')); + \Log::debug('No valid user'); + } - // Update the consumable data - $consumable->assigned_to = e($assigned_to); + // Update the consumable data + $consumable->assigned_to = $request->input('assigned_to'); - $consumable->users()->attach($consumable->id, [ - 'consumable_id' => $consumable->id, - 'user_id' => $user->id, - 'assigned_to' => $assigned_to, - 'note' => $request->input('note'), - ]); + $consumable->users()->attach($consumable->id, + [ + 'consumable_id' => $consumable->id, + 'user_id' => $user->id, + 'assigned_to' => $request->input('assigned_to'), + 'note' => $request->input('note'), + ] + ); // Log checkout event - $logaction = $consumable->logCheckout(e($request->input('note')), $user); + $logaction = $consumable->logCheckout($request->input('note'), $user); $data['log_id'] = $logaction->id; $data['eula'] = $consumable->getEula(); $data['first_name'] = $user->first_name; @@ -289,9 +299,7 @@ class ConsumablesController extends Controller $data['require_acceptance'] = $consumable->requireAcceptance(); return response()->json(Helper::formatStandardApiResponse('success', null, trans('admin/consumables/message.checkout.success'))); - } - return response()->json(Helper::formatStandardApiResponse('error', null, 'No consumables remaining')); } /** diff --git a/app/Http/Controllers/Api/DepartmentsController.php b/app/Http/Controllers/Api/DepartmentsController.php index 09e3677360..cab3991baa 100644 --- a/app/Http/Controllers/Api/DepartmentsController.php +++ b/app/Http/Controllers/Api/DepartmentsController.php @@ -58,12 +58,9 @@ class DepartmentsController extends Controller $departments->where('location_id', '=', $request->input('location_id')); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($departments) && ($request->get('offset') > $departments->count())) ? $departments->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $departments->count()) ? $departments->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'created_at'; diff --git a/app/Http/Controllers/Api/DepreciationsController.php b/app/Http/Controllers/Api/DepreciationsController.php index 2dd6b9d8e5..3d86c1b096 100644 --- a/app/Http/Controllers/Api/DepreciationsController.php +++ b/app/Http/Controllers/Api/DepreciationsController.php @@ -28,12 +28,9 @@ class DepreciationsController extends Controller $depreciations = $depreciations->TextSearch($request->input('search')); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($depreciations) && ($request->get('offset') > $depreciations->count())) ? $depreciations->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $depreciations->count()) ? $depreciations->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'created_at'; diff --git a/app/Http/Controllers/Api/GroupsController.php b/app/Http/Controllers/Api/GroupsController.php index 0e5d391e57..7cc5d2d756 100644 --- a/app/Http/Controllers/Api/GroupsController.php +++ b/app/Http/Controllers/Api/GroupsController.php @@ -35,12 +35,9 @@ class GroupsController extends Controller $groups->where('name', '=', $request->input('name')); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($groups) && ($request->get('offset') > $groups->count())) ? $groups->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $groups->count()) ? $groups->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'created_at'; diff --git a/app/Http/Controllers/Api/LicenseSeatsController.php b/app/Http/Controllers/Api/LicenseSeatsController.php index 759f11e956..884c9c59c4 100644 --- a/app/Http/Controllers/Api/LicenseSeatsController.php +++ b/app/Http/Controllers/Api/LicenseSeatsController.php @@ -39,8 +39,10 @@ class LicenseSeatsController extends Controller } $total = $seats->count(); - $offset = (($seats) && (request('offset') >= $total)) ? 0 : request('offset', 0); - $limit = request('limit', 50); + + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $seats->count()) ? $seats->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $seats = $seats->skip($offset)->take($limit)->get(); diff --git a/app/Http/Controllers/Api/LicensesController.php b/app/Http/Controllers/Api/LicensesController.php index 6e67f07ee9..df74b60895 100644 --- a/app/Http/Controllers/Api/LicensesController.php +++ b/app/Http/Controllers/Api/LicensesController.php @@ -94,12 +94,9 @@ class LicensesController extends Controller $licenses->onlyTrashed(); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($licenses) && ($request->get('offset') > $licenses->count())) ? $licenses->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $licenses->count()) ? $licenses->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; diff --git a/app/Http/Controllers/Api/LocationsController.php b/app/Http/Controllers/Api/LocationsController.php index 3a8df10587..4b1feee117 100644 --- a/app/Http/Controllers/Api/LocationsController.php +++ b/app/Http/Controllers/Api/LocationsController.php @@ -78,14 +78,15 @@ class LocationsController extends Controller $locations->where('locations.country', '=', $request->input('country')); } - $offset = (($locations) && (request('offset') > $locations->count())) ? $locations->count() : request('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $locations->count()) ? $locations->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'created_at'; + + switch ($request->input('sort')) { case 'parent': $locations->OrderParent($order); diff --git a/app/Http/Controllers/Api/ManufacturersController.php b/app/Http/Controllers/Api/ManufacturersController.php index e88ef5fedf..f3183238bf 100644 --- a/app/Http/Controllers/Api/ManufacturersController.php +++ b/app/Http/Controllers/Api/ManufacturersController.php @@ -57,12 +57,9 @@ class ManufacturersController extends Controller $manufacturers->where('support_email', '=', $request->input('support_email')); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($manufacturers) && ($request->get('offset') > $manufacturers->count())) ? $manufacturers->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $manufacturers->count()) ? $manufacturers->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'created_at'; diff --git a/app/Http/Controllers/Api/PredefinedKitsController.php b/app/Http/Controllers/Api/PredefinedKitsController.php index a2c0c1a902..85d05c422e 100644 --- a/app/Http/Controllers/Api/PredefinedKitsController.php +++ b/app/Http/Controllers/Api/PredefinedKitsController.php @@ -29,8 +29,10 @@ class PredefinedKitsController extends Controller $kits = $kits->TextSearch($request->input('search')); } - $offset = $request->input('offset', 0); - $limit = $request->input('limit', 50); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $kits->count()) ? $kits->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); + $order = $request->input('order') === 'desc' ? 'desc' : 'asc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'name'; $kits->orderBy($sort, $order); diff --git a/app/Http/Controllers/Api/ReportsController.php b/app/Http/Controllers/Api/ReportsController.php index f42a2d0f81..21294c5779 100644 --- a/app/Http/Controllers/Api/ReportsController.php +++ b/app/Http/Controllers/Api/ReportsController.php @@ -54,15 +54,15 @@ class ReportsController extends Controller 'note', ]; + + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $actionlogs->count()) ? $actionlogs->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); + $sort = in_array($request->input('sort'), $allowed_columns) ? e($request->input('sort')) : 'created_at'; $order = ($request->input('order') == 'asc') ? 'asc' : 'desc'; - $offset = request('offset', 0); $total = $actionlogs->count(); - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); - - $actionlogs = $actionlogs->orderBy($sort, $order)->skip($offset)->take($limit)->get(); return response()->json((new ActionlogsTransformer)->transformActionlogs($actionlogs, $total), 200, ['Content-Type' => 'application/json;charset=utf8'], JSON_UNESCAPED_UNICODE); diff --git a/app/Http/Controllers/Api/StatuslabelsController.php b/app/Http/Controllers/Api/StatuslabelsController.php index 76055f2d9b..a9e44d91b4 100644 --- a/app/Http/Controllers/Api/StatuslabelsController.php +++ b/app/Http/Controllers/Api/StatuslabelsController.php @@ -50,12 +50,9 @@ class StatuslabelsController extends Controller } } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($statuslabels) && ($request->get('offset') > $statuslabels->count())) ? $statuslabels->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $statuslabels->count()) ? $statuslabels->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'created_at'; diff --git a/app/Http/Controllers/Api/SuppliersController.php b/app/Http/Controllers/Api/SuppliersController.php index f73f150499..a26c33b1f8 100644 --- a/app/Http/Controllers/Api/SuppliersController.php +++ b/app/Http/Controllers/Api/SuppliersController.php @@ -23,11 +23,30 @@ class SuppliersController extends Controller public function index(Request $request) { $this->authorize('view', Supplier::class); - $allowed_columns = ['id', 'name', 'address', 'phone', 'contact', 'fax', 'email', 'image', 'assets_count', 'licenses_count', 'accessories_count', 'url']; + $allowed_columns = [' + id', + 'name', + 'address', + 'phone', + 'contact', + 'fax', + 'email', + 'image', + 'assets_count', + 'licenses_count', + 'accessories_count', + 'components_count', + 'consumables_count', + 'url', + ]; $suppliers = Supplier::select( - ['id', 'name', 'address', 'address2', 'city', 'state', 'country', 'fax', 'phone', 'email', 'contact', 'created_at', 'updated_at', 'deleted_at', 'image', 'notes'] - )->withCount('assets as assets_count')->withCount('licenses as licenses_count')->withCount('accessories as accessories_count'); + ['id', 'name', 'address', 'address2', 'city', 'state', 'country', 'fax', 'phone', 'email', 'contact', 'created_at', 'updated_at', 'deleted_at', 'image', 'notes']) + ->withCount('assets as assets_count') + ->withCount('licenses as licenses_count') + ->withCount('accessories as accessories_count') + ->withCount('components as components_count') + ->withCount('consumables as consumables_count'); if ($request->filled('search')) { @@ -74,12 +93,9 @@ class SuppliersController extends Controller $suppliers->where('notes', '=', $request->input('notes')); } - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($suppliers) && ($request->get('offset') > $suppliers->count())) ? $suppliers->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $suppliers->count()) ? $suppliers->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; $sort = in_array($request->input('sort'), $allowed_columns) ? $request->input('sort') : 'created_at'; diff --git a/app/Http/Controllers/Api/UsersController.php b/app/Http/Controllers/Api/UsersController.php index ff18b87910..7c63bb925c 100644 --- a/app/Http/Controllers/Api/UsersController.php +++ b/app/Http/Controllers/Api/UsersController.php @@ -193,12 +193,9 @@ class UsersController extends Controller $order = $request->input('order') === 'asc' ? 'asc' : 'desc'; - // Set the offset to the API call's offset, unless the offset is higher than the actual count of items in which - // case we override with the actual count, so we should return 0 items. - $offset = (($users) && ($request->get('offset') > $users->count())) ? $users->count() : $request->get('offset', 0); - - // Check to make sure the limit is not higher than the max allowed - ((config('app.max_results') >= $request->input('limit')) && ($request->filled('limit'))) ? $limit = $request->input('limit') : $limit = config('app.max_results'); + // Make sure the offset and limit are actually integers and do not exceed system limits + $offset = ($request->input('offset') > $users->count()) ? $users->count() : abs($request->input('offset')); + $limit = app('api_limit_value'); switch ($request->input('sort')) { diff --git a/app/Http/Controllers/BulkAssetModelsController.php b/app/Http/Controllers/BulkAssetModelsController.php index 43381da783..a312ba1f6e 100644 --- a/app/Http/Controllers/BulkAssetModelsController.php +++ b/app/Http/Controllers/BulkAssetModelsController.php @@ -92,7 +92,7 @@ class BulkAssetModelsController extends Controller AssetModel::whereIn('id', $models_raw_array)->update($update_array); return redirect()->route('models.index') - ->with('success', trans('admin/models/message.bulkedit.success')); + ->with('success', trans_choice('admin/models/message.bulkedit.success', count($models_raw_array), ['model_count' => count($models_raw_array)])); } return redirect()->route('models.index') diff --git a/app/Http/Controllers/Components/ComponentCheckoutController.php b/app/Http/Controllers/Components/ComponentCheckoutController.php index b2be07c661..412d9dde62 100644 --- a/app/Http/Controllers/Components/ComponentCheckoutController.php +++ b/app/Http/Controllers/Components/ComponentCheckoutController.php @@ -33,6 +33,11 @@ class ComponentCheckoutController extends Controller } $this->authorize('checkout', $component); + // Make sure there is at least one available to checkout + if ($component->numRemaining() <= 0){ + return redirect()->route('components.index')->with('error', trans('admin/components/message.checkout.unavailable')); + } + return view('components/checkout', compact('component')); } @@ -50,7 +55,7 @@ class ComponentCheckoutController extends Controller public function store(Request $request, $componentId) { // Check if the component exists - if (is_null($component = Component::find($componentId))) { + if (!$component = Component::find($componentId)) { // Redirect to the component management page with error return redirect()->route('components.index')->with('error', trans('admin/components/message.not_found')); } @@ -58,9 +63,15 @@ class ComponentCheckoutController extends Controller $this->authorize('checkout', $component); $max_to_checkout = $component->numRemaining(); + + // Make sure there are at least the requested number of components available to checkout + if ($max_to_checkout < $request->get('assigned_qty')) { + return redirect()->back()->withInput()->with('error', trans('admin/components/message.checkout.unavailable', ['remaining' => $max_to_checkout, 'requested' => $request->get('assigned_qty')])); + } + $validator = Validator::make($request->all(), [ - 'asset_id' => 'required', - 'assigned_qty' => "required|numeric|between:1,$max_to_checkout", + 'asset_id' => 'required|exists:assets,id', + 'assigned_qty' => "required|numeric|min:1|digits_between:1,$max_to_checkout", ]); if ($validator->fails()) { @@ -69,24 +80,17 @@ class ComponentCheckoutController extends Controller ->withInput(); } - $admin_user = Auth::user(); - $asset_id = e($request->input('asset_id')); - // Check if the user exists - if (is_null($asset = Asset::find($asset_id))) { - // Redirect to the component management page with error - return redirect()->route('components.index')->with('error', trans('admin/components/message.asset_does_not_exist')); - } + $asset = Asset::find($request->input('asset_id')); // Update the component data - $component->asset_id = $asset_id; - + $component->asset_id = $request->input('asset_id'); $component->assets()->attach($component->id, [ 'component_id' => $component->id, - 'user_id' => $admin_user->id, + 'user_id' => Auth::user(), 'created_at' => date('Y-m-d H:i:s'), 'assigned_qty' => $request->input('assigned_qty'), - 'asset_id' => $asset_id, + 'asset_id' => $request->input('asset_id'), 'note' => $request->input('note'), ]); diff --git a/app/Http/Controllers/Components/ComponentsController.php b/app/Http/Controllers/Components/ComponentsController.php index f943a71a2e..2ada973612 100644 --- a/app/Http/Controllers/Components/ComponentsController.php +++ b/app/Http/Controllers/Components/ComponentsController.php @@ -71,6 +71,7 @@ class ComponentsController extends Controller $component = new Component(); $component->name = $request->input('name'); $component->category_id = $request->input('category_id'); + $component->supplier_id = $request->input('supplier_id'); $component->location_id = $request->input('location_id'); $component->company_id = Company::getIdForCurrentUser($request->input('company_id')); $component->order_number = $request->input('order_number', null); @@ -145,6 +146,7 @@ class ComponentsController extends Controller // Update the component data $component->name = $request->input('name'); $component->category_id = $request->input('category_id'); + $component->supplier_id = $request->input('supplier_id'); $component->location_id = $request->input('location_id'); $component->company_id = Company::getIdForCurrentUser($request->input('company_id')); $component->order_number = $request->input('order_number'); diff --git a/app/Http/Controllers/Consumables/ConsumableCheckoutController.php b/app/Http/Controllers/Consumables/ConsumableCheckoutController.php index f7f2b6e54d..6585624d82 100644 --- a/app/Http/Controllers/Consumables/ConsumableCheckoutController.php +++ b/app/Http/Controllers/Consumables/ConsumableCheckoutController.php @@ -24,9 +24,16 @@ class ConsumableCheckoutController extends Controller */ public function create($consumableId) { - if (is_null($consumable = Consumable::find($consumableId))) { + + if (is_null($consumable = Consumable::with('users')->find($consumableId))) { return redirect()->route('consumables.index')->with('error', trans('admin/consumables/message.does_not_exist')); } + + // Make sure there is at least one available to checkout + if ($consumable->numRemaining() <= 0){ + return redirect()->route('consumables.index')->with('error', trans('admin/consumables/message.checkout.unavailable')); + } + $this->authorize('checkout', $consumable); return view('consumables/checkout', compact('consumable')); @@ -44,12 +51,18 @@ class ConsumableCheckoutController extends Controller */ public function store(Request $request, $consumableId) { - if (is_null($consumable = Consumable::find($consumableId))) { + if (is_null($consumable = Consumable::with('users')->find($consumableId))) { return redirect()->route('consumables.index')->with('error', trans('admin/consumables/message.not_found')); } $this->authorize('checkout', $consumable); + // Make sure there is at least one available to checkout + if ($consumable->numRemaining() <= 0) { + return redirect()->route('consumables.index')->with('error', trans('admin/consumables/message.checkout.unavailable')); + } + + $admin_user = Auth::user(); $assigned_to = e($request->input('assigned_to')); diff --git a/app/Http/Controllers/Consumables/ConsumablesController.php b/app/Http/Controllers/Consumables/ConsumablesController.php index f068e9868d..0a40c0bb3b 100644 --- a/app/Http/Controllers/Consumables/ConsumablesController.php +++ b/app/Http/Controllers/Consumables/ConsumablesController.php @@ -68,6 +68,7 @@ class ConsumablesController extends Controller $consumable = new Consumable(); $consumable->name = $request->input('name'); $consumable->category_id = $request->input('category_id'); + $consumable->supplier_id = $request->input('supplier_id'); $consumable->location_id = $request->input('location_id'); $consumable->company_id = Company::getIdForCurrentUser($request->input('company_id')); $consumable->order_number = $request->input('order_number'); @@ -144,6 +145,7 @@ class ConsumablesController extends Controller $consumable->name = $request->input('name'); $consumable->category_id = $request->input('category_id'); + $consumable->supplier_id = $request->input('supplier_id'); $consumable->location_id = $request->input('location_id'); $consumable->company_id = Company::getIdForCurrentUser($request->input('company_id')); $consumable->order_number = $request->input('order_number'); diff --git a/app/Http/Controllers/Controller.php b/app/Http/Controllers/Controller.php index 96d761ef5b..c0e9454d62 100644 --- a/app/Http/Controllers/Controller.php +++ b/app/Http/Controllers/Controller.php @@ -9,11 +9,11 @@ * * **THIS DOCUMENTATION DOES NOT COVER INSTALLATION.** If you're here and you're not a * developer, you're probably in the wrong place. Please see the - * [Installation documentation](http://docs.snipeitapp.com) for + * [Installation documentation](https://snipe-it.readme.io) for * information on how to install Snipe-IT. * * To learn how to set up a development environment and get started developing for Snipe-IT, - * please see the [contributing documentation](http://docs.snipeitapp.com/contributing.html). + * please see the [contributing documentation](https://snipe-it.readme.io/docs/contributing-overview). * * Only the Snipe-IT specific controllers, models, helpers, service providers, * etc have been included in this documentation (excluding vendors, Laravel core, etc) diff --git a/app/Http/Controllers/SettingsController.php b/app/Http/Controllers/SettingsController.php index 1deaa5d104..f16a6fc8f0 100755 --- a/app/Http/Controllers/SettingsController.php +++ b/app/Http/Controllers/SettingsController.php @@ -84,7 +84,7 @@ class SettingsController extends Controller } $pageURL = $protocol.$host.$_SERVER['REQUEST_URI']; - $start_settings['url_config'] = url('/').'/setup'; + $start_settings['url_config'] = config('app.url').'/setup'; $start_settings['url_valid'] = ($start_settings['url_config'] === $pageURL); $start_settings['real_url'] = $pageURL; $start_settings['php_version_min'] = true; diff --git a/app/Http/Controllers/Users/UsersController.php b/app/Http/Controllers/Users/UsersController.php index 83f271362a..7e95484f6e 100755 --- a/app/Http/Controllers/Users/UsersController.php +++ b/app/Http/Controllers/Users/UsersController.php @@ -74,7 +74,6 @@ class UsersController extends Controller $permissions = $this->filterDisplayable($permissions); $user = new User; - $user->activated = 1; return view('users/edit', compact('groups', 'userGroups', 'permissions', 'userPermissions')) ->with('user', $user); diff --git a/app/Http/Middleware/CheckForSetup.php b/app/Http/Middleware/CheckForSetup.php index b4beb70588..4e399ffcff 100644 --- a/app/Http/Middleware/CheckForSetup.php +++ b/app/Http/Middleware/CheckForSetup.php @@ -20,13 +20,13 @@ class CheckForSetup if (Setting::setupCompleted()) { if ($request->is('setup*')) { - return redirect(url('/')); + return redirect(config('app.url')); } else { return $next($request); } } else { if (! ($request->is('setup*')) && ! ($request->is('.env')) && ! ($request->is('health'))) { - return redirect(url('/').'/setup'); + return redirect(config('app.url').'/setup'); } return $next($request); diff --git a/app/Http/Transformers/ComponentsTransformer.php b/app/Http/Transformers/ComponentsTransformer.php index 1610c3da5b..97677af283 100644 --- a/app/Http/Transformers/ComponentsTransformer.php +++ b/app/Http/Transformers/ComponentsTransformer.php @@ -37,6 +37,7 @@ class ComponentsTransformer 'id' => (int) $component->category->id, 'name' => e($component->category->name), ] : null, + 'supplier' => ($component->supplier) ? ['id' => $component->supplier->id, 'name'=> e($component->supplier->name)] : null, 'order_number' => e($component->order_number), 'purchase_date' => Helper::getFormattedDateObject($component->purchase_date, 'date'), 'purchase_cost' => Helper::formatCurrencyOutput($component->purchase_cost), diff --git a/app/Http/Transformers/ConsumablesTransformer.php b/app/Http/Transformers/ConsumablesTransformer.php index 5079b28961..b92f843b7f 100644 --- a/app/Http/Transformers/ConsumablesTransformer.php +++ b/app/Http/Transformers/ConsumablesTransformer.php @@ -31,6 +31,7 @@ class ConsumablesTransformer 'item_no' => e($consumable->item_no), 'location' => ($consumable->location) ? ['id' => (int) $consumable->location->id, 'name' => e($consumable->location->name)] : null, 'manufacturer' => ($consumable->manufacturer) ? ['id' => (int) $consumable->manufacturer->id, 'name' => e($consumable->manufacturer->name)] : null, + 'supplier' => ($consumable->supplier) ? ['id' => $consumable->supplier->id, 'name'=> e($consumable->supplier->name)] : null, 'min_amt' => (int) $consumable->min_amt, 'model_number' => ($consumable->model_number != '') ? e($consumable->model_number) : null, 'remaining' => $consumable->numRemaining(), diff --git a/app/Http/Transformers/SuppliersTransformer.php b/app/Http/Transformers/SuppliersTransformer.php index 71307a750d..e7546bfd15 100644 --- a/app/Http/Transformers/SuppliersTransformer.php +++ b/app/Http/Transformers/SuppliersTransformer.php @@ -41,6 +41,8 @@ class SuppliersTransformer 'assets_count' => (int) $supplier->assets_count, 'accessories_count' => (int) $supplier->accessories_count, 'licenses_count' => (int) $supplier->licenses_count, + 'consumables_count' => (int) $supplier->consumables_count, + 'components_count' => (int) $supplier->components_count, 'notes' => ($supplier->notes) ? e($supplier->notes) : null, 'created_at' => Helper::getFormattedDateObject($supplier->created_at, 'datetime'), 'updated_at' => Helper::getFormattedDateObject($supplier->updated_at, 'datetime'), diff --git a/app/Models/Accessory.php b/app/Models/Accessory.php index 0457cf253f..7576cc644f 100755 --- a/app/Models/Accessory.php +++ b/app/Models/Accessory.php @@ -330,7 +330,11 @@ class Accessory extends SnipeModel /** - * Check how many items of an accessory remain + * Check how many items of an accessory remain. + * + * In order to use this model method, you MUST call withCount('users as users_count') + * on the eloquent query in the controller, otherwise $this->>users_count will be null and + * bad things happen. * * @author [A. Gianotto] [] * @since [v3.0] diff --git a/app/Models/Component.php b/app/Models/Component.php index 98230132be..052ec1219d 100644 --- a/app/Models/Component.php +++ b/app/Models/Component.php @@ -33,7 +33,8 @@ class Component extends SnipeModel 'name' => 'required|min:3|max:255', 'qty' => 'required|integer|min:1', 'category_id' => 'required|integer|exists:categories,id', - 'company_id' => 'integer|nullable', + 'supplier_id' => 'nullable|integer|exists:suppliers,id', + 'company_id' => 'integer|nullable|exists:companies,id', 'min_amt' => 'integer|min:0|nullable', 'purchase_date' => 'date_format:Y-m-d|nullable', 'purchase_cost' => 'numeric|nullable|gte:0', @@ -57,6 +58,7 @@ class Component extends SnipeModel protected $fillable = [ 'category_id', 'company_id', + 'supplier_id', 'location_id', 'name', 'purchase_cost', @@ -86,6 +88,7 @@ class Component extends SnipeModel 'category' => ['name'], 'company' => ['name'], 'location' => ['name'], + 'supplier' => ['name'], ]; @@ -168,6 +171,18 @@ class Component extends SnipeModel return $this->belongsTo(\App\Models\Category::class, 'category_id'); } + /** + * Establishes the item -> supplier relationship + * + * @author [A. Gianotto] [] + * @since [v6.1.1] + * @return \Illuminate\Database\Eloquent\Relations\Relation + */ + public function supplier() + { + return $this->belongsTo(\App\Models\Supplier::class, 'supplier_id'); + } + /** * Establishes the component -> action logs relationship * @@ -247,4 +262,17 @@ class Component extends SnipeModel { return $query->leftJoin('companies', 'components.company_id', '=', 'companies.id')->orderBy('companies.name', $order); } + + /** + * Query builder scope to order on supplier + * + * @param \Illuminate\Database\Query\Builder $query Query builder instance + * @param text $order Order + * + * @return \Illuminate\Database\Query\Builder Modified query builder + */ + public function scopeOrderSupplier($query, $order) + { + return $query->leftJoin('suppliers', 'components.supplier_id', '=', 'suppliers.id')->orderBy('suppliers.name', $order); + } } diff --git a/app/Models/Consumable.php b/app/Models/Consumable.php index ea4ac6086b..a3a0d59178 100644 --- a/app/Models/Consumable.php +++ b/app/Models/Consumable.php @@ -27,6 +27,7 @@ class Consumable extends SnipeModel 'requestable' => 'boolean', 'category_id' => 'integer', 'company_id' => 'integer', + 'supplier_id', 'qty' => 'integer', 'min_amt' => 'integer', ]; @@ -95,6 +96,7 @@ class Consumable extends SnipeModel 'company' => ['name'], 'location' => ['name'], 'manufacturer' => ['name'], + 'supplier' => ['name'], ]; @@ -249,6 +251,18 @@ class Consumable extends SnipeModel return $this->belongsToMany(\App\Models\User::class, 'consumables_users', 'consumable_id', 'assigned_to')->withPivot('user_id')->withTrashed()->withTimestamps(); } + /** + * Establishes the item -> supplier relationship + * + * @author [A. Gianotto] [] + * @since [v6.1.1] + * @return \Illuminate\Database\Eloquent\Relations\Relation + */ + public function supplier() + { + return $this->belongsTo(\App\Models\Supplier::class, 'supplier_id'); + } + /** * Determine whether to send a checkin/checkout email based on @@ -376,4 +390,17 @@ class Consumable extends SnipeModel { return $query->leftJoin('companies', 'consumables.company_id', '=', 'companies.id')->orderBy('companies.name', $order); } + + /** + * Query builder scope to order on supplier + * + * @param \Illuminate\Database\Query\Builder $query Query builder instance + * @param text $order Order + * + * @return \Illuminate\Database\Query\Builder Modified query builder + */ + public function scopeOrderSupplier($query, $order) + { + return $query->leftJoin('suppliers', 'consumables.supplier_id', '=', 'suppliers.id')->orderBy('suppliers.name', $order); + } } diff --git a/app/Models/License.php b/app/Models/License.php index 94263ee0d8..ff69d5f66d 100755 --- a/app/Models/License.php +++ b/app/Models/License.php @@ -33,9 +33,9 @@ class License extends Depreciable protected $table = 'licenses'; protected $casts = [ - 'purchase_date' => 'datetime', - 'expiration_date' => 'datetime', - 'termination_date' => 'datetime', + 'purchase_date' => 'date', + 'expiration_date' => 'date', + 'termination_date' => 'date', 'category_id' => 'integer', 'company_id' => 'integer', ]; @@ -49,9 +49,9 @@ class License extends Depreciable 'category_id' => 'required|exists:categories,id', 'company_id' => 'integer|nullable', 'purchase_cost'=> 'numeric|nullable|gte:0', - 'purchase_date' => 'date_format:Y-m-d|nullable', - 'expiration_date' => 'date_format:Y-m-d|nullable', - 'termination_date' => 'date_format:Y-m-d|nullable', + 'purchase_date' => 'date_format:Y-m-d|nullable|max:10', + 'expiration_date' => 'date_format:Y-m-d|nullable|max:10', + 'termination_date' => 'date_format:Y-m-d|nullable|max:10', ]; /** diff --git a/app/Models/Location.php b/app/Models/Location.php index 8181f406cd..8cea9bda12 100755 --- a/app/Models/Location.php +++ b/app/Models/Location.php @@ -267,7 +267,7 @@ class Location extends SnipeModel foreach ($locations_with_children[$parent_id] as $location) { $location->use_text = $prefix.' '.$location->name; - $location->use_image = ($location->image) ? url('/').'/uploads/locations/'.$location->image : null; + $location->use_image = ($location->image) ? config('app.url').'/uploads/locations/'.$location->image : null; $results[] = $location; //now append the children. (if we have any) if (array_key_exists($location->id, $locations_with_children)) { diff --git a/app/Models/Supplier.php b/app/Models/Supplier.php index 393e7ddb29..d60d3c42fe 100755 --- a/app/Models/Supplier.php +++ b/app/Models/Supplier.php @@ -121,6 +121,30 @@ class Supplier extends SnipeModel return $this->hasMany(\App\Models\Accessory::class, 'supplier_id'); } + /** + * Establishes the supplier -> component relationship + * + * @author A. Gianotto + * @since [v6.1.1] + * @return \Illuminate\Database\Eloquent\Relations\Relation + */ + public function components() + { + return $this->hasMany(\App\Models\Component::class, 'supplier_id'); + } + + /** + * Establishes the supplier -> component relationship + * + * @author A. Gianotto + * @since [v6.1.1] + * @return \Illuminate\Database\Eloquent\Relations\Relation + */ + public function consumables() + { + return $this->hasMany(\App\Models\Consumable::class, 'supplier_id'); + } + /** * Establishes the supplier -> asset maintenances relationship * diff --git a/app/Models/User.php b/app/Models/User.php index f32e041626..efdbb6297c 100644 --- a/app/Models/User.php +++ b/app/Models/User.php @@ -76,8 +76,6 @@ class User extends SnipeModel implements AuthenticatableContract, AuthorizableCo 'created_at' => 'datetime', 'updated_at' => 'datetime', 'deleted_at' => 'datetime', - 'start_date' => 'datetime:Y-m-d', - 'end_date' => 'datetime:Y-m-d', ]; /** diff --git a/app/Notifications/FirstAdminNotification.php b/app/Notifications/FirstAdminNotification.php index 71637b5e80..83e3a65de7 100644 --- a/app/Notifications/FirstAdminNotification.php +++ b/app/Notifications/FirstAdminNotification.php @@ -24,7 +24,7 @@ class FirstAdminNotification extends Notification $this->_data['last_name'] = $content['last_name']; $this->_data['username'] = $content['username']; $this->_data['password'] = $content['password']; - $this->_data['url'] = url('/'); + $this->_data['url'] = config('app.url'); } /** diff --git a/app/Notifications/WelcomeNotification.php b/app/Notifications/WelcomeNotification.php index a5754be4d9..1e27ca7364 100644 --- a/app/Notifications/WelcomeNotification.php +++ b/app/Notifications/WelcomeNotification.php @@ -24,7 +24,7 @@ class WelcomeNotification extends Notification $this->_data['last_name'] = htmlspecialchars_decode($content['last_name']); $this->_data['username'] = htmlspecialchars_decode($content['username']); $this->_data['password'] = htmlspecialchars_decode($content['password']); - $this->_data['url'] = url('/'); + $this->_data['url'] = config('app.url'); } /** diff --git a/app/Presenters/AssetModelPresenter.php b/app/Presenters/AssetModelPresenter.php index fd74108ee3..8e3d109045 100644 --- a/app/Presenters/AssetModelPresenter.php +++ b/app/Presenters/AssetModelPresenter.php @@ -210,7 +210,7 @@ class AssetModelPresenter extends Presenter public function imageUrl() { if (! empty($this->image)) { - return ''.$this->name.''; + return ''.$this->name.''; } return ''; @@ -223,7 +223,7 @@ class AssetModelPresenter extends Presenter public function imageSrc() { if (! empty($this->image)) { - return url('/').'/uploads/models/'.$this->image; + return config('app.url').'/uploads/models/'.$this->image; } return ''; diff --git a/app/Presenters/ComponentPresenter.php b/app/Presenters/ComponentPresenter.php index 16a96f3c4c..c7468911a1 100644 --- a/app/Presenters/ComponentPresenter.php +++ b/app/Presenters/ComponentPresenter.php @@ -59,6 +59,15 @@ class ComponentPresenter extends Presenter 'title' => trans('general.category'), 'formatter' => 'categoriesLinkObjFormatter', ], [ + 'field' => 'supplier', + 'searchable' => true, + 'sortable' => true, + 'switchable' => true, + 'title' => trans('general.supplier'), + 'visible' => false, + 'formatter' => 'suppliersLinkObjFormatter', + ], + [ 'field' => 'qty', 'searchable' => false, 'sortable' => true, diff --git a/app/Presenters/ConsumablePresenter.php b/app/Presenters/ConsumablePresenter.php index e931fc1228..abb599de4f 100644 --- a/app/Presenters/ConsumablePresenter.php +++ b/app/Presenters/ConsumablePresenter.php @@ -53,6 +53,14 @@ class ConsumablePresenter extends Presenter 'sortable' => true, 'title' => trans('general.category'), 'formatter' => 'categoriesLinkObjFormatter', + ], [ + 'field' => 'supplier', + 'searchable' => true, + 'sortable' => true, + 'switchable' => true, + 'title' => trans('general.supplier'), + 'visible' => false, + 'formatter' => 'suppliersLinkObjFormatter', ], [ 'field' => 'model_number', 'searchable' => true, diff --git a/app/Presenters/UserPresenter.php b/app/Presenters/UserPresenter.php index 4bfe4492ff..b5eefdf811 100644 --- a/app/Presenters/UserPresenter.php +++ b/app/Presenters/UserPresenter.php @@ -406,7 +406,7 @@ class UserPresenter extends Presenter } // Set a fun, gender-neutral default icon - return url('/').'/img/default-sm.png'; + return config('app.url').'/img/default-sm.png'; } /** diff --git a/app/Providers/SettingsServiceProvider.php b/app/Providers/SettingsServiceProvider.php index ed5bd48dd2..371fc234de 100644 --- a/app/Providers/SettingsServiceProvider.php +++ b/app/Providers/SettingsServiceProvider.php @@ -29,6 +29,23 @@ class SettingsServiceProvider extends ServiceProvider $view->with('snipeSettings', Setting::getSettings()); }); + + // Make sure the limit is actually set, is an integer and does not exceed system limits + \App::singleton('api_limit_value', function () { + $limit = config('app.max_results'); + + if ((abs(intval(request('limit'))) > 0) && (abs(request('limit')) <= config('app.max_results'))) { + $limit = abs(request('limit')); + } + \Log::debug('Max in env: '.config('app.max_results')); + \Log::debug('Original requested limit: '.request('limit')); + \Log::debug('Modified limit: '.$limit); + \Log::debug('------------------------------'); + + return $limit; + }); + + /** * Set some common variables so that they're globally available. * The paths should always be public (versus private uploads) diff --git a/app/Services/Saml.php b/app/Services/Saml.php index 3f39be29ff..f80b1c1fb9 100644 --- a/app/Services/Saml.php +++ b/app/Services/Saml.php @@ -161,7 +161,7 @@ class Saml //Let onelogin/php-saml know to use 'X-Forwarded-*' headers if it is from a trusted proxy OneLogin_Saml2_Utils::setProxyVars(request()->isFromTrustedProxy()); - data_set($settings, 'sp.entityId', url('/')); + data_set($settings, 'sp.entityId', config('app.url')); data_set($settings, 'sp.assertionConsumerService.url', route('saml.acs')); data_set($settings, 'sp.singleLogoutService.url', route('saml.sls')); data_set($settings, 'sp.x509cert', $setting->saml_sp_x509cert); diff --git a/config/services.php b/config/services.php index 3f7362fd51..de8c4ed71a 100644 --- a/config/services.php +++ b/config/services.php @@ -43,10 +43,10 @@ return [ 'secret' => env('STRIPE_SECRET'), ], - 'stunning' => [ - 'enabled' => env('ENABLE_STUNNING', false), - 'app_key' => env('STUNNING_APP_KEY'), - 'stripe_id' => env('STUNNING_STRIPE_ID'), + 'baremetrics' => [ + 'enabled' => env('ENABLE_BMPAY', false), + 'app_key' => env('BMPAY_PUBLIC_KEY', null), + 'stripe_id' => env('BMPAY_STRIPE_ID', null), ], 'google' => [ diff --git a/config/version.php b/config/version.php index fba609ce3a..f8c297c9ca 100644 --- a/config/version.php +++ b/config/version.php @@ -1,10 +1,10 @@ 'v6.1.0-pre', - 'full_app_version' => 'v6.1.0-pre - build 10030-gdcbd216e2', - 'build_version' => '10030', + 'app_version' => 'v6.1.0', + 'full_app_version' => 'v6.1.0 - build 10161-ga8ca3ad2a', + 'build_version' => '10161', 'prerelease_version' => '', - 'hash_version' => 'gdcbd216e2', - 'full_hash' => 'v6.1.0-pre-986-gdcbd216e2', + 'hash_version' => 'ga8ca3ad2a', + 'full_hash' => 'v6.1.0-127-ga8ca3ad2a', 'branch' => 'develop', ); \ No newline at end of file diff --git a/crowdin.yml b/crowdin.yml index 4eccb2adbc..7abe441e4f 100644 --- a/crowdin.yml +++ b/crowdin.yml @@ -3,6 +3,7 @@ "files": [ { "source" : "/resources/lang/en/**/*.php", - "translation" : "/resources/lang/%locale%/%original_file_name%" + # https://developer.crowdin.com/configuration-file/#placeholders + "translation" : "/resources/lang/%locale%/**/%original_file_name%" } ] diff --git a/database/factories/ComponentFactory.php b/database/factories/ComponentFactory.php index 6db9ef24fa..caac70078f 100644 --- a/database/factories/ComponentFactory.php +++ b/database/factories/ComponentFactory.php @@ -7,6 +7,7 @@ use App\Models\Company; use App\Models\Component; use App\Models\Location; use Illuminate\Database\Eloquent\Factories\Factory; +use App\Models\Supplier; class ComponentFactory extends Factory { @@ -35,6 +36,7 @@ class ComponentFactory extends Factory 'purchase_cost' => $this->faker->randomFloat(2), 'min_amt' => $this->faker->numberBetween($min = 1, $max = 2), 'company_id' => Company::factory(), + 'supplier_id' => Supplier::factory(), ]; } diff --git a/database/factories/ConsumableFactory.php b/database/factories/ConsumableFactory.php index 8dd56229e0..5444999711 100644 --- a/database/factories/ConsumableFactory.php +++ b/database/factories/ConsumableFactory.php @@ -8,6 +8,7 @@ use App\Models\Consumable; use App\Models\Manufacturer; use App\Models\User; use Illuminate\Database\Eloquent\Factories\Factory; +use App\Models\Supplier; class ConsumableFactory extends Factory { @@ -36,6 +37,7 @@ class ConsumableFactory extends Factory 'qty' => $this->faker->numberBetween(5, 10), 'min_amt' => $this->faker->numberBetween($min = 1, $max = 2), 'company_id' => Company::factory(), + 'supplier_id' => Supplier::factory(), ]; } diff --git a/database/factories/SettingFactory.php b/database/factories/SettingFactory.php index 2e19f831d7..1655bd3350 100644 --- a/database/factories/SettingFactory.php +++ b/database/factories/SettingFactory.php @@ -34,31 +34,4 @@ class SettingFactory extends Factory 'email_domain' => 'test.com', ]; } - - public function withMultipleFullCompanySupport() - { - return $this->state(function () { - return [ - 'full_multiple_companies_support' => 1, - ]; - }); - } - - public function withWebhookEnabled() - { - return $this->state(fn() => [ - 'webhook_botname' => 'SnipeBot5000', - 'webhook_endpoint' => 'https://hooks.slack.com/services/NZ59/Q446/672N', - 'webhook_channel' => '#it', - ]); - } - - public function withWebhookDisabled() - { - return $this->state(fn() => [ - 'webhook_botname' => '', - 'webhook_endpoint' => '', - 'webhook_channel' => '', - ]); - } } diff --git a/database/migrations/2023_04_12_135822_add_supplier_to_components.php b/database/migrations/2023_04_12_135822_add_supplier_to_components.php new file mode 100644 index 0000000000..447c7850a9 --- /dev/null +++ b/database/migrations/2023_04_12_135822_add_supplier_to_components.php @@ -0,0 +1,48 @@ +integer('supplier_id')->after('user_id')->nullable()->default(null); + } + }); + + Schema::table('consumables', function (Blueprint $table) { + if (!Schema::hasColumn('consumables', 'supplier_id')) { + $table->integer('supplier_id')->after('user_id')->nullable()->default(null); + } + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::table('components', function (Blueprint $table) { + if (Schema::hasColumn('components', 'supplier_id')) { + $table->dropColumn('supplier_id'); + } + }); + + Schema::table('consumables', function (Blueprint $table) { + if (Schema::hasColumn('consumables', 'supplier_id')) { + $table->dropColumn('supplier_id'); + } + }); + } +} diff --git a/database/seeders/AssetSeeder.php b/database/seeders/AssetSeeder.php index 53af19758b..5fdc09bdb3 100644 --- a/database/seeders/AssetSeeder.php +++ b/database/seeders/AssetSeeder.php @@ -29,26 +29,26 @@ class AssetSeeder extends Seeder $this->locationIds = Location::all()->pluck('id'); $this->supplierIds = Supplier::all()->pluck('id'); - Asset::factory()->count(1000)->laptopMbp()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(2000)->laptopMbp()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(50)->laptopMbpPending()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(50)->laptopMbpArchived()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(50)->laptopAir()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(5)->laptopSurface()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(50)->laptopSurface()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(5)->laptopXps()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(5)->laptopSpectre()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(5)->laptopZenbook()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(3)->laptopYoga()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(50)->laptopZenbook()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(30)->laptopYoga()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(30)->desktopMacpro()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(30)->desktopLenovoI5()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(30)->desktopOptiplex()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(5)->confPolycom()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(2)->confPolycomcx()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(12)->tabletIpad()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(4)->tabletTab3()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(50)->confPolycom()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(20)->confPolycomcx()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(30)->tabletIpad()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(10)->tabletTab3()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(27)->phoneIphone11()->state(new Sequence($this->getState()))->create(); Asset::factory()->count(40)->phoneIphone12()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(10)->ultrafine()->state(new Sequence($this->getState()))->create(); - Asset::factory()->count(10)->ultrasharp()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(20)->ultrafine()->state(new Sequence($this->getState()))->create(); + Asset::factory()->count(20)->ultrasharp()->state(new Sequence($this->getState()))->create(); $del_files = Storage::files('assets'); foreach ($del_files as $del_file) { // iterate files diff --git a/package-lock.json b/package-lock.json index 327f8ede3a..dd058375d0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1346,26 +1346,43 @@ "@jridgewell/resolve-uri": { "version": "3.0.7", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.0.7.tgz", - "integrity": "sha512-8cXDaBBHOr2pQ7j77Y6Vp5VDT2sIqWyWQ56TjEq4ih/a4iST3dItRe8Q9fp0rrIl9DoKhWQtUQz/YpOxLkXbNA==", - "dev": true + "integrity": "sha512-8cXDaBBHOr2pQ7j77Y6Vp5VDT2sIqWyWQ56TjEq4ih/a4iST3dItRe8Q9fp0rrIl9DoKhWQtUQz/YpOxLkXbNA==" }, "@jridgewell/set-array": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.1.tgz", - "integrity": "sha512-Ct5MqZkLGEXTVmQYbGtx9SVqD2fqwvdubdps5D3djjAkgkKwT918VNOz65pEHFaYTeWcukmJmH5SwsA9Tn2ObQ==", - "dev": true + "integrity": "sha512-Ct5MqZkLGEXTVmQYbGtx9SVqD2fqwvdubdps5D3djjAkgkKwT918VNOz65pEHFaYTeWcukmJmH5SwsA9Tn2ObQ==" + }, + "@jridgewell/source-map": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.3.tgz", + "integrity": "sha512-b+fsZXeLYi9fEULmfBrhxn4IrPlINf8fiNarzTof004v3lFdntdwa9PF7vFJqm3mg7s+ScJMxXaE3Acp1irZcg==", + "requires": { + "@jridgewell/gen-mapping": "^0.3.0", + "@jridgewell/trace-mapping": "^0.3.9" + }, + "dependencies": { + "@jridgewell/gen-mapping": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz", + "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==", + "requires": { + "@jridgewell/set-array": "^1.0.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.9" + } + } + } }, "@jridgewell/sourcemap-codec": { "version": "1.4.13", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.13.tgz", - "integrity": "sha512-GryiOJmNcWbovBxTfZSF71V/mXbgcV3MewDe3kIMCLyIh5e7SKAeUZs+rMnJ8jkMolZ/4/VsdBmMrw3l+VdZ3w==", - "dev": true + "integrity": "sha512-GryiOJmNcWbovBxTfZSF71V/mXbgcV3MewDe3kIMCLyIh5e7SKAeUZs+rMnJ8jkMolZ/4/VsdBmMrw3l+VdZ3w==" }, "@jridgewell/trace-mapping": { "version": "0.3.13", "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.13.tgz", "integrity": "sha512-o1xbKhp9qnIAoHJSWd6KlCZfqslL4valSF81H8ImioOAxluWYWOpWkpyktY2vnt4tbrX9XYaxovq6cgowaJp2w==", - "dev": true, "requires": { "@jridgewell/resolve-uri": "^3.0.3", "@jridgewell/sourcemap-codec": "^1.4.10" @@ -1405,6 +1422,21 @@ "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.2.0.tgz", "integrity": "sha512-VkE3KLBmJwcCaVARtQpfuKcKv8gcBmUubrfHGF84dXuuW6jgsRYxPtzcIhPyK9WAPpRt2/xY6zkD9MnRaJzSyw==" }, + "@swc/helpers": { + "version": "0.3.17", + "resolved": "https://registry.npmjs.org/@swc/helpers/-/helpers-0.3.17.tgz", + "integrity": "sha512-tb7Iu+oZ+zWJZ3HJqwx8oNwSDIU440hmVMDPhpACWQWnrZHK99Bxs70gT1L2dnr5Hg50ZRWEFkQCAnOVVV0z1Q==", + "requires": { + "tslib": "^2.4.0" + }, + "dependencies": { + "tslib": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.5.0.tgz", + "integrity": "sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg==" + } + } + }, "@szmarczak/http-timer": { "version": "4.0.6", "resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-4.0.6.tgz", @@ -1533,9 +1565,9 @@ } }, "@types/eslint": { - "version": "8.21.2", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.21.2.tgz", - "integrity": "sha512-EMpxUyystd3uZVByZap1DACsMXvb82ypQnGn89e1Y0a+LYu3JJscUd/gqhRsVFDkaD2MIiWo0MT8EfXr3DGRKw==", + "version": "8.37.0", + "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.37.0.tgz", + "integrity": "sha512-Piet7dG2JBuDIfohBngQ3rCt7MgO9xCO4xIMKxBThCq5PNRB91IjlJ10eJVwfoNtvTErmxLzwBZ7rHZtbOMmFQ==", "requires": { "@types/estree": "*", "@types/json-schema": "*" @@ -1551,9 +1583,9 @@ } }, "@types/estree": { - "version": "0.0.51", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.51.tgz", - "integrity": "sha512-CuPgU6f3eT/XgKKPqKd/gLZV1Xmvf1a2R5POBOGQa6uv82xpls89HU5zKeVoyR8XzHd1RGNOlQlvUe3CFkjWNQ==" + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.0.tgz", + "integrity": "sha512-WulqXMDUTYAXCjZnk6JtIHPigp55cVtDgDrO2gHRwhyJto21+1zbVCtOYB2L1F9w4qCQ0rOGWBnBe0FNTiEJIQ==" }, "@types/express": { "version": "4.17.13", @@ -2155,12 +2187,6 @@ "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==" }, - "amdefine": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/amdefine/-/amdefine-1.0.1.tgz", - "integrity": "sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU=", - "optional": true - }, "ansi-html-community": { "version": "0.0.8", "resolved": "https://registry.npmjs.org/ansi-html-community/-/ansi-html-community-0.0.8.tgz", @@ -2200,11 +2226,6 @@ "integrity": "sha512-hNfzcOV8W4NdualtqBFPyVO+54DSJuZGY9qT4pRroB6S9e3iiido2ISIC5h9R2sPJ8H3FHCIiEnsv1lPXO3KtQ==", "dev": true }, - "array-from": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/array-from/-/array-from-2.1.1.tgz", - "integrity": "sha1-z+nYwmYoudxa7MYqn12PHzUsEZU=" - }, "array-union": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/array-union/-/array-union-3.0.1.tgz", @@ -2252,58 +2273,6 @@ } } }, - "ast-transform": { - "version": "0.0.0", - "resolved": "https://registry.npmjs.org/ast-transform/-/ast-transform-0.0.0.tgz", - "integrity": "sha1-dJRAWIh9goPhidlUYAlHvJj+AGI=", - "requires": { - "escodegen": "~1.2.0", - "esprima": "~1.0.4", - "through": "~2.3.4" - }, - "dependencies": { - "escodegen": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.2.0.tgz", - "integrity": "sha1-Cd55Z3kcyVi3+Jot220jRRrzJ+E=", - "requires": { - "esprima": "~1.0.4", - "estraverse": "~1.5.0", - "esutils": "~1.0.0", - "source-map": "~0.1.30" - } - }, - "esprima": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-1.0.4.tgz", - "integrity": "sha1-n1V+CPw7TSbs6d00+Pv0drYlha0=" - }, - "estraverse": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-1.5.1.tgz", - "integrity": "sha1-hno+jlip+EYYr7bC3bzZFrfLr3E=" - }, - "esutils": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-1.0.0.tgz", - "integrity": "sha1-gVHTWOIMisx/t0XnRywAJf5JZXA=" - }, - "source-map": { - "version": "0.1.43", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.1.43.tgz", - "integrity": "sha1-wkvBRspRfBRx9drL4lcbK3+eM0Y=", - "optional": true, - "requires": { - "amdefine": ">=0.0.4" - } - } - } - }, - "ast-types": { - "version": "0.7.8", - "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.7.8.tgz", - "integrity": "sha1-kC0uDWDQcb3NRtwRXhgJ7RHBOKk=" - }, "asynckit": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", @@ -2973,6 +2942,7 @@ "version": "6.26.0", "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz", "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=", + "dev": true, "requires": { "core-js": "^2.4.0", "regenerator-runtime": "^0.11.0" @@ -3184,9 +3154,9 @@ "integrity": "sha1-EQPWvADPv6jPyaJZmrUYxVZD2j8=" }, "bootstrap-table": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/bootstrap-table/-/bootstrap-table-1.20.2.tgz", - "integrity": "sha512-6j9zfjjK6VZyJj8KsH+LnGczqglmMvMctGAoEAKDvrQ92ExQbA3mHGYPQr9iPrzoyeGL8+6Dyx6LqJbWmWmBoA==" + "version": "1.21.3", + "resolved": "https://registry.npmjs.org/bootstrap-table/-/bootstrap-table-1.21.3.tgz", + "integrity": "sha512-y6PLHxJJVqIVXoMWrnwPsA8dKqvy9An8Iz7WuuimuLU1i0jIT9+Xzg6NXqBBilHOwp0dUAw9vfgNLvCVq2wdJQ==" }, "brace-expansion": { "version": "1.1.11", @@ -3205,26 +3175,15 @@ "fill-range": "^7.0.1" } }, - "brfs": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/brfs/-/brfs-2.0.2.tgz", - "integrity": "sha512-IrFjVtwu4eTJZyu8w/V2gxU7iLTtcHih67sgEdzrhjLBMHp2uYefUBfdM4k2UvcuWMgV7PQDZHSLeNWnLFKWVQ==", - "requires": { - "quote-stream": "^1.0.1", - "resolve": "^1.1.5", - "static-module": "^3.0.2", - "through2": "^2.0.0" - } - }, "brorand": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", "integrity": "sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8=" }, "brotli": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/brotli/-/brotli-1.3.2.tgz", - "integrity": "sha1-UlqcrU/LqWR119OI9q7LE+7VL0Y=", + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/brotli/-/brotli-1.3.3.tgz", + "integrity": "sha512-oTKjJdShmDuGW94SyyaoQvAjf30dZaHnjJ8uAF+u2/vGJkJbJPJAT1gDiOJP5v1Zb6f9KEyW/1HpuaWIXtGHPg==", "requires": { "base64-js": "^1.1.2" } @@ -3396,31 +3355,6 @@ "safe-buffer": "^5.1.2" } }, - "browserify-optional": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/browserify-optional/-/browserify-optional-1.0.1.tgz", - "integrity": "sha1-HhNyLP3g2F8SFnbCpyztUzoBiGk=", - "requires": { - "ast-transform": "0.0.0", - "ast-types": "^0.7.0", - "browser-resolve": "^1.8.1" - }, - "dependencies": { - "browser-resolve": { - "version": "1.11.3", - "resolved": "https://registry.npmjs.org/browser-resolve/-/browser-resolve-1.11.3.tgz", - "integrity": "sha512-exDi1BYWB/6raKHmDTCicQfTkqwN5fioMFV4j8BsfMU4R2DK/QfZfK7kOVkmWCNANf0snkBzqGqAJBao9gZMdQ==", - "requires": { - "resolve": "1.1.7" - } - }, - "resolve": { - "version": "1.1.7", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.1.7.tgz", - "integrity": "sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs=" - } - } - }, "browserify-rsa": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.1.0.tgz", @@ -3505,11 +3439,6 @@ "ieee754": "^1.1.4" } }, - "buffer-equal": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/buffer-equal/-/buffer-equal-0.0.1.tgz", - "integrity": "sha1-kbx0sR6kBbyRa8aqkI+q+ltKrEs=" - }, "buffer-from": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", @@ -3626,15 +3555,15 @@ }, "dependencies": { "core-js": { - "version": "3.22.5", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.22.5.tgz", - "integrity": "sha512-VP/xYuvJ0MJWRAobcmQ8F2H6Bsn+s7zqAAjFaHGBMc5AQm7zaelhD1LGduFn2EehEcQcU+br6t+fwbpQ5d1ZWA==", + "version": "3.30.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.30.1.tgz", + "integrity": "sha512-ZNS5nbiSwDTq4hFosEDqm65izl2CWmLz0hARJMyNQBgkUZMIF51cQiMvIQKA6hvuaeWxQDP3hEedM1JZIgTldQ==", "optional": true }, "regenerator-runtime": { - "version": "0.13.9", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.9.tgz", - "integrity": "sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA==", + "version": "0.13.11", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz", + "integrity": "sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==", "optional": true } } @@ -3950,46 +3879,6 @@ "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" }, - "concat-stream": { - "version": "1.6.2", - "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.6.2.tgz", - "integrity": "sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==", - "requires": { - "buffer-from": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^2.2.2", - "typedarray": "^0.0.6" - }, - "dependencies": { - "process-nextick-args": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" - }, - "readable-stream": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", - "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "requires": { - "safe-buffer": "~5.1.0" - } - } - } - }, "connect-history-api-fallback": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/connect-history-api-fallback/-/connect-history-api-fallback-1.6.0.tgz", @@ -4048,6 +3937,7 @@ "version": "1.8.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.8.0.tgz", "integrity": "sha512-+OQdjP49zViI/6i7nIJpA8rAl4sV/JdPfU9nZs3VqOwGIgizICvuN2ru6fMd+4llL0tar18UYJXfZ/TWtmhUjA==", + "dev": true, "requires": { "safe-buffer": "~5.1.1" } @@ -4075,7 +3965,8 @@ "core-js": { "version": "2.6.12", "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.12.tgz", - "integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==" + "integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==", + "dev": true }, "core-js-compat": { "version": "3.23.2", @@ -4406,15 +4297,6 @@ "css-tree": "^1.1.2" } }, - "d": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/d/-/d-1.0.1.tgz", - "integrity": "sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==", - "requires": { - "es5-ext": "^0.10.50", - "type": "^1.0.1" - } - }, "dash-ast": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/dash-ast/-/dash-ast-1.0.0.tgz", @@ -4468,23 +4350,127 @@ } }, "deep-equal": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-1.1.1.tgz", - "integrity": "sha512-yd9c5AdiqVcR+JjcwUQb9DkhJc8ngNr0MahEBGvDiJw8puWab2yZlh+nkasOnZP+EGTAP6rRp2JzJhJZzvNF8g==", + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.0.tgz", + "integrity": "sha512-RdpzE0Hv4lhowpIUKKMJfeH6C1pXdtT1/it80ubgWqwI3qpuxUBpC1S4hnHg+zjnuOoDkzUtUCEEkG+XG5l3Mw==", "requires": { - "is-arguments": "^1.0.4", - "is-date-object": "^1.0.1", - "is-regex": "^1.0.4", - "object-is": "^1.0.1", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.2", + "get-intrinsic": "^1.1.3", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.1", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", "object-keys": "^1.1.1", - "regexp.prototype.flags": "^1.2.0" + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.4.3", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + }, + "dependencies": { + "available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==" + }, + "define-properties": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.0.tgz", + "integrity": "sha512-xvqAVKGfT1+UAvPwKTVw/njhdQ8ZhXK4lI0bCIuCMrp2up9nPnaDftrLtmpTazqd1o+UY4zgzU+avtMbDP+ldA==", + "requires": { + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + } + }, + "get-intrinsic": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.0.tgz", + "integrity": "sha512-L049y6nFOuom5wGyRc3/gdTLO94dySVKRACj1RmJZBQXlbTMhtNIgkWkUHq+jYmZvKf14EW1EoJnnjbmoHij0Q==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.3" + } + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + }, + "is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-typed-array": { + "version": "1.1.10", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.10.tgz", + "integrity": "sha512-PJqgEHiWZvMpaFZ3uTc8kHPM4+4ADTlDniuQL7cU/UDA0Ql7F70yGfHph3cLNe+c9toaigv+DFzTJKhc2CtO6A==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, + "object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + } + }, + "which-typed-array": { + "version": "1.1.9", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.9.tgz", + "integrity": "sha512-w9c4xkx6mPidwp7180ckYWfMmvxpjlZuIudNtDf4N/tTAUB8VJbX25qZoAsrtGuYNnGw3pa0AXgbGKRB8/EceA==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0", + "is-typed-array": "^1.1.10" + } + } } }, - "deep-is": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", - "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==" - }, "default-gateway": { "version": "6.0.3", "resolved": "https://registry.npmjs.org/default-gateway/-/default-gateway-6.0.3.tgz", @@ -4659,9 +4645,9 @@ } }, "dompurify": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-2.3.7.tgz", - "integrity": "sha512-fsVZLywBd3awZIG3qU4JEdw7DCb0uUCajTfWRrLhsgKjTBd5CIIluPoAkNfco05GuNYQGj4/+bQIhlq96eT9eQ==", + "version": "2.4.5", + "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-2.4.5.tgz", + "integrity": "sha512-jggCCd+8Iqp4Tsz0nIvpcb22InKEBrGz5dw3EQJMs8HPJDsKbFIO3STYtAvCfDx26Muevn1MHVI0XxjgFfmiSA==", "optional": true }, "domutils": { @@ -4827,10 +4813,57 @@ "string.prototype.trimstart": "^1.0.3" } }, + "es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + }, + "dependencies": { + "get-intrinsic": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.0.tgz", + "integrity": "sha512-L049y6nFOuom5wGyRc3/gdTLO94dySVKRACj1RmJZBQXlbTMhtNIgkWkUHq+jYmZvKf14EW1EoJnnjbmoHij0Q==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.3" + } + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + }, + "is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + } + } + }, "es-module-lexer": { - "version": "0.9.3", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-0.9.3.tgz", - "integrity": "sha512-1HQ2M2sPtxwnvOvT1ZClHyQDiggdNjURWpY2we6aMKCQiUVxTmVs2UYPLIrD84sS+kMdUwfBSylbJPwNnBrnHQ==" + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.2.1.tgz", + "integrity": "sha512-9978wrXM50Y4rTMmW5kXIC09ZdXQZqkE4mxhwkd8VbzsGkXGPgV4zWuqQJgCEzYngdo2dYDa0l8xhX4fkSwJSg==" }, "es-to-primitive": { "version": "1.2.1", @@ -4842,71 +4875,6 @@ "is-symbol": "^1.0.2" } }, - "es5-ext": { - "version": "0.10.61", - "resolved": "https://registry.npmjs.org/es5-ext/-/es5-ext-0.10.61.tgz", - "integrity": "sha512-yFhIqQAzu2Ca2I4SE2Au3rxVfmohU9Y7wqGR+s7+H7krk26NXhIRAZDgqd6xqjCEFUomDEA3/Bo/7fKmIkW1kA==", - "requires": { - "es6-iterator": "^2.0.3", - "es6-symbol": "^3.1.3", - "next-tick": "^1.1.0" - } - }, - "es6-iterator": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/es6-iterator/-/es6-iterator-2.0.3.tgz", - "integrity": "sha1-p96IkUGgWpSwhUQDstCg+/qY87c=", - "requires": { - "d": "1", - "es5-ext": "^0.10.35", - "es6-symbol": "^3.1.1" - } - }, - "es6-map": { - "version": "0.1.5", - "resolved": "https://registry.npmjs.org/es6-map/-/es6-map-0.1.5.tgz", - "integrity": "sha1-kTbgUD3MBqMBaQ8LsU/042TpSfA=", - "requires": { - "d": "1", - "es5-ext": "~0.10.14", - "es6-iterator": "~2.0.1", - "es6-set": "~0.1.5", - "es6-symbol": "~3.1.1", - "event-emitter": "~0.3.5" - } - }, - "es6-set": { - "version": "0.1.5", - "resolved": "https://registry.npmjs.org/es6-set/-/es6-set-0.1.5.tgz", - "integrity": "sha1-0rPsXU2ADO2BjbU40ol02wpzzLE=", - "requires": { - "d": "1", - "es5-ext": "~0.10.14", - "es6-iterator": "~2.0.1", - "es6-symbol": "3.1.1", - "event-emitter": "~0.3.5" - }, - "dependencies": { - "es6-symbol": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/es6-symbol/-/es6-symbol-3.1.1.tgz", - "integrity": "sha1-vwDvT9q2uhtG7Le2KbTH7VcVzHc=", - "requires": { - "d": "1", - "es5-ext": "~0.10.14" - } - } - } - }, - "es6-symbol": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/es6-symbol/-/es6-symbol-3.1.3.tgz", - "integrity": "sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA==", - "requires": { - "d": "^1.0.1", - "ext": "^1.1.2" - } - }, "escalade": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", @@ -4924,26 +4892,6 @@ "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", "dev": true }, - "escodegen": { - "version": "1.14.3", - "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.14.3.tgz", - "integrity": "sha512-qFcX0XJkdg+PB3xjZZG/wKSuT1PnQWx57+TVSjIMmILd2yC/6ByYElPwJnslDsuWuSAp4AwJGumarAAmJch5Kw==", - "requires": { - "esprima": "^4.0.1", - "estraverse": "^4.2.0", - "esutils": "^2.0.2", - "optionator": "^0.8.1", - "source-map": "~0.6.1" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "optional": true - } - } - }, "eslint-scope": { "version": "5.1.1", "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz", @@ -4953,11 +4901,6 @@ "estraverse": "^4.1.1" } }, - "esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" - }, "esrecurse": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", @@ -4978,15 +4921,11 @@ "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==" }, - "estree-is-function": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/estree-is-function/-/estree-is-function-1.0.0.tgz", - "integrity": "sha512-nSCWn1jkSq2QAtkaVLJZY2ezwcFO161HVc174zL1KPW3RJ+O6C3eJb8Nx7OXzvhoEv+nLgSR1g71oWUHUDTrJA==" - }, "esutils": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha1-dNLrTeC42hKTcRkQ1Qd1ubcQ72Q=" + "integrity": "sha1-dNLrTeC42hKTcRkQ1Qd1ubcQ72Q=", + "dev": true }, "etag": { "version": "1.8.1", @@ -4999,15 +4938,6 @@ "resolved": "https://registry.npmjs.org/eve-raphael/-/eve-raphael-0.5.0.tgz", "integrity": "sha1-F8dUt5K+7z+maE15z1pHxjxM2jA=" }, - "event-emitter": { - "version": "0.3.5", - "resolved": "https://registry.npmjs.org/event-emitter/-/event-emitter-0.3.5.tgz", - "integrity": "sha1-34xp7vFkeSPHFXuc6DhAYQsCzDk=", - "requires": { - "d": "1", - "es5-ext": "~0.10.14" - } - }, "eventemitter3": { "version": "4.0.7", "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", @@ -5106,21 +5036,6 @@ } } }, - "ext": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/ext/-/ext-1.6.0.tgz", - "integrity": "sha512-sdBImtzkq2HpkdRLtlLWDa6w4DX22ijZLKx8BMPUuKe1c5lbN6xwQDQCxSfxBQnHZ13ls/FH0MQZx/q/gr6FQg==", - "requires": { - "type": "^2.5.0" - }, - "dependencies": { - "type": { - "version": "2.6.0", - "resolved": "https://registry.npmjs.org/type/-/type-2.6.0.tgz", - "integrity": "sha512-eiDBDOmkih5pMbo9OqsqPRGMljLodLcwd5XD5JbtNB0o89xZAwynY9EdCDsJU7LtcVCClu9DvM7/0Ep1hYX3EQ==" - } - } - }, "fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -5143,11 +5058,6 @@ "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", "integrity": "sha1-h0v2nG9ATCtdmcSBNBOZ/VWJJjM=" }, - "fast-levenshtein": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=" - }, "fast-safe-stringify": { "version": "2.0.7", "resolved": "https://registry.npmjs.org/fast-safe-stringify/-/fast-safe-stringify-2.0.7.tgz", @@ -5313,42 +5223,27 @@ "integrity": "sha1-j6jPBBGhoxr9B7BtKQK7n8gVoTM=" }, "fontkit": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/fontkit/-/fontkit-1.8.1.tgz", - "integrity": "sha512-BsNCjDoYRxmNWFdAuK1y9bQt+igIxGtTC9u/jSFjR9MKhmI00rP1fwSvERt+5ddE82544l0XH5mzXozQVUy2Tw==", + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/fontkit/-/fontkit-1.9.0.tgz", + "integrity": "sha512-HkW/8Lrk8jl18kzQHvAw9aTHe1cqsyx5sDnxncx652+CIfhawokEPkeM3BoIC+z/Xv7a0yMr0f3pRRwhGH455g==", "requires": { - "babel-runtime": "^6.26.0", - "brfs": "^2.0.0", - "brotli": "^1.2.0", - "browserify-optional": "^1.0.1", - "clone": "^1.0.4", - "deep-equal": "^1.0.0", + "@swc/helpers": "^0.3.13", + "brotli": "^1.3.2", + "clone": "^2.1.2", + "deep-equal": "^2.0.5", "dfa": "^1.2.0", - "restructure": "^0.5.3", - "tiny-inflate": "^1.0.2", - "unicode-properties": "^1.2.2", - "unicode-trie": "^0.3.0" - }, - "dependencies": { - "clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha1-2jCcwmPfFZlMaIypAheco8fNfH4=" - }, - "pako": { - "version": "0.2.9", - "resolved": "https://registry.npmjs.org/pako/-/pako-0.2.9.tgz", - "integrity": "sha1-8/dSL073gjSNqBYbrZ7P1Rv4OnU=" - }, - "unicode-trie": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/unicode-trie/-/unicode-trie-0.3.1.tgz", - "integrity": "sha1-1nHd3YkQGgi6w3tqUWEBBgIFIIU=", - "requires": { - "pako": "^0.2.5", - "tiny-inflate": "^1.0.0" - } - } + "restructure": "^2.0.1", + "tiny-inflate": "^1.0.3", + "unicode-properties": "^1.3.1", + "unicode-trie": "^2.0.0" + } + }, + "for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "requires": { + "is-callable": "^1.1.3" } }, "foreach": { @@ -14872,6 +14767,11 @@ "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", "integrity": "sha1-pWiZ0+o8m6uHS7l3O3xe3pL0iV0=" }, + "functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==" + }, "gensync": { "version": "1.0.0-beta.2", "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", @@ -14959,6 +14859,31 @@ } } }, + "gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "requires": { + "get-intrinsic": "^1.1.3" + }, + "dependencies": { + "get-intrinsic": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.0.tgz", + "integrity": "sha512-L049y6nFOuom5wGyRc3/gdTLO94dySVKRACj1RmJZBQXlbTMhtNIgkWkUHq+jYmZvKf14EW1EoJnnjbmoHij0Q==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.3" + } + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + } + } + }, "got": { "version": "11.8.5", "resolved": "https://registry.npmjs.org/got/-/got-11.8.5.tgz", @@ -15011,17 +14936,45 @@ "ansi-regex": "^2.0.0" } }, + "has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==" + }, "has-flag": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", "dev": true }, + "has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "requires": { + "get-intrinsic": "^1.1.1" + } + }, "has-symbols": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", "integrity": "sha1-n1IUdYpEGWxAbZvXbOv4HsLdMeg=" }, + "has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "requires": { + "has-symbols": "^1.0.2" + }, + "dependencies": { + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + } + } + }, "hash-base": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-3.1.0.tgz", @@ -15316,11 +15269,6 @@ "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", "dev": true }, - "icheck": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/icheck/-/icheck-1.0.2.tgz", - "integrity": "sha1-BtCNo9R65EjBU7Jjm4bprX/fcSg=" - }, "iconv-lite": { "version": "0.4.24", "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", @@ -15513,6 +15461,33 @@ } } }, + "internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "requires": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + }, + "dependencies": { + "get-intrinsic": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.0.tgz", + "integrity": "sha512-L049y6nFOuom5wGyRc3/gdTLO94dySVKRACj1RmJZBQXlbTMhtNIgkWkUHq+jYmZvKf14EW1EoJnnjbmoHij0Q==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.3" + } + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + } + } + }, "interpret": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/interpret/-/interpret-2.2.0.tgz", @@ -15552,12 +15527,64 @@ "call-bind": "^1.0.0" } }, + "is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + }, + "dependencies": { + "available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==" + }, + "get-intrinsic": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.0.tgz", + "integrity": "sha512-L049y6nFOuom5wGyRc3/gdTLO94dySVKRACj1RmJZBQXlbTMhtNIgkWkUHq+jYmZvKf14EW1EoJnnjbmoHij0Q==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.3" + } + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + }, + "is-typed-array": { + "version": "1.1.10", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.10.tgz", + "integrity": "sha512-PJqgEHiWZvMpaFZ3uTc8kHPM4+4ADTlDniuQL7cU/UDA0Ql7F70yGfHph3cLNe+c9toaigv+DFzTJKhc2CtO6A==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + } + } + } + }, "is-arrayish": { "version": "0.2.1", "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", "dev": true }, + "is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "requires": { + "has-bigints": "^1.0.1" + } + }, "is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", @@ -15567,6 +15594,15 @@ "binary-extensions": "^2.0.0" } }, + "is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, "is-buffer": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", @@ -15620,6 +15656,11 @@ "is-extglob": "^2.1.1" } }, + "is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==" + }, "is-negative-zero": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.1.tgz", @@ -15630,6 +15671,14 @@ "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" }, + "is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, "is-plain-obj": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-3.0.0.tgz", @@ -15654,12 +15703,33 @@ "has-symbols": "^1.0.1" } }, + "is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==" + }, + "is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "requires": { + "call-bind": "^1.0.2" + } + }, "is-stream": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", "dev": true }, + "is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, "is-symbol": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", @@ -15680,6 +15750,20 @@ "has-symbols": "^1.0.1" } }, + "is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==" + }, + "is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, "is-what": { "version": "3.14.1", "resolved": "https://registry.npmjs.org/is-what/-/is-what-3.14.1.tgz", @@ -15855,9 +15939,9 @@ }, "dependencies": { "core-js": { - "version": "3.22.5", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.22.5.tgz", - "integrity": "sha512-VP/xYuvJ0MJWRAobcmQ8F2H6Bsn+s7zqAAjFaHGBMc5AQm7zaelhD1LGduFn2EehEcQcU+br6t+fwbpQ5d1ZWA==", + "version": "3.30.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.30.1.tgz", + "integrity": "sha512-ZNS5nbiSwDTq4hFosEDqm65izl2CWmLz0hARJMyNQBgkUZMIF51cQiMvIQKA6hvuaeWxQDP3hEedM1JZIgTldQ==", "optional": true } } @@ -16276,15 +16360,6 @@ } } }, - "levn": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", - "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", - "requires": { - "prelude-ls": "~1.1.2", - "type-check": "~0.3.2" - } - }, "lilconfig": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-2.0.5.tgz", @@ -16292,19 +16367,18 @@ "dev": true }, "linebreak": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/linebreak/-/linebreak-1.0.2.tgz", - "integrity": "sha512-bJwSRsJeAmaZYnkcwl5sCQNfSDAhBuXxb6L27tb+qkBRtUQSSTUa5bcgCPD6hFEkRNlpWHfK7nFMmcANU7ZP1w==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/linebreak/-/linebreak-1.1.0.tgz", + "integrity": "sha512-MHp03UImeVhB7XZtjd0E4n6+3xr5Dq/9xI/5FptGk5FrbDR3zagPa2DS6U8ks/3HjbKWG9Q1M2ufOzxV2qLYSQ==", "requires": { "base64-js": "0.0.8", - "brfs": "^2.0.2", - "unicode-trie": "^1.0.0" + "unicode-trie": "^2.0.0" }, "dependencies": { "base64-js": { "version": "0.0.8", "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-0.0.8.tgz", - "integrity": "sha1-EQHpVE9KdrG8OybUUsqW16NeeXg=" + "integrity": "sha512-3XSA2cR/h/73EzlXXdU6YNycmYI7+kicTxks4eJg2g39biHR84slg2+des+p7iHYhbRg/udIS4TD53WabcOUkw==" } } }, @@ -16411,14 +16485,6 @@ "yallist": "^4.0.0" } }, - "magic-string": { - "version": "0.25.1", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.25.1.tgz", - "integrity": "sha512-sCuTz6pYom8Rlt4ISPFn6wuFodbKMIHUMv4Qko9P17dpxb7s52KJTmRuZZqHdGmLCK9AOcDare039nRIcfdkEg==", - "requires": { - "sourcemap-codec": "^1.4.1" - } - }, "md5": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/md5/-/md5-2.3.0.tgz", @@ -16756,11 +16822,6 @@ "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==" }, - "next-tick": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/next-tick/-/next-tick-1.1.0.tgz", - "integrity": "sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ==" - }, "no-case": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/no-case/-/no-case-3.0.4.tgz", @@ -17081,19 +17142,6 @@ "is-wsl": "^2.2.0" } }, - "optionator": { - "version": "0.8.3", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.3.tgz", - "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", - "requires": { - "deep-is": "~0.1.3", - "fast-levenshtein": "~2.0.6", - "levn": "~0.3.0", - "prelude-ls": "~1.1.2", - "type-check": "~0.3.2", - "word-wrap": "~1.2.3" - } - }, "os-browserify": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/os-browserify/-/os-browserify-0.3.0.tgz", @@ -17329,7 +17377,7 @@ "performance-now": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", - "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", + "integrity": "sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==", "optional": true }, "picocolors": { @@ -18002,11 +18050,6 @@ "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.1.0.tgz", "integrity": "sha512-97DXOFbQJhk71ne5/Mt6cOu6yxsSfM0QGQyl0L25Gca4yGWEGJaig7l7gbCX623VqTBNGLRLaVUCnNkcedlRSQ==" }, - "prelude-ls": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", - "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=" - }, "prettier": { "version": "1.19.1", "resolved": "https://registry.npmjs.org/prettier/-/prettier-1.19.1.tgz", @@ -18129,16 +18172,6 @@ "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-5.1.1.tgz", "integrity": "sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==" }, - "quote-stream": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/quote-stream/-/quote-stream-1.0.2.tgz", - "integrity": "sha1-hJY/jJwmuULhU/7rU6rnRlK34LI=", - "requires": { - "buffer-equal": "0.0.1", - "minimist": "^1.1.3", - "through2": "^2.0.0" - } - }, "raf": { "version": "3.4.1", "resolved": "https://registry.npmjs.org/raf/-/raf-3.4.1.tgz", @@ -18289,7 +18322,8 @@ "regenerator-runtime": { "version": "0.11.1", "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz", - "integrity": "sha1-vgWtf5v30i4Fb5cmzuUBf78Z4uk=" + "integrity": "sha1-vgWtf5v30i4Fb5cmzuUBf78Z4uk=", + "dev": true }, "regenerator-transform": { "version": "0.10.1", @@ -18303,12 +18337,13 @@ } }, "regexp.prototype.flags": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.3.1.tgz", - "integrity": "sha512-JiBdRBq91WlY7uRJ0ds7R+dU02i6LKi8r3BuQhNXn+kmeLN+EfHhfjqMRis1zJxnlu88hq/4dx0P2OP3APRTOA==", + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.4.3.tgz", + "integrity": "sha512-fjggEOO3slI6Wvgjwflkc4NFRCTZAu5CnNfBd5qOMYhWdn67nJBBu34/TkD++eeFmd8C9r9jfXJ27+nSiRkSUA==", "requires": { "call-bind": "^1.0.2", - "define-properties": "^1.1.3" + "define-properties": "^1.1.3", + "functions-have-names": "^1.2.2" } }, "regexpu-core": { @@ -18421,12 +18456,9 @@ } }, "restructure": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/restructure/-/restructure-0.5.4.tgz", - "integrity": "sha1-9U591WNZD7NP1r9Vh2EJrsyyjeg=", - "requires": { - "browserify-optional": "^1.0.0" - } + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/restructure/-/restructure-2.0.1.tgz", + "integrity": "sha512-e0dOpjm5DseomnXx2M5lpdZ5zoHqF1+bqdMJUohoYVVQa7cBdnk7fdmeI6byNWP/kiME72EeTiSypTCVnpLiDg==" }, "retry": { "version": "0.13.1", @@ -18442,7 +18474,7 @@ "rgbcolor": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/rgbcolor/-/rgbcolor-1.0.1.tgz", - "integrity": "sha1-1lBezbMEplldom+ktDMHMGd1lF0=", + "integrity": "sha512-9aZLIrhRaD97sgVhtJOW6ckOEh6/GnvQtdVNfdZ6s67+3/XwLS9lBcQYzEEhYVeUowN7pRzMLsyGhK2i/xvWbw==", "optional": true }, "rimraf": { @@ -18496,27 +18528,6 @@ "ajv-keywords": "^3.5.2" } }, - "scope-analyzer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/scope-analyzer/-/scope-analyzer-2.1.2.tgz", - "integrity": "sha512-5cfCmsTYV/wPaRIItNxatw02ua/MThdIUNnUOCYp+3LSEJvnG804ANw2VLaavNILIfWXF1D1G2KNANkBBvInwQ==", - "requires": { - "array-from": "^2.1.1", - "dash-ast": "^2.0.1", - "es6-map": "^0.1.5", - "es6-set": "^0.1.5", - "es6-symbol": "^3.1.1", - "estree-is-function": "^1.0.0", - "get-assigned-identifiers": "^1.1.0" - }, - "dependencies": { - "dash-ast": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/dash-ast/-/dash-ast-2.0.1.tgz", - "integrity": "sha512-5TXltWJGc+RdnabUGzhRae1TRq6m4gr+3K2wQX0is5/F2yS6MJXJvLyI3ErAnsAXuJoGqvfVD5icRgim07DrxQ==" - } - } - }, "select-hose": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/select-hose/-/select-hose-2.0.0.tgz", @@ -18576,6 +18587,7 @@ "version": "6.0.0", "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz", "integrity": "sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==", + "dev": true, "requires": { "randombytes": "^2.1.0" } @@ -18675,11 +18687,6 @@ "kind-of": "^6.0.2" } }, - "shallow-copy": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/shallow-copy/-/shallow-copy-0.0.1.tgz", - "integrity": "sha1-QV9CcC1z2BAzApLMXuhurhoRoXA=" - }, "shasum-object": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/shasum-object/-/shasum-object-1.0.0.tgz", @@ -18723,7 +18730,6 @@ "version": "1.0.4", "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", - "dev": true, "requires": { "call-bind": "^1.0.0", "get-intrinsic": "^1.0.2", @@ -18801,11 +18807,6 @@ } } }, - "sourcemap-codec": { - "version": "1.4.8", - "resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz", - "integrity": "sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==" - }, "spdy": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/spdy/-/spdy-4.0.2.tgz", @@ -18913,72 +18914,6 @@ "integrity": "sha512-EeNzTVfj+1In7aSLPKDD03F/ly4RxEuF/EX0YcOG0cKoPXs+SLZxDawQbexQDBzwROs4VKLWTOaZQlZkGBFEIQ==", "optional": true }, - "static-eval": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/static-eval/-/static-eval-2.1.0.tgz", - "integrity": "sha512-agtxZ/kWSsCkI5E4QifRwsaPs0P0JmZV6dkLz6ILYfFYQGn+5plctanRN+IC8dJRiFkyXHrwEE3W9Wmx67uDbw==", - "requires": { - "escodegen": "^1.11.1" - } - }, - "static-module": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/static-module/-/static-module-3.0.4.tgz", - "integrity": "sha512-gb0v0rrgpBkifXCa3yZXxqVmXDVE+ETXj6YlC/jt5VzOnGXR2C15+++eXuMDUYsePnbhf+lwW0pE1UXyOLtGCw==", - "requires": { - "acorn-node": "^1.3.0", - "concat-stream": "~1.6.0", - "convert-source-map": "^1.5.1", - "duplexer2": "~0.1.4", - "escodegen": "^1.11.1", - "has": "^1.0.1", - "magic-string": "0.25.1", - "merge-source-map": "1.0.4", - "object-inspect": "^1.6.0", - "readable-stream": "~2.3.3", - "scope-analyzer": "^2.0.1", - "shallow-copy": "~0.0.1", - "static-eval": "^2.0.5", - "through2": "~2.0.3" - }, - "dependencies": { - "merge-source-map": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/merge-source-map/-/merge-source-map-1.0.4.tgz", - "integrity": "sha1-pd5GU42uhNQRTMXqArR3KmNGcB8=", - "requires": { - "source-map": "^0.5.6" - } - }, - "process-nextick-args": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" - }, - "readable-stream": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", - "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "requires": { - "safe-buffer": "~5.1.0" - } - } - } - }, "statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -18991,6 +18926,14 @@ "integrity": "sha512-/c645XdExBypL01TpFKiG/3RAa/Qmu+zRi0MwAmrdEkwHNuN0ebo8ccAXBBDa5Z0QOJgBskUIbuCK91x0sCVEw==", "dev": true }, + "stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "requires": { + "internal-slot": "^1.0.4" + } + }, "stream-browserify": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-3.0.0.tgz", @@ -19261,9 +19204,9 @@ } }, "tableexport.jquery.plugin": { - "version": "1.26.0", - "resolved": "https://registry.npmjs.org/tableexport.jquery.plugin/-/tableexport.jquery.plugin-1.26.0.tgz", - "integrity": "sha512-PMad8npkQviiZG/J0kV6zphmcpNwMglxbxZjGR/7DtcKOTfiOzpcQQFIjHVqpnnKgpHHzOfV6GB9km6EkUAt4A==", + "version": "1.27.0", + "resolved": "https://registry.npmjs.org/tableexport.jquery.plugin/-/tableexport.jquery.plugin-1.27.0.tgz", + "integrity": "sha512-aJ6XBeqtPqV8P2v8vvKNa54SGp9R4V4CIwaIhA1WTkflvoYaWqCyTmf/O6WH5kKBvDpva+RhLnYwsPHEPwdSsg==", "requires": { "file-saver": ">=2.0.1", "html2canvas": ">=1.0.0", @@ -19282,6 +19225,7 @@ "version": "5.10.0", "resolved": "https://registry.npmjs.org/terser/-/terser-5.10.0.tgz", "integrity": "sha512-AMmF99DMfEDiRJfxfY5jj5wNH/bYO09cniSqhfoyxc8sFoYIgkJy86G04UoZU5VjlpnplVu0K6Tx6E9b5+DlHA==", + "dev": true, "requires": { "commander": "^2.20.0", "source-map": "~0.7.2", @@ -19291,12 +19235,14 @@ "commander": { "version": "2.20.3", "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", - "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==" + "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", + "dev": true }, "source-map": { "version": "0.7.3", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz", - "integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==" + "integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==", + "dev": true } } }, @@ -19304,6 +19250,7 @@ "version": "5.3.0", "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.0.tgz", "integrity": "sha512-LPIisi3Ol4chwAaPP8toUJ3L4qCM1G0wao7L3qNv57Drezxj6+VEyySpPw4B1HSO2Eg/hDY/MNF5XihCAoqnsQ==", + "dev": true, "requires": { "jest-worker": "^27.4.1", "schema-utils": "^3.1.1", @@ -19315,12 +19262,14 @@ "@types/json-schema": { "version": "7.0.9", "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.9.tgz", - "integrity": "sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ==" + "integrity": "sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ==", + "dev": true }, "schema-utils": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "dev": true, "requires": { "@types/json-schema": "^7.0.8", "ajv": "^6.12.5", @@ -19330,7 +19279,8 @@ "source-map": { "version": "0.6.1", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true } } }, @@ -19454,19 +19404,6 @@ "resolved": "https://registry.npmjs.org/tty-browserify/-/tty-browserify-0.0.1.tgz", "integrity": "sha512-C3TaO7K81YvjCgQH9Q1S3R3P3BtN3RIM8n+OvX4il1K1zgE8ZhI0op7kClgkxtutIE8hQrcrHBXvIheqKUUCxw==" }, - "type": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/type/-/type-1.2.0.tgz", - "integrity": "sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==" - }, - "type-check": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", - "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", - "requires": { - "prelude-ls": "~1.1.2" - } - }, "type-is": { "version": "1.6.18", "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", @@ -19522,28 +19459,12 @@ "dev": true }, "unicode-properties": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/unicode-properties/-/unicode-properties-1.3.1.tgz", - "integrity": "sha512-nIV3Tf3LcUEZttY/2g4ZJtGXhWwSkuLL+rCu0DIAMbjyVPj+8j5gNVz4T/sVbnQybIsd5SFGkPKg/756OY6jlA==", + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/unicode-properties/-/unicode-properties-1.4.1.tgz", + "integrity": "sha512-CLjCCLQ6UuMxWnbIylkisbRj31qxHPAurvena/0iwSVbQ2G1VY5/HjV0IRabOEbDHlzZlRdCrD4NhB0JtU40Pg==", "requires": { "base64-js": "^1.3.0", "unicode-trie": "^2.0.0" - }, - "dependencies": { - "pako": { - "version": "0.2.9", - "resolved": "https://registry.npmjs.org/pako/-/pako-0.2.9.tgz", - "integrity": "sha1-8/dSL073gjSNqBYbrZ7P1Rv4OnU=" - }, - "unicode-trie": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/unicode-trie/-/unicode-trie-2.0.0.tgz", - "integrity": "sha512-x7bc76x0bm4prf1VLg79uhAzKw8DVboClSN5VxJuQ+LKDOVEW9CdH+VY7SP+vX7xCYQqzzgQpFqz15zeLvAtZQ==", - "requires": { - "pako": "^0.2.5", - "tiny-inflate": "^1.0.0" - } - } } }, "unicode-property-aliases-ecmascript": { @@ -19553,9 +19474,9 @@ "dev": true }, "unicode-trie": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/unicode-trie/-/unicode-trie-1.0.0.tgz", - "integrity": "sha512-v5raLKsobbFbWLMoX9+bChts/VhPPj3XpkNr/HbqkirXR1DPk8eo9IYKyvk0MQZFkaoRsFj2Rmaqgi2rfAZYtA==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/unicode-trie/-/unicode-trie-2.0.0.tgz", + "integrity": "sha512-x7bc76x0bm4prf1VLg79uhAzKw8DVboClSN5VxJuQ+LKDOVEW9CdH+VY7SP+vX7xCYQqzzgQpFqz15zeLvAtZQ==", "requires": { "pako": "^0.2.5", "tiny-inflate": "^1.0.0" @@ -19564,7 +19485,7 @@ "pako": { "version": "0.2.9", "resolved": "https://registry.npmjs.org/pako/-/pako-0.2.9.tgz", - "integrity": "sha1-8/dSL073gjSNqBYbrZ7P1Rv4OnU=" + "integrity": "sha512-NUcwaKxUxWrZLpDG+z/xZaCgQITkA/Dv4V/T6bw7VON6l1Xz/VnrBqrYjZQ12TamKHzITTfOEIYUj48y2KXImA==" } } }, @@ -19758,12 +19679,12 @@ } }, "webpack": { - "version": "5.76.1", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.76.1.tgz", - "integrity": "sha512-4+YIK4Abzv8172/SGqObnUjaIHjLEuUasz9EwQj/9xmPPkYJy2Mh03Q/lJfSD3YLzbxy5FeTq5Uw0323Oh6SJQ==", + "version": "5.79.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.79.0.tgz", + "integrity": "sha512-3mN4rR2Xq+INd6NnYuL9RC9GAmc1ROPKJoHhrZ4pAjdMFEkJJWrsPw8o2JjCIyQyTu7rTXYn4VG6OpyB3CobZg==", "requires": { "@types/eslint-scope": "^3.7.3", - "@types/estree": "^0.0.51", + "@types/estree": "^1.0.0", "@webassemblyjs/ast": "1.11.1", "@webassemblyjs/wasm-edit": "1.11.1", "@webassemblyjs/wasm-parser": "1.11.1", @@ -19772,7 +19693,7 @@ "browserslist": "^4.14.5", "chrome-trace-event": "^1.0.2", "enhanced-resolve": "^5.10.0", - "es-module-lexer": "^0.9.0", + "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", @@ -19783,31 +19704,86 @@ "neo-async": "^2.6.2", "schema-utils": "^3.1.0", "tapable": "^2.1.1", - "terser-webpack-plugin": "^5.1.3", + "terser-webpack-plugin": "^5.3.7", "watchpack": "^2.4.0", "webpack-sources": "^3.2.3" }, "dependencies": { + "@jridgewell/resolve-uri": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", + "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==" + }, + "@jridgewell/sourcemap-codec": { + "version": "1.4.14", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", + "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==" + }, + "@jridgewell/trace-mapping": { + "version": "0.3.18", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.18.tgz", + "integrity": "sha512-w+niJYzMHdd7USdiH2U6869nqhD2nbfZXND5Yp93qIbEmnDNk7PD48o+YchRVpzMU7M6jVCbenTR7PA1FLQ9pA==", + "requires": { + "@jridgewell/resolve-uri": "3.1.0", + "@jridgewell/sourcemap-codec": "1.4.14" + } + }, "@types/json-schema": { "version": "7.0.11", "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.11.tgz", "integrity": "sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ==" }, + "commander": { + "version": "2.20.3", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", + "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==" + }, "graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==" + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" }, "schema-utils": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", - "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.2.tgz", + "integrity": "sha512-pvjEHOgWc9OWA/f/DE3ohBWTD6EleVLf7iFUkoSwAxttdBhB9QUebQgxER2kWueOvRJXPHNnyrvvh9eZINB8Eg==", "requires": { "@types/json-schema": "^7.0.8", "ajv": "^6.12.5", "ajv-keywords": "^3.5.2" } }, + "serialize-javascript": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.1.tgz", + "integrity": "sha512-owoXEFjWRllis8/M1Q+Cw5k8ZH40e3zhp/ovX+Xr/vi1qj6QesbyXXViFbpNvWvPNAD62SutwEXavefrLJWj7w==", + "requires": { + "randombytes": "^2.1.0" + } + }, + "terser": { + "version": "5.16.9", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.16.9.tgz", + "integrity": "sha512-HPa/FdTB9XGI2H1/keLFZHxl6WNvAI4YalHGtDQTlMnJcoqSab1UwL4l1hGEhs6/GmLHBZIg/YgB++jcbzoOEg==", + "requires": { + "@jridgewell/source-map": "^0.3.2", + "acorn": "^8.5.0", + "commander": "^2.20.0", + "source-map-support": "~0.5.20" + } + }, + "terser-webpack-plugin": { + "version": "5.3.7", + "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.7.tgz", + "integrity": "sha512-AfKwIktyP7Cu50xNjXF/6Qb5lBNzYaWpU6YfoX3uZicTx0zTy0stDDCsvjDapKsSDvOeWo5MEq4TmdBy2cNoHw==", + "requires": { + "@jridgewell/trace-mapping": "^0.3.17", + "jest-worker": "^27.4.5", + "schema-utils": "^3.1.1", + "serialize-javascript": "^6.0.1", + "terser": "^5.16.5" + } + }, "webpack-sources": { "version": "3.2.3", "resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-3.2.3.tgz", @@ -20117,6 +20093,29 @@ "isexe": "^2.0.0" } }, + "which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "requires": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + } + }, + "which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "requires": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + } + }, "which-typed-array": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.4.tgz", @@ -20147,11 +20146,6 @@ "resolved": "https://registry.npmjs.org/word/-/word-0.3.0.tgz", "integrity": "sha512-OELeY0Q61OXpdUfTp+oweA/vtLVg5VDOXh+3he3PNzLGG/y0oylSOC1xRVj0+l4vQ3tj/bB1HVHv1ocXkQceFA==" }, - "word-wrap": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", - "integrity": "sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==" - }, "wrap-ansi": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", @@ -20224,11 +20218,11 @@ } }, "xmldoc": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/xmldoc/-/xmldoc-1.1.2.tgz", - "integrity": "sha512-ruPC/fyPNck2BD1dpz0AZZyrEwMOrWTO5lDdIXS91rs3wtm4j+T8Rp2o+zoOYkkAxJTZRPOSnOGei1egoRmKMQ==", + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/xmldoc/-/xmldoc-1.3.0.tgz", + "integrity": "sha512-y7IRWW6PvEnYQZNZFMRLNJw+p3pezM4nKYPfr15g4OOW9i8VpeydycFuipE2297OvZnh3jSb2pxOt9QpkZUVng==", "requires": { - "sax": "^1.2.1" + "sax": "^1.2.4" } }, "xtend": { diff --git a/package.json b/package.json index 442513a9f9..6c1df03834 100644 --- a/package.json +++ b/package.json @@ -34,11 +34,10 @@ "bootstrap-colorpicker": "^2.5.3", "bootstrap-datepicker": "^1.9.0", "bootstrap-less": "^3.3.8", - "bootstrap-table": "1.20.2", + "bootstrap-table": "1.21.3", "chart.js": "^2.9.4", "css-loader": "^4.0.0", "ekko-lightbox": "^5.1.1", - "icheck": "^1.0.2", "imagemin": "^8.0.1", "jquery-form-validator": "^2.3.79", "jquery-slimscroll": "^1.3.8", @@ -52,9 +51,9 @@ "papaparse": "^4.3.3", "select2": "4.0.13", "sheetjs": "^2.0.0", - "tableexport.jquery.plugin": "1.26.0", + "tableexport.jquery.plugin": "1.27.0", "tether": "^1.4.0", "vue-resource": "^1.5.2", - "webpack": "^5.76.0" + "webpack": "^5.76.2" } } diff --git a/public/css/build/app.css b/public/css/build/app.css index b67a5f6a1c..558970fa05 100644 Binary files a/public/css/build/app.css and b/public/css/build/app.css differ diff --git a/public/css/build/overrides.css b/public/css/build/overrides.css index 7d0450d520..37ec7d15c3 100644 Binary files a/public/css/build/overrides.css and b/public/css/build/overrides.css differ diff --git a/public/css/dist/all.css b/public/css/dist/all.css index f1f0b46d30..8585073ccb 100644 Binary files a/public/css/dist/all.css and b/public/css/dist/all.css differ diff --git a/public/css/dist/bootstrap-table.css b/public/css/dist/bootstrap-table.css index b95d3d2b77..4cc91443e4 100644 Binary files a/public/css/dist/bootstrap-table.css and b/public/css/dist/bootstrap-table.css differ diff --git a/public/js/build/app.js b/public/js/build/app.js index 3c65e5fa81..000ab0bf37 100644 Binary files a/public/js/build/app.js and b/public/js/build/app.js differ diff --git a/public/js/build/vendor.js b/public/js/build/vendor.js index b5ee42d9f6..68a04d9a7a 100644 Binary files a/public/js/build/vendor.js and b/public/js/build/vendor.js differ diff --git a/public/js/dist/all.js b/public/js/dist/all.js index f8861c6b0a..0293da7fce 100644 Binary files a/public/js/dist/all.js and b/public/js/dist/all.js differ diff --git a/public/js/dist/bootstrap-table.js b/public/js/dist/bootstrap-table.js index 0fafbbff9b..0ded615dc6 100644 Binary files a/public/js/dist/bootstrap-table.js and b/public/js/dist/bootstrap-table.js differ diff --git a/public/mix-manifest.json b/public/mix-manifest.json index 0e447acd4e..7142f3d899 100644 --- a/public/mix-manifest.json +++ b/public/mix-manifest.json @@ -1,8 +1,8 @@ { - "/js/build/app.js": "/js/build/app.js?id=bcb572126085fb7637accdcff1e0c0c6", + "/js/build/app.js": "/js/build/app.js?id=7caeae38608edd96421f8ef59d33f5f6", "/css/dist/skins/skin-blue.css": "/css/dist/skins/skin-blue.css?id=f677207c6cf9678eb539abecb408c374", - "/css/build/overrides.css": "/css/build/overrides.css?id=d9175e3d9b9074397343dddebfe23888", - "/css/build/app.css": "/css/build/app.css?id=dcb8aa9f4501a370214a67442e88daf0", + "/css/build/overrides.css": "/css/build/overrides.css?id=ce23fa22306439befbf49e8e63adb4e0", + "/css/build/app.css": "/css/build/app.css?id=2e40bdf6f6d3d6d6954c391a0a91285e", "/css/build/AdminLTE.css": "/css/build/AdminLTE.css?id=dc383f8560a8d4adb51d44fb4043e03b", "/css/dist/skins/skin-orange.css": "/css/dist/skins/skin-orange.css?id=6f0563e726c2fe4fab4026daaa5bfdf2", "/css/dist/skins/skin-orange-dark.css": "/css/dist/skins/skin-orange-dark.css?id=f343f659ca1d45534d2c2c3cc30fb619", @@ -18,9 +18,7 @@ "/css/dist/skins/skin-green.css": "/css/dist/skins/skin-green.css?id=0a82a6ae6bb4e58fe62d162c4fb50397", "/css/dist/skins/skin-contrast.css": "/css/dist/skins/skin-contrast.css?id=da6c7997d9de2f8329142399f0ce50da", "/css/dist/skins/skin-red.css": "/css/dist/skins/skin-red.css?id=44bf834f2110504a793dadec132a5898", - "/css/dist/all.css": "/css/dist/all.css?id=0314c741a636de602ec952468eb171f3", - "/css/blue.png": "/css/blue.png?id=e83a6c29e04fe851f2122815b2e4b150", - "/css/blue@2x.png": "/css/blue@2x.png?id=51135dd4d24f88f5de0b2414bd51dac5", + "/css/dist/all.css": "/css/dist/all.css?id=1faccd9b34013f9893ed467fa3ddcb39", "/css/dist/signature-pad.css": "/css/dist/signature-pad.css?id=6a89d3cd901305e66ced1cf5f13147f7", "/css/dist/signature-pad.min.css": "/css/dist/signature-pad.min.css?id=6a89d3cd901305e66ced1cf5f13147f7", "/css/webfonts/fa-brands-400.ttf": "/css/webfonts/fa-brands-400.ttf?id=2df05d4beaa48550d71234e8dca79141", @@ -31,10 +29,10 @@ "/css/webfonts/fa-solid-900.woff2": "/css/webfonts/fa-solid-900.woff2?id=6707d0247b0bca1b4964bab435e3c0d6", "/css/webfonts/fa-v4compatibility.ttf": "/css/webfonts/fa-v4compatibility.ttf?id=a947172f4fde88e43b4c1a60b01db061", "/css/webfonts/fa-v4compatibility.woff2": "/css/webfonts/fa-v4compatibility.woff2?id=bbc23038a6067c78310d3f19432a3ebf", - "/css/dist/bootstrap-table.css": "/css/dist/bootstrap-table.css?id=ee4896df8b8f008ce73a9a0c2549aefd", - "/js/build/vendor.js": "/js/build/vendor.js?id=47ecbb4bb3b0e02315f391caadbdf971", - "/js/dist/bootstrap-table.js": "/js/dist/bootstrap-table.js?id=14d9a2affec7b066d20fcba2e6e67ad2", - "/js/dist/all.js": "/js/dist/all.js?id=eb7becb7a5a2ebf0dae7926190d95832", + "/css/dist/bootstrap-table.css": "/css/dist/bootstrap-table.css?id=418917c053841ab1aa1b78610a1825e0", + "/js/build/vendor.js": "/js/build/vendor.js?id=3843eca1b2e670b29c1e1cb57e1d7aa7", + "/js/dist/bootstrap-table.js": "/js/dist/bootstrap-table.js?id=7a506bf59323cf5b5fe97f7080fc5ee0", + "/js/dist/all.js": "/js/dist/all.js?id=97b1034b75e3ac29a2eb9770d66c3370", "/css/dist/skins/skin-green.min.css": "/css/dist/skins/skin-green.min.css?id=0a82a6ae6bb4e58fe62d162c4fb50397", "/css/dist/skins/skin-green-dark.min.css": "/css/dist/skins/skin-green-dark.min.css?id=c0d21166315b7c2cdd4819fa4a5e4d1e", "/css/dist/skins/skin-black.min.css": "/css/dist/skins/skin-black.min.css?id=76482123f6c70e866d6b971ba91de7bb", diff --git a/resources/assets/js/snipeit.js b/resources/assets/js/snipeit.js index 95fb268657..70e4f80a8f 100755 --- a/resources/assets/js/snipeit.js +++ b/resources/assets/js/snipeit.js @@ -185,14 +185,6 @@ $(document).ready(function () { } }); - /* - * iCheck checkbox plugin - */ - - $('input[type="checkbox"].minimal, input[type="radio"].minimal').iCheck({ - checkboxClass: 'icheckbox_minimal-blue', - radioClass: 'iradio_minimal-blue' - }); /* @@ -607,26 +599,14 @@ function htmlEntities(str) { })(jQuery); /** - * Universal Livewire Select2 and iCheck integration + * Universal Livewire Select2 integration * * How to use: * - * 1. Set the class of your select2 elements to 'livewire-select2' and your icheck elements to 'livewire-icheck' (as appropriate). - * (For iCheck, you may still need to apply the other iCheck classes like 'minimal' or 'iCheck') + * 1. Set the class of your select2 elements to 'livewire-select2'). * 2. Name your element to match a property in your Livewire component * 3. Add an attribute called 'data-livewire-component' that points to $_instance->id (via `{{ }}` if you're in a blade, * or just $_instance->id if not). - * 4. For iCheck, you need to wrap the 'checkbox' element with wire:ignore - perhaps in the