refactor: telemetry

* only works with frappe v15.96+
This commit is contained in:
Saqib Ansari
2026-01-14 14:48:05 +05:30
parent 4ace8b2ec0
commit 0aeada4549
15 changed files with 40 additions and 115 deletions

View File

@@ -80,13 +80,13 @@ import {
} from 'frappe-ui'
import { reactive, watch, inject } from 'vue'
import { getFileSize } from '@/utils/'
import { capture } from '@/telemetry'
import { FileText, X } from 'lucide-vue-next'
import { useOnboarding } from 'frappe-ui/frappe'
import { useOnboarding, useTelemetry } from 'frappe-ui/frappe'
const show = defineModel()
const outline = defineModel('outline')
const user = inject('$user')
const { capture } = useTelemetry()
const { updateOnboardingStep } = useOnboarding('learning')
const props = defineProps({

View File

@@ -66,6 +66,7 @@ import { inject, reactive, watch } from 'vue'
import { User } from '@/components/Settings/types'
import { openSettings, cleanError } from '@/utils'
import Link from '@/components/Controls/Link.vue'
import { useTelemetry } from 'frappe-ui/frappe'
interface ZoomAccount {
name: string
@@ -97,6 +98,7 @@ interface ZoomAccounts {
const show = defineModel('show')
const user = inject<User | null>('$user')
const zoomAccounts = defineModel<ZoomAccounts>('zoomAccounts')
const { capture } = useTelemetry()
const account = reactive({
name: '',
@@ -154,6 +156,7 @@ const createAccount = (close: () => void) => {
},
{
onSuccess() {
capture('zoom_account_linked')
zoomAccounts.value?.reload()
close()
toast.success(__('Zoom Account created successfully'))