1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-15 12:25:15 +03:00

Improvements to analytics collection.

This commit is contained in:
mikeller 2018-08-12 20:19:02 +12:00
parent 5a3bda615d
commit 6b7ac3e542
7 changed files with 122 additions and 10 deletions

View file

@ -1,6 +1,6 @@
'use strict';
var Analytics = function (trackingId, userId, appName, appVersion, buildType, optOut, debugMode) {
var Analytics = function (trackingId, userId, appName, appVersion, changesetId, buildType, checkForDebugVersions, optOut, debugMode) {
this._trackingId = trackingId;
this.setOptOut(optOut);
@ -58,6 +58,8 @@ var Analytics = function (trackingId, userId, appName, appVersion, buildType, op
FIRMWARE_CHANNEL: 10,
LOGGING_STATUS: 11,
MCU_ID: 12,
CONFIGURATOR_CHANGESET_ID: 13,
CONFIGURATOR_USE_DEBUG_VERSIONS: 14,
};
this.METRICS = {
@ -66,6 +68,8 @@ var Analytics = function (trackingId, userId, appName, appVersion, buildType, op
};
this.setDimension(this.DIMENSIONS.CONFIGURATOR_BUILD_TYPE, buildType);
this.setDimension(this.DIMENSIONS.CONFIGURATOR_CHANGESET_ID, changesetId);
this.setDimension(this.DIMENSIONS.CONFIGURATOR_USE_DEBUG_VERSIONS, checkForDebugVersions);
this.resetFlightControllerData();
this.resetFirmwareData();