gitea umzug

This commit is contained in:
2026-03-12 06:16:36 +01:00
parent 1294f0f07c
commit 5cbe4525d1
3 changed files with 386 additions and 499 deletions

View File

@@ -5,23 +5,25 @@ import { OpenPanel } from '@openpanel/web';
providedIn: 'root'
})
export class AnalyticsService {
private openpanel: OpenPanel;
constructor() {
OpenPanel.init({
clientId: 'DEINE_CLIENT_ID', // Aus dem OpenPanel Dashboard
trackScreenViews: true, // Automatisches Tracking von Routenwechseln
this.openpanel = new OpenPanel({
clientId: 'DEINE_CLIENT_ID',
trackScreenViews: true,
trackOutgoingLinks: true,
url: 'https://api.deine-coolify-domain.de' // WICHTIG: Deine eigene API URL!
});
}
// Methode für benutzerdefinierte Events (das "Brett")
trackEvent(name: string, properties?: object) {
openpanel.track(name, properties);
trackEvent(name: string, properties?: Record<string, any>) {
this.openpanel.track(name, properties);
}
// Für deinen Kunden-Login: User identifizieren
identifyUser(userId: string, traits?: object) {
openpanel.identify(userId, traits);
identifyUser(userId: string, traits?: Record<string, any>) {
this.openpanel.identify(userId);
if (traits) {
this.openpanel.setProfile(traits);
}
}
}
}