I'm using google analytics with the new api gtag
. I want to send events that have specific dimensions rather than have common dimensions for each event that are configured in the beginning of the page load.
I'm trying do like this:
parameters.softwareOwner = HelperJSViewBag.getValue("softwareOwner");
parameters.softwareVersion = HelperJSViewBag.getValue("softwareVersion");
parameters.event_category = this.category.name;
parameters.event_label = this.description;
parameters.metricValue = 1;
parameters.customerID = cookieCustomer.id;
parameters.customerSessionID = cookieCustomer.id_session;
parameters.customerPartnerID = localStorageCustomer.partnerID;
parameters.customerName = localStorageCustomer.firstName + " " +
localStorageCustomer.lastName;
gtag('event', parameters.metricName, parameters);
I'm using the tag assistance (by google) to track if the metrics are being sent to google analytics and it is being sent but only with the dimensions event_category
and event_label
.
What I'm doing is possible? If not there is any alternative to accomplish what I want?