From: Vincent Vanwaelscappel Date: Wed, 16 Dec 2020 10:27:50 +0000 (+0100) Subject: wip #3753 @3 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=490ac34ce832cd17f149a061324d6d40859f6002;p=fluidbook-toolbox.git wip #3753 @3 --- diff --git a/app/Console/Commands/Precache.php b/app/Console/Commands/Precache.php new file mode 100644 index 000000000..e82180fcc --- /dev/null +++ b/app/Console/Commands/Precache.php @@ -0,0 +1,89 @@ + 'user', + 'Cache company data' => 'company', + 'Cache permissions data' => 'permissions', + 'Cache fluidbook quote data' => 'fluidbookquote', + 'Cache quiz data' => 'quiz', + ]; + + $user = AuthUser::where('id', self::$_admin)->first(); + backpack_auth()->login($user); + + $this->progressBar = $this->output->createProgressBar(count($actions)); + + $this->line('Begins data caching'); + $this->progressBar->start(); + + + foreach ($actions as $comment => $action) { + $this->line($comment); + $this->$action(); + $this->progressBar->advance(); + } + + $this->line('End of caching data'); + } + + protected function permissions() + { + Permissions::getManagedUsers(5); + } + + protected function company() + { + $companies = Company::withoutGlobalScopes()->get(); + foreach ($companies as $company) { + $company->preCache(); + break; + } + } + + protected function user() + { + $users = User::withoutGlobalScopes()->get(); + foreach ($users as $user) { + $user->preCache(); + break; + } + } + + protected function fluidbookquote() + { + $quotes = FluidbookQuote::withoutGlobalScopes()->get(); + foreach ($quotes as $quote) { + $quote->preCache(); + break; + } + } + + protected function quiz() + { + $quizzes = Quiz::withoutGlobalScopes()->get(); + foreach ($quizzes as $quiz) { + $quiz->preCache(); + break; + } + } + +} diff --git a/app/Console/Commands/WorkshopMigration.php b/app/Console/Commands/WorkshopMigration.php index c3a4948a5..5c6b7e062 100644 --- a/app/Console/Commands/WorkshopMigration.php +++ b/app/Console/Commands/WorkshopMigration.php @@ -56,28 +56,6 @@ class WorkshopMigration extends CubistCommand $this->executeProcessQuiet('php artisan optimize:clear'); } -// protected function importSignatures() -// { -// $map = ['signature_id' => 'id', -// 'nom' => 'name', -// 'active' => 'active']; -// -// Signature::query()->truncate(); -// foreach (DB::table($this->_oldDB . '.signatures')->get() as $e) { -// $c = new Signature(); -// foreach ($map as $old => $new) { -// $c->setAttribute($new, $e->$old); -// } -// $credits = '' . $e->fblink . ''; -// if ($e->partnercredit !== '') { -// $credits = '' . $e->partnerlink . '' . $credits; -// } -// $c->setAttribute('credits', $credits); -// $c->save(); -// } -// -// } - protected function importQuotes() { $map = ['demande_id' => 'id', diff --git a/app/Console/Kernel.php b/app/Console/Kernel.php index b790bc50a..63d894f1e 100644 --- a/app/Console/Kernel.php +++ b/app/Console/Kernel.php @@ -24,6 +24,8 @@ class Kernel extends ConsoleKernel */ protected function schedule(Schedule $schedule) { + $schedule->command('ws:precache')->everyMinute(); + $schedule->command('backup:clean')->daily()->at('04:00'); $schedule->command('backup:run')->daily()->at('05:00'); } diff --git a/app/Models/Company.php b/app/Models/Company.php index 8402220f6..37ee110ef 100644 --- a/app/Models/Company.php +++ b/app/Models/Company.php @@ -1,7 +1,11 @@ 'company', + 'singular' => 'client', + 'plural' => 'clients']; + } diff --git a/app/Models/FluidbookQuote.php b/app/Models/FluidbookQuote.php index 075a6b41f..08b95a9a0 100644 --- a/app/Models/FluidbookQuote.php +++ b/app/Models/FluidbookQuote.php @@ -8,8 +8,6 @@ use App\Http\Controllers\Admin\Operations\FluidbookQuote\AssignOperation; use App\Http\Controllers\Admin\Operations\FluidbookQuote\ConfirmAssignmentOperation; use App\Http\Controllers\Admin\Operations\FluidbookQuote\CreateFromWebsite; use App\Widgets; -use Backpack\CRUD\app\Library\Widget; -use Cubedesigners\UserDatabase\User; use Cubist\Backpack\Http\Controllers\Operations\ShowOperation; use Cubist\Backpack\Magic\Models\CubistMagicAbstractModel; use Illuminate\Database\Eloquent\Builder; @@ -21,7 +19,8 @@ class FluidbookQuote extends CubistMagicAbstractModel 'singular' => 'demande de devis', 'plural' => 'demandes de devis']; - protected $_operations = [/*ShowOperation::class,*/ AssignOperation::class, CreateFromWebsite::class, ConfirmAssignmentOperation::class]; + protected $_operations = [/*ShowOperation::class,*/ + AssignOperation::class, CreateFromWebsite::class, ConfirmAssignmentOperation::class]; protected $_enableClone = false; protected $_enableCreation = false; protected $_enableBulk = false; @@ -44,7 +43,9 @@ class FluidbookQuote extends CubistMagicAbstractModel $this->addField('langs', 'Hidden'); $this->addField('user', 'SelectFromModel', __('Utilisateur'), - ['optionsmodel' => User::class, + [ + 'optionsmodel' => User::class, + 'optionsmodel_global_scopes' => false, 'attribute' => 'companyWithName', 'column_attribute' => 'CompanyWithNameOnTwoLines', 'column' => true, @@ -97,7 +98,7 @@ class FluidbookQuote extends CubistMagicAbstractModel 4 => __('Déjà client'), ], 'column' => true, 'filter' => true]); - $this->addField('notes', 'Textarea', __('Notes'),['column'=>true]); + $this->addField('notes', 'Textarea', __('Notes'), ['column' => true]); $this->addField('origin_column', FluidbookQuoteOrigin::class, __('Origine'), ['column' => true, 'filter' => true]); $this->addField('fluidbooks', 'ModelAttribute', __('Fluidbooks'), ['column' => true, 'column_label' => '', 'attribute' => 'user.e1_ws_count']); diff --git a/app/Models/User.php b/app/Models/User.php index f06cb77ea..ed2254f57 100644 --- a/app/Models/User.php +++ b/app/Models/User.php @@ -2,7 +2,7 @@ namespace App\Models; -class User extends \Cubedesigners\UserDatabase\User +class User extends \Cubedesigners\UserDatabase\Models\User { protected $_syncDbSchema = false; diff --git a/composer.lock b/composer.lock index 5847d007c..7b202e40c 100644 --- a/composer.lock +++ b/composer.lock @@ -518,21 +518,21 @@ }, { "name": "cache/adapter-common", - "version": "1.1.0", + "version": "1.2.0", "source": { "type": "git", "url": "https://github.com/php-cache/adapter-common.git", - "reference": "6320bb5f5574cb88438059b59f8708da6b6f1d32" + "reference": "6b87c5cbdf03be42437b595dbe5de8e97cd1d497" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-cache/adapter-common/zipball/6320bb5f5574cb88438059b59f8708da6b6f1d32", - "reference": "6320bb5f5574cb88438059b59f8708da6b6f1d32", + "url": "https://api.github.com/repos/php-cache/adapter-common/zipball/6b87c5cbdf03be42437b595dbe5de8e97cd1d497", + "reference": "6b87c5cbdf03be42437b595dbe5de8e97cd1d497", "shasum": "" }, "require": { "cache/tag-interop": "^1.0", - "php": "^5.6 || ^7.0", + "php": "^5.6 || ^7.0 || ^8.0", "psr/cache": "^1.0", "psr/log": "^1.0", "psr/simple-cache": "^1.0" @@ -565,7 +565,7 @@ { "name": "Tobias Nyholm", "email": "tobias.nyholm@gmail.com", - "homepage": "https://github.com/Nyholm" + "homepage": "https://github.com/nyholm" } ], "description": "Common classes for PSR-6 adapters", @@ -576,33 +576,34 @@ "tag" ], "support": { - "source": "https://github.com/php-cache/adapter-common/tree/master" + "source": "https://github.com/php-cache/adapter-common/tree/1.2.0" }, - "time": "2018-07-08T13:04:33+00:00" + "time": "2020-12-14T12:17:39+00:00" }, { "name": "cache/filesystem-adapter", - "version": "1.0.0", + "version": "1.1.0", "source": { "type": "git", "url": "https://github.com/php-cache/filesystem-adapter.git", - "reference": "d50680b6dabbe39f9831f5fc9efa61c09d936017" + "reference": "1501ca71502f45114844824209e6a41d87afb221" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-cache/filesystem-adapter/zipball/d50680b6dabbe39f9831f5fc9efa61c09d936017", - "reference": "d50680b6dabbe39f9831f5fc9efa61c09d936017", + "url": "https://api.github.com/repos/php-cache/filesystem-adapter/zipball/1501ca71502f45114844824209e6a41d87afb221", + "reference": "1501ca71502f45114844824209e6a41d87afb221", "shasum": "" }, "require": { "cache/adapter-common": "^1.0", "league/flysystem": "^1.0", - "php": "^5.6 || ^7.0", + "php": "^5.6 || ^7.0 || ^8.0", "psr/cache": "^1.0", "psr/simple-cache": "^1.0" }, "provide": { - "psr/cache-implementation": "^1.0" + "psr/cache-implementation": "^1.0", + "psr/simple-cache-implementation": "^1.0" }, "require-dev": { "cache/integration-tests": "^0.16", @@ -611,7 +612,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "1.1-dev" } }, "autoload": { @@ -635,7 +636,7 @@ { "name": "Tobias Nyholm", "email": "tobias.nyholm@gmail.com", - "homepage": "https://github.com/Nyholm" + "homepage": "https://github.com/nyholm" } ], "description": "A PSR-6 cache implementation using filesystem. This implementation supports tags", @@ -647,27 +648,27 @@ "tag" ], "support": { - "source": "https://github.com/php-cache/filesystem-adapter/tree/master" + "source": "https://github.com/php-cache/filesystem-adapter/tree/1.1.0" }, - "time": "2017-07-16T21:09:25+00:00" + "time": "2020-12-14T12:17:39+00:00" }, { "name": "cache/hierarchical-cache", - "version": "1.0.0", + "version": "1.1.0", "source": { "type": "git", "url": "https://github.com/php-cache/hierarchical-cache.git", - "reference": "97173a5115765f72ccdc90dbc01132a3786ef5fd" + "reference": "ba3746c65461b17154fb855068403670fd7fa2d3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-cache/hierarchical-cache/zipball/97173a5115765f72ccdc90dbc01132a3786ef5fd", - "reference": "97173a5115765f72ccdc90dbc01132a3786ef5fd", + "url": "https://api.github.com/repos/php-cache/hierarchical-cache/zipball/ba3746c65461b17154fb855068403670fd7fa2d3", + "reference": "ba3746c65461b17154fb855068403670fd7fa2d3", "shasum": "" }, "require": { "cache/adapter-common": "^1.0", - "php": "^5.6 || ^7.0", + "php": "^5.6 || ^7.0 || ^8.0", "psr/cache": "^1.0" }, "require-dev": { @@ -676,7 +677,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "1.1-dev" } }, "autoload": { @@ -700,7 +701,7 @@ { "name": "Tobias Nyholm", "email": "tobias.nyholm@gmail.com", - "homepage": "https://github.com/Nyholm" + "homepage": "https://github.com/nyholm" } ], "description": "A helper trait and interface to your PSR-6 cache to support hierarchical keys.", @@ -712,9 +713,9 @@ "psr-6" ], "support": { - "source": "https://github.com/php-cache/hierarchical-cache/tree/master" + "source": "https://github.com/php-cache/hierarchical-cache/tree/1.1.0" }, - "time": "2017-07-16T21:58:17+00:00" + "time": "2020-12-14T12:17:39+00:00" }, { "name": "cache/tag-interop", @@ -1089,21 +1090,31 @@ "source": { "type": "git", "url": "git://git.cubedesigners.com/cubedesigners_userdatabase.git", - "reference": "dca252aac1c06bc61a54cf3fde4a61a4034d8c8a" + "reference": "82d9104d3a0666d3f067032fa0dcda126aeb919c" }, "dist": { "type": "tar", - "url": "https://composer.cubedesigners.com/dist/cubedesigners/userdatabase/cubedesigners-userdatabase-dev-master-a37e90.tar", - "reference": "dca252aac1c06bc61a54cf3fde4a61a4034d8c8a", - "shasum": "6235517745e6dd115dc0572171fe1f21ccb07530" + "url": "https://composer.cubedesigners.com/dist/cubedesigners/userdatabase/cubedesigners-userdatabase-dev-master-33d8b9.tar", + "reference": "82d9104d3a0666d3f067032fa0dcda126aeb919c", + "shasum": "e73f4d84eb08f207dacfef2e2d41e701c6afb48a" }, "require": { "cubist/cms-back": "dev-master" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + }, + "laravel": { + "providers": [ + "Cubedesigners\\UserDatabase\\CubedesignersUserDatabaseServiceProvider" + ] + } + }, "autoload": { "psr-4": { - "Cubedesigners\\UserDatabase\\": "src" + "Cubedesigners\\UserDatabase\\": "src/app" } }, "license": [ @@ -1116,7 +1127,7 @@ } ], "description": "Cubedesigners common users database", - "time": "2020-12-09T07:05:00+00:00" + "time": "2020-12-15T20:25:51+00:00" }, { "name": "cubist/cms-back", @@ -1124,13 +1135,13 @@ "source": { "type": "git", "url": "git://git.cubedesigners.com/cubist_cms-back.git", - "reference": "9833ca5f7ecedeecdd5f8c9062a3f2690386156e" + "reference": "83e296653f0cf4d2cc5cf33518c86d3deb9a618b" }, "dist": { "type": "tar", - "url": "https://composer.cubedesigners.com/dist/cubist/cms-back/cubist-cms-back-dev-master-93ea0b.tar", - "reference": "9833ca5f7ecedeecdd5f8c9062a3f2690386156e", - "shasum": "0cfb6cae6a3bab6659abf087f9201e3fdb3c43b7" + "url": "https://composer.cubedesigners.com/dist/cubist/cms-back/cubist-cms-back-dev-master-dd75cc.tar", + "reference": "83e296653f0cf4d2cc5cf33518c86d3deb9a618b", + "shasum": "89111dc9b83affb7a3f7e2091d9806adce8a4547" }, "require": { "backpack/backupmanager": "^2.0", @@ -1205,7 +1216,7 @@ } ], "description": "Cubist Backpack extension", - "time": "2020-12-09T12:11:14+00:00" + "time": "2020-12-14T18:28:34+00:00" }, { "name": "cubist/cms-front", @@ -3211,16 +3222,16 @@ }, { "name": "lavary/laravel-menu", - "version": "v1.7.7", + "version": "v1.8.0", "source": { "type": "git", "url": "https://github.com/lavary/laravel-menu.git", - "reference": "5592778b3193ae561614ecb107467469b694ab11" + "reference": "02c58d8284c47a33eb365873a02953bff8c95d31" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/lavary/laravel-menu/zipball/5592778b3193ae561614ecb107467469b694ab11", - "reference": "5592778b3193ae561614ecb107467469b694ab11", + "url": "https://api.github.com/repos/lavary/laravel-menu/zipball/02c58d8284c47a33eb365873a02953bff8c95d31", + "reference": "02c58d8284c47a33eb365873a02953bff8c95d31", "shasum": "" }, "require": { @@ -3261,9 +3272,9 @@ ], "support": { "issues": "https://github.com/lavary/laravel-menu/issues", - "source": "https://github.com/lavary/laravel-menu/tree/master" + "source": "https://github.com/lavary/laravel-menu/tree/v1.8.0" }, - "time": "2019-09-06T16:28:16+00:00" + "time": "2020-12-12T18:16:03+00:00" }, { "name": "league/commonmark", @@ -3368,22 +3379,22 @@ }, { "name": "league/csv", - "version": "9.6.1", + "version": "9.6.2", "source": { "type": "git", "url": "https://github.com/thephpleague/csv.git", - "reference": "634322df4aed210fdfbb7c94e434dc860da733d9" + "reference": "f28da6e483bf979bac10e2add384c90ae9983e4e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/csv/zipball/634322df4aed210fdfbb7c94e434dc860da733d9", - "reference": "634322df4aed210fdfbb7c94e434dc860da733d9", + "url": "https://api.github.com/repos/thephpleague/csv/zipball/f28da6e483bf979bac10e2add384c90ae9983e4e", + "reference": "f28da6e483bf979bac10e2add384c90ae9983e4e", "shasum": "" }, "require": { "ext-json": "*", "ext-mbstring": "*", - "php": "^7.2.5" + "php": ">=7.2.5" }, "require-dev": { "ext-curl": "*", @@ -3448,7 +3459,7 @@ "type": "github" } ], - "time": "2020-09-05T08:40:12+00:00" + "time": "2020-12-10T19:40:30+00:00" }, { "name": "league/flysystem", @@ -3976,16 +3987,16 @@ }, { "name": "monolog/monolog", - "version": "2.1.1", + "version": "2.2.0", "source": { "type": "git", "url": "https://github.com/Seldaek/monolog.git", - "reference": "f9eee5cec93dfb313a38b6b288741e84e53f02d5" + "reference": "1cb1cde8e8dd0f70cc0fe51354a59acad9302084" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Seldaek/monolog/zipball/f9eee5cec93dfb313a38b6b288741e84e53f02d5", - "reference": "f9eee5cec93dfb313a38b6b288741e84e53f02d5", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/1cb1cde8e8dd0f70cc0fe51354a59acad9302084", + "reference": "1cb1cde8e8dd0f70cc0fe51354a59acad9302084", "shasum": "" }, "require": { @@ -3998,16 +4009,17 @@ "require-dev": { "aws/aws-sdk-php": "^2.4.9 || ^3.0", "doctrine/couchdb": "~1.0@dev", - "elasticsearch/elasticsearch": "^6.0", + "elasticsearch/elasticsearch": "^7", "graylog2/gelf-php": "^1.4.2", + "mongodb/mongodb": "^1.8", "php-amqplib/php-amqplib": "~2.4", "php-console/php-console": "^3.1.3", - "php-parallel-lint/php-parallel-lint": "^1.0", "phpspec/prophecy": "^1.6.1", + "phpstan/phpstan": "^0.12.59", "phpunit/phpunit": "^8.5", "predis/predis": "^1.1", "rollbar/rollbar": "^1.3", - "ruflin/elastica": ">=0.90 <3.0", + "ruflin/elastica": ">=0.90 <7.0.1", "swiftmailer/swiftmailer": "^5.3|^6.0" }, "suggest": { @@ -4027,7 +4039,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.x-dev" + "dev-main": "2.x-dev" } }, "autoload": { @@ -4043,11 +4055,11 @@ { "name": "Jordi Boggiano", "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" + "homepage": "https://seld.be" } ], "description": "Sends your logs to files, sockets, inboxes, databases and various web services", - "homepage": "http://github.com/Seldaek/monolog", + "homepage": "https://github.com/Seldaek/monolog", "keywords": [ "log", "logging", @@ -4055,7 +4067,7 @@ ], "support": { "issues": "https://github.com/Seldaek/monolog/issues", - "source": "https://github.com/Seldaek/monolog/tree/2.1.1" + "source": "https://github.com/Seldaek/monolog/tree/2.2.0" }, "funding": [ { @@ -4067,7 +4079,7 @@ "type": "tidelift" } ], - "time": "2020-07-23T08:41:23+00:00" + "time": "2020-12-14T13:15:25+00:00" }, { "name": "myclabs/php-enum", @@ -5515,16 +5527,16 @@ }, { "name": "spatie/laravel-backup", - "version": "6.13.1", + "version": "6.14.0", "source": { "type": "git", "url": "https://github.com/spatie/laravel-backup.git", - "reference": "a0ca6662fbc3d008fe9e17b0f74101d139aca6f1" + "reference": "982d8377816eaceac0ac0a78fbf9b0f75fb009db" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/laravel-backup/zipball/a0ca6662fbc3d008fe9e17b0f74101d139aca6f1", - "reference": "a0ca6662fbc3d008fe9e17b0f74101d139aca6f1", + "url": "https://api.github.com/repos/spatie/laravel-backup/zipball/982d8377816eaceac0ac0a78fbf9b0f75fb009db", + "reference": "982d8377816eaceac0ac0a78fbf9b0f75fb009db", "shasum": "" }, "require": { @@ -5588,7 +5600,7 @@ ], "support": { "issues": "https://github.com/spatie/laravel-backup/issues", - "source": "https://github.com/spatie/laravel-backup/tree/6.13.1" + "source": "https://github.com/spatie/laravel-backup/tree/6.14.0" }, "funding": [ { @@ -5600,7 +5612,7 @@ "type": "other" } ], - "time": "2020-12-01T07:29:53+00:00" + "time": "2020-12-09T20:35:29+00:00" }, { "name": "spatie/laravel-googletagmanager", @@ -9548,16 +9560,16 @@ }, { "name": "facade/ignition", - "version": "2.5.2", + "version": "2.5.3", "source": { "type": "git", "url": "https://github.com/facade/ignition.git", - "reference": "08668034beb185fa2ac6f09b1034eaa440952ace" + "reference": "d8dc4f90ed469f9f9313b976fb078c20585d5c99" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/facade/ignition/zipball/08668034beb185fa2ac6f09b1034eaa440952ace", - "reference": "08668034beb185fa2ac6f09b1034eaa440952ace", + "url": "https://api.github.com/repos/facade/ignition/zipball/d8dc4f90ed469f9f9313b976fb078c20585d5c99", + "reference": "d8dc4f90ed469f9f9313b976fb078c20585d5c99", "shasum": "" }, "require": { @@ -9621,7 +9633,7 @@ "issues": "https://github.com/facade/ignition/issues", "source": "https://github.com/facade/ignition" }, - "time": "2020-11-17T09:18:51+00:00" + "time": "2020-12-09T20:25:45+00:00" }, { "name": "facade/ignition-contracts", @@ -9743,16 +9755,16 @@ }, { "name": "fzaninotto/faker", - "version": "v1.9.1", + "version": "v1.9.2", "source": { "type": "git", "url": "https://github.com/fzaninotto/Faker.git", - "reference": "fc10d778e4b84d5bd315dad194661e091d307c6f" + "reference": "848d8125239d7dbf8ab25cb7f054f1a630e68c2e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/fzaninotto/Faker/zipball/fc10d778e4b84d5bd315dad194661e091d307c6f", - "reference": "fc10d778e4b84d5bd315dad194661e091d307c6f", + "url": "https://api.github.com/repos/fzaninotto/Faker/zipball/848d8125239d7dbf8ab25cb7f054f1a630e68c2e", + "reference": "848d8125239d7dbf8ab25cb7f054f1a630e68c2e", "shasum": "" }, "require": { @@ -9791,10 +9803,10 @@ ], "support": { "issues": "https://github.com/fzaninotto/Faker/issues", - "source": "https://github.com/fzaninotto/Faker/tree/v1.9.1" + "source": "https://github.com/fzaninotto/Faker/tree/v1.9.2" }, "abandoned": true, - "time": "2019-12-12T13:22:17+00:00" + "time": "2020-12-11T09:56:16+00:00" }, { "name": "hamcrest/hamcrest-php", @@ -10321,16 +10333,16 @@ }, { "name": "phar-io/version", - "version": "3.0.3", + "version": "3.0.4", "source": { "type": "git", "url": "https://github.com/phar-io/version.git", - "reference": "726c026815142e4f8677b7cb7f2249c9ffb7ecae" + "reference": "e4782611070e50613683d2b9a57730e9a3ba5451" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/726c026815142e4f8677b7cb7f2249c9ffb7ecae", - "reference": "726c026815142e4f8677b7cb7f2249c9ffb7ecae", + "url": "https://api.github.com/repos/phar-io/version/zipball/e4782611070e50613683d2b9a57730e9a3ba5451", + "reference": "e4782611070e50613683d2b9a57730e9a3ba5451", "shasum": "" }, "require": { @@ -10366,9 +10378,9 @@ "description": "Library for handling version information and constraints", "support": { "issues": "https://github.com/phar-io/version/issues", - "source": "https://github.com/phar-io/version/tree/3.0.3" + "source": "https://github.com/phar-io/version/tree/3.0.4" }, - "time": "2020-11-30T09:21:21+00:00" + "time": "2020-12-13T23:18:30+00:00" }, { "name": "phpdocumentor/reflection-common", diff --git a/config/backpack/crud.php b/config/backpack/crud.php index d544593a6..849b140b7 100644 --- a/config/backpack/crud.php +++ b/config/backpack/crud.php @@ -39,7 +39,7 @@ return [ // How many items should be shown by default by the Datatable? // This value can be overwritten on a specific CRUD by calling // $this->crud->setDefaultPageLength(50); - 'defaultPageLength' => 100, + 'defaultPageLength' => 25, // A 1D array of options which will be used for both the displayed option and the value, or // A 2D array in which the first array is used to define the value options and the second array the displayed options diff --git a/config/debugbar.php b/config/debugbar.php new file mode 100644 index 000000000..d17dde2e7 --- /dev/null +++ b/config/debugbar.php @@ -0,0 +1,216 @@ + env('DEBUGBAR_ENABLED', null), + 'except' => [ + 'telescope*', + 'horizon*', + ], + + /* + |-------------------------------------------------------------------------- + | Storage settings + |-------------------------------------------------------------------------- + | + | DebugBar stores data for session/ajax requests. + | You can disable this, so the debugbar stores data in headers/session, + | but this can cause problems with large data collectors. + | By default, file storage (in the storage folder) is used. Redis and PDO + | can also be used. For PDO, run the package migrations first. + | + */ + 'storage' => [ + 'enabled' => true, + 'driver' => 'file', // redis, file, pdo, custom + 'path' => storage_path('debugbar'), // For file driver + 'connection' => null, // Leave null for default connection (Redis/PDO) + 'provider' => '', // Instance of StorageInterface for custom driver + ], + + /* + |-------------------------------------------------------------------------- + | Vendors + |-------------------------------------------------------------------------- + | + | Vendor files are included by default, but can be set to false. + | This can also be set to 'js' or 'css', to only include javascript or css vendor files. + | Vendor files are for css: font-awesome (including fonts) and highlight.js (css files) + | and for js: jquery and and highlight.js + | So if you want syntax highlighting, set it to true. + | jQuery is set to not conflict with existing jQuery scripts. + | + */ + + 'include_vendors' => true, + + /* + |-------------------------------------------------------------------------- + | Capture Ajax Requests + |-------------------------------------------------------------------------- + | + | The Debugbar can capture Ajax requests and display them. If you don't want this (ie. because of errors), + | you can use this option to disable sending the data through the headers. + | + | Optionally, you can also send ServerTiming headers on ajax requests for the Chrome DevTools. + */ + + 'capture_ajax' => true, + 'add_ajax_timing' => false, + + /* + |-------------------------------------------------------------------------- + | Custom Error Handler for Deprecated warnings + |-------------------------------------------------------------------------- + | + | When enabled, the Debugbar shows deprecated warnings for Symfony components + | in the Messages tab. + | + */ + 'error_handler' => false, + + /* + |-------------------------------------------------------------------------- + | Clockwork integration + |-------------------------------------------------------------------------- + | + | The Debugbar can emulate the Clockwork headers, so you can use the Chrome + | Extension, without the server-side code. It uses Debugbar collectors instead. + | + */ + 'clockwork' => false, + + /* + |-------------------------------------------------------------------------- + | DataCollectors + |-------------------------------------------------------------------------- + | + | Enable/disable DataCollectors + | + */ + + 'collectors' => [ + 'phpinfo' => true, // Php version + 'messages' => true, // Messages + 'time' => true, // Time Datalogger + 'memory' => true, // Memory usage + 'exceptions' => true, // Exception displayer + 'log' => true, // Logs from Monolog (merged in messages if enabled) + 'db' => true, // Show database (PDO) queries and bindings + 'views' => false, // Views with their data + 'route' => true, // Current route information + 'auth' => true, // Display Laravel authentication status + 'gate' => false, // Display Laravel Gate checks + 'session' => true, // Display session data + 'symfony_request' => true, // Only one can be enabled.. + 'mail' => true, // Catch mail messages + 'laravel' => true, // Laravel version and environment + 'events' => false, // All events fired + 'default_request' => false, // Regular or special Symfony request logger + 'logs' => false, // Add the latest log messages + 'files' => false, // Show the included files + 'config' => false, // Display config settings + 'cache' => false, // Display cache events + 'models' => false, // Display models + 'livewire' => true, // Display Livewire (when available) + ], + + /* + |-------------------------------------------------------------------------- + | Extra options + |-------------------------------------------------------------------------- + | + | Configure some DataCollectors + | + */ + + 'options' => [ + 'auth' => [ + 'show_name' => true, // Also show the users name/email in the debugbar + ], + 'db' => [ + 'with_params' => true, // Render SQL with the parameters substituted + 'backtrace' => true, // Use a backtrace to find the origin of the query in your files. + 'backtrace_exclude_paths' => [], // Paths to exclude from backtrace. (in addition to defaults) + 'timeline' => true, // Add the queries to the timeline + 'explain' => [ // Show EXPLAIN output on queries + 'enabled' => false, + 'types' => ['SELECT'], // Deprecated setting, is always only SELECT + ], + 'hints' => false, // Show hints for common mistakes + 'show_copy' => false, // Show copy button next to the query + ], + 'mail' => [ + 'full_log' => false, + ], + 'views' => [ + 'data' => false, //Note: Can slow down the application, because the data can be quite large.. + ], + 'route' => [ + 'label' => true, // show complete route on bar + ], + 'logs' => [ + 'file' => null, + ], + 'cache' => [ + 'values' => true, // collect cache values + ], + ], + + /* + |-------------------------------------------------------------------------- + | Inject Debugbar in Response + |-------------------------------------------------------------------------- + | + | Usually, the debugbar is added just before , by listening to the + | Response after the App is done. If you disable this, you have to add them + | in your template yourself. See http://phpdebugbar.com/docs/rendering.html + | + */ + + 'inject' => true, + + /* + |-------------------------------------------------------------------------- + | DebugBar route prefix + |-------------------------------------------------------------------------- + | + | Sometimes you want to set route prefix to be used by DebugBar to load + | its resources from. Usually the need comes from misconfigured web server or + | from trying to overcome bugs like this: http://trac.nginx.org/nginx/ticket/97 + | + */ + 'route_prefix' => '_debugbar', + + /* + |-------------------------------------------------------------------------- + | DebugBar route domain + |-------------------------------------------------------------------------- + | + | By default DebugBar route served from the same domain that request served. + | To override default domain, specify it as a non-empty value. + */ + 'route_domain' => null, + + /* + |-------------------------------------------------------------------------- + | DebugBar theme + |-------------------------------------------------------------------------- + | + | Switches between light and dark theme. If set to auto it will respect system preferences + | Possible values: auto, light, dark + */ + 'theme' => 'auto', +]; diff --git a/public/packages/fluidbook/toolbox/css/style.less b/public/packages/fluidbook/toolbox/css/style.less index 72641f926..c1f3ab24e 100644 --- a/public/packages/fluidbook/toolbox/css/style.less +++ b/public/packages/fluidbook/toolbox/css/style.less @@ -315,3 +315,40 @@ a, a.btn-link { display: block !important; } } + +body.embeded { + .app-header, .app-body .sidebar-pills, .app-footer, main > section { + display: none; + } + + main > div > .row > div { + max-width: 100%; + flex: none; + } +} + +.company-userlist { + width: 100%; + padding: 0 1em; + + table { + margin-top: 3.5em; + width: 100%; + text-align: left; + + tr { + td { + padding: 0 1em; + + &:first-child, &:last-child { + white-space: nowrap; + width: 1px; + } + } + } + } + + .add { + float: right; + } +} diff --git a/resources/views/vendor/backpack/base/inc/sidebar_content.blade.php b/resources/views/vendor/backpack/base/inc/sidebar_content.blade.php index 3a82df3f3..506bc553c 100644 --- a/resources/views/vendor/backpack/base/inc/sidebar_content.blade.php +++ b/resources/views/vendor/backpack/base/inc/sidebar_content.blade.php @@ -38,14 +38,10 @@