From: Louis Jeckel Date: Fri, 11 Sep 2020 17:48:27 +0000 (+0200) Subject: ga twill X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=f9ff7bd2716a563b2bd6d92b8f5ea3fbd3264d9d;p=psq.git ga twill --- diff --git a/composer.json b/composer.json index a9a07e0..23b53f1 100644 --- a/composer.json +++ b/composer.json @@ -39,6 +39,7 @@ "psq/psq-theme": "*", "pusher/pusher-php-server": "~4.0", "sentry/sentry-laravel": "1.7.1", + "spatie/laravel-analytics": "^3.10", "spatie/pdf-to-image": "^2.0", "spatie/pdf-to-text": "^1.3", "vaites/php-apache-tika": "^0.9.1" diff --git a/composer.lock b/composer.lock index a9fbdb3..238f80c 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "247a233609ac91be13638bd635f24b12", + "content-hash": "70d746984d1fe596d469cdd574622e82", "packages": [ { "name": "algolia/algoliasearch-client-php", @@ -7021,21 +7021,21 @@ }, { "name": "spatie/laravel-analytics", - "version": "3.10.0", + "version": "3.10.1", "source": { "type": "git", "url": "https://github.com/spatie/laravel-analytics.git", - "reference": "88f20f0a82dfb2263aca082df41011ce46128d69" + "reference": "61eb3a00b799a38f355dc24e378e92f98e71ed6b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/laravel-analytics/zipball/88f20f0a82dfb2263aca082df41011ce46128d69", - "reference": "88f20f0a82dfb2263aca082df41011ce46128d69", + "url": "https://api.github.com/repos/spatie/laravel-analytics/zipball/61eb3a00b799a38f355dc24e378e92f98e71ed6b", + "reference": "61eb3a00b799a38f355dc24e378e92f98e71ed6b", "shasum": "" }, "require": { - "google/apiclient": "^2.0", - "laravel/framework": "^6.0|^7.0", + "google/apiclient": "^2.0|^2.7", + "laravel/framework": "^6.0|^7.0|^8.0", "nesbot/carbon": "^2.0", "php": "^7.2", "symfony/cache": "^4.3|^5.0" @@ -7043,7 +7043,7 @@ "require-dev": { "league/flysystem": ">=1.0.8", "mockery/mockery": "^1.3", - "orchestra/testbench": "^4.0|^5.0", + "orchestra/testbench": "^4.0|^5.0|^6.0", "phpunit/phpunit": "^8.0|^9.0" }, "type": "library", @@ -7084,7 +7084,7 @@ "retrieve", "spatie" ], - "time": "2020-06-26T07:32:16+00:00" + "time": "2020-09-09T08:25:08+00:00" }, { "name": "spatie/once", diff --git a/config/analytics.php b/config/analytics.php new file mode 100644 index 0000000..81b5572 --- /dev/null +++ b/config/analytics.php @@ -0,0 +1,33 @@ + env('ANALYTICS_VIEW_ID', '228741471'), + + /* + * Path to the client secret json file. Take a look at the README of this package + * to learn how to get this file. You can also pass the credentials as an array + * instead of a file path. + */ + 'service_account_credentials_json' => storage_path('app/analytics/prescription-sante-quotidien-69ee22ce96f6.json'), + + /* + * The amount of minutes the Google API responses will be cached. + * If you set this to zero, the responses won't be cached at all. + */ + 'cache_lifetime_in_minutes' => 10, + + /* + * Here you may configure the "store" that the underlying Google_Client will + * use to store it's data. You may also add extra parameters that will + * be passed on setCacheConfig (see docs for google-api-php-client). + * + * Optional parameters: "lifetime", "prefix" + */ + 'cache' => [ + 'store' => 'file', + ], +]; diff --git a/config/twill.php b/config/twill.php index 0939a51..21c8b2b 100644 --- a/config/twill.php +++ b/config/twill.php @@ -18,6 +18,7 @@ return [ ], + 'bucketsRoutes' => [ 'homepage' => 'content' ], @@ -108,6 +109,13 @@ return [ 'admin_app_url' => env('ADMIN_APP_URL', 'admin.' . env('APP_URL')), 'admin_app_path' => env('ADMIN_APP_PATH', ''), +// 'dashboard' => [ +// 'analytics' => [ +// 'enabled' => true, +// 'service_account_credentials_json' => storage_path('app/analytics/prescription-sante-quotidien-69ee22ce96f6.json'), +// ], +// ], + /* |-------------------------------------------------------------------------- | Admin subdomain routing support