1/** 2 * @license Angulartics v0.17.2 3 * (c) 2013 Luis Farzati http://luisfarzati.github.io/angulartics 4 * Universal Analytics update contributed by http://github.com/willmcclellan 5 * License: MIT 6 */ 7!function (a) { 8 "use strict"; 9 a.module("angulartics.google.analytics", ["angulartics"]).config(["$analyticsProvider", function (b) { 10 b.settings.trackRelativePath = !0, 11 b.settings.ga = { 12 additionalAccountNames : void 0 13 }, 14 b.registerPageTrack(function (c) { 15 window._gaq && _gaq.push(["_trackPageview", c]), 16 window.ga && (ga("send", "pageview", c), a.forEach(b.settings.ga.additionalAccountNames, function (a) { 17 ga(a + ".send", "pageview", c) 18 })) 19 }), 20 b.registerEventTrack(function (c, d) { 21 if (d && d.category) { 22 if (d.value) { 23 var e = parseInt(d.value, 10); 24 d.value = isNaN(e) ? 0 : e 25 } 26 if (window.ga) { 27 for (var f = { 28 eventCategory : d.category || null, 29 eventAction : c || null, 30 eventLabel : d.label || null, 31 eventValue : d.value || null, 32 nonInteraction : d.noninteraction || null 33 }, g = 1; 20 >= g; g++) 34 d["dimension" + g.toString()] && (f["dimension" + g.toString()] = d["dimension" + g.toString()]), d["metric" + g.toString()] && (f["metric" + g.toString()] = d["metric" + g.toString()]); 35 ga("send", "event", f), 36 a.forEach(b.settings.ga.additionalAccountNames, function (a) { 37 ga(a + ".send", "event", f) 38 }) 39 } else 40 window._gaq && _gaq.push(["_trackEvent", d.category, c, d.label, d.value, d.noninteraction]) 41 } 42 }), 43 b.registerAddTrans(function (d) { 44 if (d && d.transaction !== undefined) { 45 if (window.ga) { 46 ga('ecommerce:addTransaction', { 47 id: d.transaction, // Transaction ID* 48 affiliation: d.label, // Store Name 49 revenue: d.montantTTC, // Total 50 shipping: d.fdp, // Shipping 51 tax: d.taxes, // Tax 52 city: d.ville, 53 state: d.departement, 54 country: d.pays, 55 currency: d.devise 56 }) 57 } else 58 window._gaq && _gaq.push(["_addTrans", d.transaction, d.label, d.montantTTC, d.taxes, d.fdp, d.ville, d.departement, d.pays]) 59 } 60 console.log(JSON.stringify(d)); 61 }), 62 b.registerAddItem(function (d) { 63 if (d && d.transaction !== undefined) { 64 if (window.ga) { 65 ga('ecommerce:addItem', { 66 id: d.transaction, // Transaction ID* 67 sku: d.codetarif, // Product SKU 68 name: d.produit, // Product Name* 69 category: d.categorie, // Product Category 70 price: d.puTTC, // Price (individual price) 71 quantity: d.quantite // Quantity 72 73 }) 74 } else 75 window._gaq && _gaq.push(["_addItem", d.transaction, d.codetarif, d.produit, d.categorie, d.puTTC, d.quantite]) 76 } 77 console.log(JSON.stringify(d)); 78 }), 79 b.registerTrackTrans(function () { 80 if (window.ga) { 81 ga('ecommerce:send') 82 console.log("ecommerce : send") 83 } 84 window._gaq && _gaq.push(["_trackTrans"]) 85 console.log("_trackTrans"); 86 }) 87 } 88 ]) 89} 90(angular);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.