mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-08-02 10:08:39 +00:00
Add google analytics to config
This commit is contained in:
parent
90f70238d1
commit
e09a9fa832
2 changed files with 18 additions and 1 deletions
|
@ -51,6 +51,19 @@
|
|||
<link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5">
|
||||
<meta name="msapplication-TileColor" content="#da532c">
|
||||
<meta name="theme-color" content="#ffffff">
|
||||
|
||||
@if (ServerSettings.Instance.GoogleAnalyticsEnabled)
|
||||
{
|
||||
<!-- Global site tag (gtag.js) - Google Analytics -->
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id=@ServerSettings.Instance.GoogleAnalyticsId"></script>
|
||||
<script>
|
||||
window.dataLayer = window.dataLayer || [];
|
||||
function gtag(){dataLayer.push(arguments);}
|
||||
gtag('js', new Date());
|
||||
|
||||
gtag('config', '@ServerSettings.Instance.GoogleAnalyticsId');
|
||||
</script>
|
||||
}
|
||||
</head>
|
||||
<body>
|
||||
<div class="pageContainer">
|
||||
|
|
|
@ -63,7 +63,7 @@ namespace LBPUnion.ProjectLighthouse.Types.Settings
|
|||
}
|
||||
}
|
||||
|
||||
public const int CurrentConfigVersion = 10; // MUST BE INCREMENTED FOR EVERY CONFIG CHANGE!
|
||||
public const int CurrentConfigVersion = 11; // MUST BE INCREMENTED FOR EVERY CONFIG CHANGE!
|
||||
|
||||
#region Meta
|
||||
|
||||
|
@ -102,5 +102,9 @@ namespace LBPUnion.ProjectLighthouse.Types.Settings
|
|||
public int EntitledSlots { get; set; } = 50;
|
||||
|
||||
public int ListsQuota { get; set; } = 50;
|
||||
|
||||
public bool GoogleAnalyticsEnabled { get; set; } = false;
|
||||
|
||||
public string GoogleAnalyticsId { get; set; } = "";
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue