Improve telemetry (#2604)

* add node positions in node graph

* add hover events

* add tag count in save event

* populate properties when default

* fix delete and enable node events

* add node and workflow exec events

* lint

* add node graph

* add node id
This commit is contained in:
Ahsan Virani
2022-01-07 17:14:59 +01:00
committed by GitHub
parent df412e9523
commit 57016624b8
14 changed files with 104 additions and 32 deletions

View File

@@ -328,14 +328,14 @@ export default mixins(externalHooks, nodeBase, nodeHelpers, workflowHelpers).ext
},
disableNode () {
this.disableNodes([this.data]);
this.$telemetry.track('User set node enabled status', { node_type: this.data.type, is_enabled: !this.data.disabled, workflow_id: this.$store.getters.workflowId });
this.$telemetry.track('User clicked node hover button', { node_type: this.data.type, button_name: 'disable', workflow_id: this.$store.getters.workflowId });
},
executeNode () {
this.$emit('runWorkflow', this.data.name, 'Node.executeNode');
this.$telemetry.track('User clicked node hover button', { node_type: this.data.type, button_name: 'execute', workflow_id: this.$store.getters.workflowId });
},
deleteNode () {
this.$externalHooks().run('node.deleteNode', { node: this.data});
this.$telemetry.track('User deleted node', { node_type: this.data.type, workflow_id: this.$store.getters.workflowId });
this.$telemetry.track('User clicked node hover button', { node_type: this.data.type, button_name: 'delete', workflow_id: this.$store.getters.workflowId });
Vue.nextTick(() => {
// Wait a tick else vue causes problems because the data is gone
@@ -343,6 +343,7 @@ export default mixins(externalHooks, nodeBase, nodeHelpers, workflowHelpers).ext
});
},
duplicateNode () {
this.$telemetry.track('User clicked node hover button', { node_type: this.data.type, button_name: 'duplicate', workflow_id: this.$store.getters.workflowId });
Vue.nextTick(() => {
// Wait a tick else vue causes problems because the data is gone
this.$emit('duplicateNode', this.data.name);