thedevdojo / voyager

Voyager - The Missing Laravel Admin
https://voyager.devdojo.com
MIT License
11.75k stars 2.67k forks source link

[Feature] Google Analytics config - use access code instead of Oauth client id #4097

Open minhdanh opened 5 years ago

minhdanh commented 5 years ago

Version information

Description of problem

At the moment Google Analytics integration is being done using an Oauth2 client key, which has the following disadvantages:

Proposed solution

I looked at the Google Analytics wordpress plugin and what it is doing is to use an access code (see: https://exactmetrics.com/quick-start-guide/): an admin will configure the access code once, and locked to a property. Any other users log in later can see Google Analytics data without having configure Google Analytics for themselves again. The data is consistent between users.

I'm willing to create a PR for this, but please let me know if that makes sense. Thanks.

minhdanh commented 5 years ago

@emptynick @fletch3555 What do you think about this?

fletch3555 commented 5 years ago

I'm not necessarily opposed to the change, but I'm not sure I understand your reasoning for it. Can you explain what you mean by "each user"?

minhdanh commented 5 years ago

Maybe you're unsure about this? Every user has to authorize with their google account separately. By every user I mean the Voyager admin users. Each of them has to configure Google Analytics on their own to have the GA graphs show up in Voyager dashboard. Using the proposed solution an admin only needs to configure Google Analytics integration once and then other admin can see the GA graphs.

irakliShengelia commented 3 years ago

Stuck with this issue myself. I think that should really be the main way to configure it. What's the point of adding it to the website dashboard if you still need to log in via google.