bcscoder/ganalytic

该软件包最新版本(0.0.1)没有可用的许可证信息。

安装: 5

依赖项: 0

建议者: 0

安全性: 0

星标: 1

关注者: 2

分支: 0

公开问题: 0

语言:HTML

类型:asgard-module

0.0.1 2017-02-02 08:54 UTC

This package is not auto-updated.

Last update: 2024-09-28 20:43:53 UTC


README

# Google Analytic 模块

## 安装 composer require bcscoder/ganalytic

在配置文件夹中创建文件 laravel-analytics.php

<?php

return [

    /*
     * The view id of which you want to display data.
     */
    'view_id' => env('ANALYTICS_VIEW_ID'),

    /*
     * Path to the client secret json file. Take a look at the README of this package
     * to learn how to get this file.
     */
    'service_account_credentials_json' => env('ANALYTICS_JSON_FILE'),
    //'service_account_credentials_json' => storage_path('app/laravel-google-analytics/Juanda Garden-1b2cc7efe5ec.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' => 60 * 24,

    /*
     * The directory where the underlying Google_Client will store it's cache files.
     */
    'cache_location' => storage_path('app/laravel-google-analytics/google-cache/'),

];

`

更新视图 ID 并上传 Google 凭据 JSON 文件。

更多信息请访问: https://github.com/spatie/laravel-analytics