mirror of
https://github.com/frappe/books.git
synced 2024-11-09 15:20:56 +00:00
incr: log setup wizard events
This commit is contained in:
parent
e8041b7d9c
commit
243c41cff4
@ -3,6 +3,8 @@ export type UniqueId = string;
|
||||
export type Timestamp = string;
|
||||
|
||||
export enum Verb {
|
||||
Started = 'started',
|
||||
Completed = 'completed',
|
||||
Created = 'created',
|
||||
Deleted = 'deleted',
|
||||
Submitted = 'submitted',
|
||||
|
@ -216,6 +216,7 @@
|
||||
<script lang="ts">
|
||||
import { setupDummyInstance } from 'dummy';
|
||||
import { t } from 'fyo';
|
||||
import { Verb } from 'fyo/telemetry/types';
|
||||
import { DateTime } from 'luxon';
|
||||
import Button from 'src/components/Button.vue';
|
||||
import LanguageSelector from 'src/components/Controls/LanguageSelector.vue';
|
||||
@ -334,7 +335,7 @@ export default defineComponent({
|
||||
updateConfigFiles(fyo);
|
||||
await fyo.purgeCache();
|
||||
await this.setFiles();
|
||||
|
||||
this.fyo.telemetry.log(Verb.Created, 'dummy-instance');
|
||||
this.creatingDemo = false;
|
||||
},
|
||||
async setFiles() {
|
||||
|
@ -47,7 +47,7 @@
|
||||
<p v-if="loading" class="text-base text-gray-600">
|
||||
{{ t`Loading instance...` }}
|
||||
</p>
|
||||
<Button v-if="!loading" class="w-24" @click="$emit('setup-canceled')">{{
|
||||
<Button v-if="!loading" class="w-24" @click="cancel">{{
|
||||
t`Cancel`
|
||||
}}</Button>
|
||||
<Button
|
||||
@ -72,6 +72,8 @@
|
||||
<script lang="ts">
|
||||
import { DocValue } from 'fyo/core/types';
|
||||
import { Doc } from 'fyo/model/doc';
|
||||
import { Verb } from 'fyo/telemetry/types';
|
||||
import { ModelNameEnum } from 'models/types';
|
||||
import { Field } from 'schemas/types';
|
||||
import Button from 'src/components/Button.vue';
|
||||
import FormContainer from 'src/components/FormContainer.vue';
|
||||
@ -153,6 +155,7 @@ export default defineComponent({
|
||||
// @ts-ignore
|
||||
window.sw = this;
|
||||
}
|
||||
this.fyo.telemetry.log(Verb.Started, ModelNameEnum.SetupWizard);
|
||||
},
|
||||
methods: {
|
||||
async fill() {
|
||||
@ -198,8 +201,13 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
this.loading = true;
|
||||
this.fyo.telemetry.log(Verb.Completed, ModelNameEnum.SetupWizard);
|
||||
this.$emit('setup-complete', this.doc.getValidDict());
|
||||
},
|
||||
cancel() {
|
||||
this.fyo.telemetry.log(Verb.Cancelled, ModelNameEnum.SetupWizard);
|
||||
this.$emit('setup-canceled');
|
||||
},
|
||||
},
|
||||
});
|
||||
</script>
|
||||
|
Loading…
Reference in New Issue
Block a user