tango-app-api-analysis-traffic 3.1.0-alpha.11 → 3.1.0-alpha.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/src/controllers/emailers.controllers.js +285 -48
- package/src/controllers/handlebars.js +5 -0
- package/src/hbs/dailyMailerMultiple.hbs +48 -63
- package/src/hbs/dailyMailerSingle.hbs +16 -14
- package/src/hbs/weeklyMailerMultiple.hbs +47 -60
- package/src/hbs/weeklyMailerSingle.hbs +23 -18
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tango-app-api-analysis-traffic",
|
|
3
|
-
"version": "3.1.0-alpha.
|
|
3
|
+
"version": "3.1.0-alpha.13",
|
|
4
4
|
"description": "Traffic Analysis",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"puppeteer": "^23.11.1",
|
|
28
28
|
"swagger-ui-express": "^5.0.1",
|
|
29
29
|
"tango-api-schema": "^2.2.7",
|
|
30
|
-
"tango-app-api-middleware": "^3.1.
|
|
30
|
+
"tango-app-api-middleware": "^3.1.58",
|
|
31
31
|
"winston": "^3.13.1",
|
|
32
32
|
"winston-daily-rotate-file": "^5.0.0"
|
|
33
33
|
},
|
|
@@ -134,23 +134,26 @@ export const createEmailers = async ( req, res ) => {
|
|
|
134
134
|
// // Make for Loop and Get Assigned Stores each users ////
|
|
135
135
|
for ( let i = 0; i < getUserData.length; i++ ) {
|
|
136
136
|
let getUserStores = await getAssinedStoreEmailers( getUserData[i] );
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
137
|
+
|
|
138
|
+
if ( getUserStores.length > 0 ) {
|
|
139
|
+
let currentDate = new Date();
|
|
140
|
+
let emailersInsertData = {
|
|
141
|
+
clientId: requestData.clientId,
|
|
142
|
+
fromDate: requestData.fromDate,
|
|
143
|
+
toDate: requestData.toDate,
|
|
144
|
+
templateType: requestData.templateType,
|
|
145
|
+
status: 'open',
|
|
146
|
+
createdAt: currentDate,
|
|
147
|
+
dateISO: new Date( currentDate.getTime() + kolkataOffset * 60 * 1000 ),
|
|
148
|
+
userEmail: getUserData[i].email,
|
|
149
|
+
userName: getUserData[i].userName,
|
|
150
|
+
storeIds: getUserStores || [],
|
|
151
|
+
};
|
|
152
|
+
// // Insert emailers ////
|
|
153
|
+
let insertOS = await insertOpenSearchData( JSON.parse( process.env.OPENSEARCH ).emailers, emailersInsertData );
|
|
154
|
+
if ( insertOS && insertOS.body.result == 'created' ) {
|
|
155
|
+
emailersIds.push( insertOS.body._id );
|
|
156
|
+
}
|
|
154
157
|
}
|
|
155
158
|
}
|
|
156
159
|
// // Send SQS Message ////
|
|
@@ -289,7 +292,10 @@ export const sendEmailers = async ( req, res ) => {
|
|
|
289
292
|
let storeData = {
|
|
290
293
|
storeId: getStoreSourceData.storeId,
|
|
291
294
|
storeName: getStoreSourceData.storeName,
|
|
292
|
-
storeLocation: getStoreSourceData.storeProfile?.city+' '+getStoreSourceData.storeProfile.pincode,
|
|
295
|
+
// storeLocation: getStoreSourceData.storeProfile?.city+' - '+getStoreSourceData.storeProfile.pincode,
|
|
296
|
+
storeLocation: getStoreSourceData.storeProfile?.city ?
|
|
297
|
+
getStoreSourceData.storeProfile?.city + ( getStoreSourceData.storeProfile?.pincode ? ' - ' + getStoreSourceData.storeProfile.pincode : '' ) :
|
|
298
|
+
'NA',
|
|
293
299
|
storeCount: emailerSourceData._source.storeIds.length-1,
|
|
294
300
|
storeBaseImage: cameraBaseImage,
|
|
295
301
|
};
|
|
@@ -304,8 +310,8 @@ export const sendEmailers = async ( req, res ) => {
|
|
|
304
310
|
templateType: emailerSourceData._source.templateType,
|
|
305
311
|
clientId: emailerSourceData._source.clientId,
|
|
306
312
|
clientName: clientData.clientName,
|
|
307
|
-
storeId: emailerSourceData._source.storeIds
|
|
308
|
-
allStores: emailerSourceData._source.storeIds,
|
|
313
|
+
storeId: emailerSourceData._source.storeIds,
|
|
314
|
+
// allStores: emailerSourceData._source.storeIds,
|
|
309
315
|
fromDate: emailerSourceData._source.fromDate,
|
|
310
316
|
toDate: emailerSourceData._source.toDate,
|
|
311
317
|
templateType: emailerSourceData._source.templateType,
|
|
@@ -319,6 +325,8 @@ export const sendEmailers = async ( req, res ) => {
|
|
|
319
325
|
bufferTime: 30,
|
|
320
326
|
},
|
|
321
327
|
templateId: emailerSourceData._id,
|
|
328
|
+
fromDateFormat: dayjs( emailerSourceData._source.fromDate ).format( 'DD-MM-YYYY' ),
|
|
329
|
+
toDateFormat: dayjs( emailerSourceData._source.toDate ).format( 'DD-MM-YYYY' ),
|
|
322
330
|
};
|
|
323
331
|
// console.log( 'templateData =>', templateData );
|
|
324
332
|
// console.log( 'emailerSourceData =>', emailerSourceData );
|
|
@@ -326,6 +334,7 @@ export const sendEmailers = async ( req, res ) => {
|
|
|
326
334
|
|
|
327
335
|
// // Get Lamda Metrics Data ////
|
|
328
336
|
let lamdaMetrics = await getLamdaMetricsData( templateData );
|
|
337
|
+
// console.log( 'XYZ lamdaMetrics =>', lamdaMetrics );
|
|
329
338
|
|
|
330
339
|
// // Get Lamda Chart Data ///
|
|
331
340
|
let lamdaCharts = await getLamdaChartData( templateData );
|
|
@@ -363,30 +372,31 @@ export const sendEmailers = async ( req, res ) => {
|
|
|
363
372
|
async function getLamdaMetricsData( templateData ) {
|
|
364
373
|
try {
|
|
365
374
|
let resultLamdaMetricsData;
|
|
366
|
-
if ( templateData.
|
|
375
|
+
if ( templateData.storeId.length == 1 && templateData.templateType == 'daily' ) {
|
|
367
376
|
// // Call Lamda API No 1 Single Store Single Date
|
|
368
377
|
// API Number: 1 (Daily Emailer With Single Store)
|
|
369
378
|
resultLamdaMetricsData = await lamdaAPI1( templateData );
|
|
370
379
|
return resultLamdaMetricsData;
|
|
371
|
-
} else if ( templateData.
|
|
380
|
+
} else if ( templateData.storeId.length > 1 && templateData.templateType == 'daily' ) {
|
|
372
381
|
// // Call Lamda API No 2 Multiple Store Single Date
|
|
373
382
|
// API Number: 3 (Daily Emailer With Multi Stores)
|
|
374
383
|
resultLamdaMetricsData = await lamdaAPI3( templateData );
|
|
384
|
+
// console.log( 'ABC resultLamdaMetricsData =>', resultLamdaMetricsData );
|
|
375
385
|
return resultLamdaMetricsData;
|
|
376
|
-
} else if ( templateData.
|
|
386
|
+
} else if ( templateData.storeId.length == 1 && templateData.templateType == 'weekly' ) {
|
|
377
387
|
// // Call Lamda API No 3 Single Store Multiple Date
|
|
378
388
|
// API Number: 2 (Weekly Emailer With Single Store)
|
|
379
389
|
resultLamdaMetricsData = await lamdaAPI2( templateData );
|
|
380
390
|
return resultLamdaMetricsData;
|
|
381
|
-
} else if ( templateData.
|
|
391
|
+
} else if ( templateData.storeId.length > 1 && templateData.templateType == 'weekly' ) {
|
|
382
392
|
// // Call Lamda API No 4 Multiple Store Multiple Date
|
|
383
393
|
// API Number: 4 (Weekly Emailer With Multi Stores)
|
|
384
394
|
resultLamdaMetricsData = await lamdaAPI4( templateData );
|
|
385
395
|
return resultLamdaMetricsData;
|
|
386
|
-
} else if ( templateData.
|
|
396
|
+
} else if ( templateData.storeId.length == 1 && templateData.templateType == 'monthly' ) {
|
|
387
397
|
// // Call Lamda API No 5 Single Store Multiple Date
|
|
388
398
|
|
|
389
|
-
} else if ( templateData.
|
|
399
|
+
} else if ( templateData.storeId.length > 1 && templateData.templateType == 'monthly' ) {
|
|
390
400
|
// // Call Lamda API No 6 Multiple Store Multiple Date
|
|
391
401
|
|
|
392
402
|
} else {
|
|
@@ -645,7 +655,105 @@ async function lamdaAPI3( templateData ) {
|
|
|
645
655
|
if ( !lamdaAPIResultData || lamdaAPIResultData.status_code !== '200' ) {
|
|
646
656
|
return '';
|
|
647
657
|
}
|
|
648
|
-
|
|
658
|
+
// Format metrics data
|
|
659
|
+
// const updatedLamdaMetrics = formatLamdaMetrics(lamdaMetrics);
|
|
660
|
+
let updatedlamdaAPIResultData = lamdaAPIResultData;
|
|
661
|
+
// console.log( 'updatedlamdaAPIResultData 678=>', updatedlamdaAPIResultData );
|
|
662
|
+
|
|
663
|
+
let highData = {
|
|
664
|
+
'storeName': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
665
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.storeName :
|
|
666
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
667
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.storeName :
|
|
668
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
669
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.storeName : // Assuming correct key name
|
|
670
|
+
'NA',
|
|
671
|
+
'storeId': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
672
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.storeId :
|
|
673
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
674
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.storeId :
|
|
675
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
676
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.storeId : // Assuming correct key name
|
|
677
|
+
'NA',
|
|
678
|
+
'vsSameDayLastWeekRate': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
679
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.vsSameDayLastWeekRate :
|
|
680
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
681
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.vsSameDayLastWeekRate :
|
|
682
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
683
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.vsSameDayLastWeekRate : // Assuming correct key name
|
|
684
|
+
'NA',
|
|
685
|
+
'vsSameDayLastWeekComparisonFlag': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
686
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.vsSameDayLastWeekComparisonFlag :
|
|
687
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
688
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.vsSameDayLastWeekComparisonFlag :
|
|
689
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
690
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.vsSameDayLastWeekComparisonFlag : // Assuming correct key name
|
|
691
|
+
'NA',
|
|
692
|
+
'vsMTDAvgRate': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
693
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.vsMTDAvgRate :
|
|
694
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
695
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.vsMTDAvgRate :
|
|
696
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
697
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.vsMTDAvgRate : // Assuming correct key name
|
|
698
|
+
'NA',
|
|
699
|
+
'vsMTDAvgComparisonFlag': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
700
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.vsMTDAvgComparisonFlag :
|
|
701
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
702
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.vsMTDAvgComparisonFlag :
|
|
703
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
704
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.vsMTDAvgComparisonFlag : // Assuming correct key name
|
|
705
|
+
'NA',
|
|
706
|
+
};
|
|
707
|
+
// console.log( 'highData =>', highData );
|
|
708
|
+
let lowData = {
|
|
709
|
+
'storeName': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
710
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.storeName :
|
|
711
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
712
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.storeName :
|
|
713
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
714
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.storeName : // Assuming correct key name
|
|
715
|
+
'NA',
|
|
716
|
+
'storeId': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
717
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.storeId :
|
|
718
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
719
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.storeId :
|
|
720
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
721
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.storeId : // Assuming correct key name
|
|
722
|
+
'NA',
|
|
723
|
+
'vsSameDayLastWeekRate': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
724
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.vsSameDayLastWeekRate :
|
|
725
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
726
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.vsSameDayLastWeekRate :
|
|
727
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
728
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.vsSameDayLastWeekRate : // Assuming correct key name
|
|
729
|
+
'NA',
|
|
730
|
+
'vsSameDayLastWeekComparisonFlag': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
731
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.vsSameDayLastWeekComparisonFlag :
|
|
732
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
733
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.vsSameDayLastWeekComparisonFlag :
|
|
734
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
735
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.vsSameDayLastWeekComparisonFlag : // Assuming correct key name
|
|
736
|
+
'NA',
|
|
737
|
+
'vsMTDAvgRate': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
738
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.vsMTDAvgRate :
|
|
739
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
740
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.vsMTDAvgRate :
|
|
741
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
742
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.vsMTDAvgRate : // Assuming correct key name
|
|
743
|
+
'NA',
|
|
744
|
+
'vsMTDAvgComparisonFlag': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
745
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.vsMTDAvgComparisonFlag :
|
|
746
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
747
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.vsMTDAvgComparisonFlag :
|
|
748
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
749
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.vsMTDAvgComparisonFlag : // Assuming correct key name
|
|
750
|
+
'NA',
|
|
751
|
+
};
|
|
752
|
+
// console.log( 'lowData =>', lowData );
|
|
753
|
+
updatedlamdaAPIResultData.conversionMetrics.highData = highData;
|
|
754
|
+
updatedlamdaAPIResultData.conversionMetrics.lowData = lowData;
|
|
755
|
+
// console.log( 'updatedlamdaAPIResultData =>', updatedlamdaAPIResultData );
|
|
756
|
+
return updatedlamdaAPIResultData;
|
|
649
757
|
} catch ( error ) {
|
|
650
758
|
// console.log( 'error lamdaAPI3=>', error );
|
|
651
759
|
logger.error( { error: error, function: 'lamdaAPI3' } );
|
|
@@ -767,7 +875,103 @@ async function lamdaAPI4( templateData ) {
|
|
|
767
875
|
if ( !lamdaAPIResultData || lamdaAPIResultData.status_code !== '200' ) {
|
|
768
876
|
return '';
|
|
769
877
|
}
|
|
770
|
-
|
|
878
|
+
let updatedlamdaAPIResultData = lamdaAPIResultData;
|
|
879
|
+
|
|
880
|
+
let highData = {
|
|
881
|
+
'storeName': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
882
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.storeName :
|
|
883
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
884
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.storeName :
|
|
885
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
886
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.storeName : // Assuming correct key name
|
|
887
|
+
'NA',
|
|
888
|
+
'storeId': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
889
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.storeId :
|
|
890
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
891
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.storeId :
|
|
892
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
893
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.storeId : // Assuming correct key name
|
|
894
|
+
'NA',
|
|
895
|
+
'vsSameDayLastWeekRate': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
896
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.vsSameDayLastWeekRate :
|
|
897
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
898
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.vsSameDayLastWeekRate :
|
|
899
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
900
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.vsSameDayLastWeekRate : // Assuming correct key name
|
|
901
|
+
'NA',
|
|
902
|
+
'vsSameDayLastWeekComparisonFlag': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
903
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.vsSameDayLastWeekComparisonFlag :
|
|
904
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
905
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.vsSameDayLastWeekComparisonFlag :
|
|
906
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
907
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.vsSameDayLastWeekComparisonFlag : // Assuming correct key name
|
|
908
|
+
'NA',
|
|
909
|
+
'vsMTDAvgRate': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
910
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.vsMTDAvgRate :
|
|
911
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
912
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.vsMTDAvgRate :
|
|
913
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
914
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.vsMTDAvgRate : // Assuming correct key name
|
|
915
|
+
'NA',
|
|
916
|
+
'vsMTDAvgComparisonFlag': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
917
|
+
lamdaAPIResultData.conversionMetrics.highEngagers.vsMTDAvgComparisonFlag :
|
|
918
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
919
|
+
lamdaAPIResultData.conversionMetrics.highPotentialBuyers.vsMTDAvgComparisonFlag :
|
|
920
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
921
|
+
lamdaAPIResultData.conversionMetrics.highFootfall.vsMTDAvgComparisonFlag : // Assuming correct key name
|
|
922
|
+
'NA',
|
|
923
|
+
};
|
|
924
|
+
let lowData = {
|
|
925
|
+
'storeName': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
926
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.storeName :
|
|
927
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
928
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.storeName :
|
|
929
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
930
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.storeName : // Assuming correct key name
|
|
931
|
+
'NA',
|
|
932
|
+
'storeId': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
933
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.storeId :
|
|
934
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
935
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.storeId :
|
|
936
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
937
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.storeId : // Assuming correct key name
|
|
938
|
+
'NA',
|
|
939
|
+
'vsSameDayLastWeekRate': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
940
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.vsSameDayLastWeekRate :
|
|
941
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
942
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.vsSameDayLastWeekRate :
|
|
943
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
944
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.vsSameDayLastWeekRate : // Assuming correct key name
|
|
945
|
+
'NA',
|
|
946
|
+
'vsSameDayLastWeekComparisonFlag': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
947
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.vsSameDayLastWeekComparisonFlag :
|
|
948
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
949
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.vsSameDayLastWeekComparisonFlag :
|
|
950
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
951
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.vsSameDayLastWeekComparisonFlag : // Assuming correct key name
|
|
952
|
+
'NA',
|
|
953
|
+
'vsMTDAvgRate': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
954
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.vsMTDAvgRate :
|
|
955
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
956
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.vsMTDAvgRate :
|
|
957
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
958
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.vsMTDAvgRate : // Assuming correct key name
|
|
959
|
+
'NA',
|
|
960
|
+
'vsMTDAvgComparisonFlag': templateData.featureConfigs.conversionCalculation === 'engagers-count' ?
|
|
961
|
+
lamdaAPIResultData.conversionMetrics.lowEngagers.vsMTDAvgComparisonFlag :
|
|
962
|
+
templateData.featureConfigs.conversionCalculation === 'billable-entities' ?
|
|
963
|
+
lamdaAPIResultData.conversionMetrics.lowPotentialBuyers.vsMTDAvgComparisonFlag :
|
|
964
|
+
templateData.featureConfigs.conversionCalculation === 'footfall-count' ?
|
|
965
|
+
lamdaAPIResultData.conversionMetrics.lowFootfall.vsMTDAvgComparisonFlag : // Assuming correct key name
|
|
966
|
+
'NA',
|
|
967
|
+
};
|
|
968
|
+
// console.log( 'lowData =>', lowData );
|
|
969
|
+
updatedlamdaAPIResultData.conversionMetrics.highData = highData;
|
|
970
|
+
updatedlamdaAPIResultData.conversionMetrics.lowData = lowData;
|
|
971
|
+
// console.log( 'updatedlamdaAPIResultData =>', updatedlamdaAPIResultData );
|
|
972
|
+
|
|
973
|
+
|
|
974
|
+
return updatedlamdaAPIResultData;
|
|
771
975
|
} catch ( error ) {
|
|
772
976
|
// console.log( 'error lamdaAPI4=>', error );
|
|
773
977
|
logger.error( { error: error, function: 'lamdaAPI4' } );
|
|
@@ -1059,8 +1263,10 @@ async function dailyFootfallTrendChartLamdaAPI( templateData ) {
|
|
|
1059
1263
|
let newTemplateData = templateData;
|
|
1060
1264
|
// console.log( 'Template Data:', templateData );
|
|
1061
1265
|
// newTemplateData.dateType = 'weekly';
|
|
1062
|
-
let processTypeValue = '
|
|
1063
|
-
if ( templateData.featureConfigs.conversionCalculation
|
|
1266
|
+
let processTypeValue = 'conversion';
|
|
1267
|
+
if ( templateData.featureConfigs.conversionCalculation == 'engagers-count' ) {
|
|
1268
|
+
processTypeValue='engagers';
|
|
1269
|
+
} else if ( templateData.featureConfigs.conversionCalculation == 'billable-entities' ) {
|
|
1064
1270
|
processTypeValue='potentialBuyer';
|
|
1065
1271
|
}
|
|
1066
1272
|
let filterByTypeValue = 'average';
|
|
@@ -1074,10 +1280,8 @@ async function dailyFootfallTrendChartLamdaAPI( templateData ) {
|
|
|
1074
1280
|
newTemplateData.processType = processTypeValue;
|
|
1075
1281
|
newTemplateData.limit = 31;
|
|
1076
1282
|
newTemplateData.offset = 0;
|
|
1077
|
-
// console.log( 'newTemplateData', newTemplateData );
|
|
1078
1283
|
const overallLamdaURL = 'https://x6sjlqwaqd64kyioxhwrwfesbm0jjitx.lambda-url.ap-south-1.on.aws/';
|
|
1079
1284
|
let lamdaAPIResultData = await LamdaServiceCall( overallLamdaURL, newTemplateData );
|
|
1080
|
-
// console.log( 'lamdaAPIResultData =>', lamdaAPIResultData );
|
|
1081
1285
|
if ( !lamdaAPIResultData || lamdaAPIResultData.status_code !== '200' ) {
|
|
1082
1286
|
return chartUrl;
|
|
1083
1287
|
}
|
|
@@ -1097,7 +1301,7 @@ async function dailyFootfallTrendChartLamdaAPI( templateData ) {
|
|
|
1097
1301
|
// console.log( 'bucketDetails =>', bucketDetails.mailer );
|
|
1098
1302
|
// console.log( 'overallChartParams =>', overallChartParams );
|
|
1099
1303
|
const overallChartResponse = await fileUpload( overallChartParams );
|
|
1100
|
-
|
|
1304
|
+
// console.log( 'overallChartResponse', overallChartResponse );
|
|
1101
1305
|
if ( overallChartResponse && overallChartResponse.Key ) {
|
|
1102
1306
|
const URL= JSON.parse( process.env.URL );
|
|
1103
1307
|
chartUrl = `${URL.emailers}${overallChartResponse.Key}`;
|
|
@@ -1125,7 +1329,7 @@ async function getLamdaChartData( templateData ) {
|
|
|
1125
1329
|
dailyData: '',
|
|
1126
1330
|
hourlyData: '',
|
|
1127
1331
|
};
|
|
1128
|
-
if ( templateData.
|
|
1332
|
+
if ( templateData.storeId.length == 1 && templateData.templateType == 'daily' ) {
|
|
1129
1333
|
// // Call Lamda API No 1 Single Store Single Date
|
|
1130
1334
|
const [ chartImagePath, hourlyChartImagePath ] = await Promise.all( [
|
|
1131
1335
|
dailyChartLamdaAPI( templateData ), // For the overall chart (col-8)
|
|
@@ -1150,32 +1354,35 @@ async function getLamdaChartData( templateData ) {
|
|
|
1150
1354
|
async function emailerSendEmail( storeData, clientData, lamdaMetrics, lamdaCharts, templateData ) {
|
|
1151
1355
|
try {
|
|
1152
1356
|
let hbsFileName = '../hbs/dailyMailerSingle.hbs';
|
|
1153
|
-
if ( templateData.
|
|
1357
|
+
if ( templateData.storeId.length === 1 && templateData.templateType === 'daily' ) {
|
|
1154
1358
|
hbsFileName = '../hbs/dailyMailerSingle.hbs';
|
|
1155
|
-
} else if ( templateData.
|
|
1359
|
+
} else if ( templateData.storeId.length > 1 && templateData.templateType === 'daily' ) {
|
|
1156
1360
|
hbsFileName = '../hbs/dailyMailerMultiple.hbs';
|
|
1157
|
-
} else if ( templateData.
|
|
1361
|
+
} else if ( templateData.storeId.length === 1 && templateData.templateType === 'weekly' ) {
|
|
1158
1362
|
hbsFileName = '../hbs/weeklyMailerSingle.hbs';
|
|
1159
|
-
} else if ( templateData.
|
|
1363
|
+
} else if ( templateData.storeId.length > 1 && templateData.templateType === 'weekly' ) {
|
|
1160
1364
|
hbsFileName = '../hbs/weeklyMailerMultiple.hbs';
|
|
1161
|
-
} else if ( templateData.
|
|
1365
|
+
} else if ( templateData.storeId.length === 1 && templateData.templateType === 'monthly' ) {
|
|
1162
1366
|
hbsFileName = '../hbs/dailyMailerSingle.hbs';
|
|
1163
|
-
} else if ( templateData.
|
|
1367
|
+
} else if ( templateData.storeId.length > 1 && templateData.templateType === 'monthly' ) {
|
|
1164
1368
|
hbsFileName = '../hbs/dailyMailerSingle.hbs';
|
|
1165
1369
|
}
|
|
1166
1370
|
|
|
1371
|
+
|
|
1167
1372
|
// Prepare email with Handlebars template
|
|
1168
1373
|
const hbsFilePath = path.join( __dirname, hbsFileName );
|
|
1169
1374
|
const templateHtml = fs.readFileSync( hbsFilePath, 'utf8' );
|
|
1170
1375
|
const template = Handlebars.compile( templateHtml );
|
|
1171
|
-
console.log( 'JSON.parse( process.env.URL ).apiDomain', JSON.parse( process.env.URL ).apiDomain );
|
|
1376
|
+
// console.log( 'JSON.parse( process.env.URL ).apiDomain', JSON.parse( process.env.URL ).apiDomain );
|
|
1172
1377
|
const html = template( { data: {
|
|
1378
|
+
|
|
1173
1379
|
// email: inputData.email,
|
|
1174
1380
|
clientName: clientData.clientName,
|
|
1175
1381
|
domain: JSON.parse( process.env.URL ).domain,
|
|
1176
1382
|
overallChartImage: lamdaCharts.dailyData,
|
|
1177
1383
|
hourlyChartImage: lamdaCharts.hourlyData,
|
|
1178
1384
|
lamdaMetrics: lamdaMetrics,
|
|
1385
|
+
// updatedLamdaMetrics: updatedLamdaMetrics,
|
|
1179
1386
|
storeData: storeData,
|
|
1180
1387
|
templateData: templateData,
|
|
1181
1388
|
chartImage: lamdaCharts.dailyFootfallTrendData,
|
|
@@ -1187,7 +1394,9 @@ async function emailerSendEmail( storeData, clientData, lamdaMetrics, lamdaChart
|
|
|
1187
1394
|
missedOpportunityCalculation: clientData?.featureConfigs?.missedOpportunityCalculation || 'engagers-conversion',
|
|
1188
1395
|
bufferTime: 30,
|
|
1189
1396
|
},
|
|
1397
|
+
|
|
1190
1398
|
} } );
|
|
1399
|
+
// console.log( 'templateData', templateData );
|
|
1191
1400
|
|
|
1192
1401
|
|
|
1193
1402
|
let file = { content: html };
|
|
@@ -1206,28 +1415,54 @@ async function emailerSendEmail( storeData, clientData, lamdaMetrics, lamdaChart
|
|
|
1206
1415
|
let pdfBuffer = await htmlpdf.generatePdf( file, options );
|
|
1207
1416
|
// console.log( 'PDF generated successfully' );
|
|
1208
1417
|
|
|
1209
|
-
|
|
1418
|
+
let subject = '';
|
|
1419
|
+
let attachmentFileName = '';
|
|
1420
|
+
switch ( hbsFileName ) {
|
|
1421
|
+
case '../hbs/dailyMailerSingle.hbs':
|
|
1422
|
+
subject = `Footfall Trend Report for ${storeData.storeName}_${templateData.toDateFormat}`;
|
|
1423
|
+
attachmentFileName = `${storeData.storeName}_${templateData.toDateFormat}.pdf`;
|
|
1424
|
+
break;
|
|
1425
|
+
case '../hbs/dailyMailerMultiple.hbs':
|
|
1426
|
+
subject = `Daily Footfall Trend Report for ${templateData.toDateFormat}`;
|
|
1427
|
+
attachmentFileName = `Daily_${templateData.toDateFormat}.pdf`;
|
|
1428
|
+
break;
|
|
1429
|
+
break;
|
|
1430
|
+
case '../hbs/weeklyMailerSingle.hbs':
|
|
1431
|
+
subject = `Footfall Weekly Analysis Report for ${storeData.storeName}_${templateData.fromDateFormat} - ${templateData.toDateFormat}`;
|
|
1432
|
+
attachmentFileName = `${storeData.storeName}_${templateData.fromDateFormat} - ${templateData.toDateFormat}.pdf`;
|
|
1433
|
+
break;
|
|
1434
|
+
case '../hbs/weeklyMailerMultiple.hbs':
|
|
1435
|
+
subject = `Weekly Footfall Trend Report for ${templateData.fromDateFormat} - ${templateData.toDateFormat}`;
|
|
1436
|
+
attachmentFileName = `Weekly_${templateData.fromDateFormat} - ${templateData.toDateFormat}.pdf`;
|
|
1437
|
+
break;
|
|
1438
|
+
default:
|
|
1439
|
+
subject = `Footfall Report for ${templateData.toDateFormat}`;
|
|
1440
|
+
attachmentFileName = `${templateData.toDateFormat}.pdf`;
|
|
1441
|
+
}
|
|
1442
|
+
|
|
1210
1443
|
const ses = JSON.parse( process.env.SES );
|
|
1211
1444
|
// templateData.userEmail
|
|
1212
|
-
await sendEmailWithSES(
|
|
1445
|
+
let rrr = await sendEmailWithSES(
|
|
1446
|
+
// [ 'qualityassuranceteam@tangotech.co.in', 'nafila@tangotech.co.in', 'keerthivasan@tangotech.co.in' ],
|
|
1213
1447
|
'keerthivasan@tangotech.co.in',
|
|
1214
1448
|
subject,
|
|
1215
1449
|
html,
|
|
1216
1450
|
{
|
|
1217
|
-
filename: `Attachment_${Date.now()}.pdf`,
|
|
1451
|
+
// filename: `Attachment_${Date.now()}.pdf`,
|
|
1452
|
+
filename: attachmentFileName,
|
|
1218
1453
|
content: pdfBuffer,
|
|
1219
1454
|
contentType: 'application/pdf',
|
|
1220
1455
|
},
|
|
1221
1456
|
ses.adminEmail,
|
|
1222
1457
|
);
|
|
1223
1458
|
// return res.sendSuccess( { result: 'EMAIL-SENT' } );
|
|
1459
|
+
console.error( 'rrr', rrr );
|
|
1224
1460
|
return true;
|
|
1225
1461
|
} catch ( error ) {
|
|
1226
1462
|
console.error( 'Error in emailerSendEmail:', error );
|
|
1227
1463
|
return false;
|
|
1228
1464
|
}
|
|
1229
1465
|
}
|
|
1230
|
-
|
|
1231
1466
|
const overallChart = async ( data ) => {
|
|
1232
1467
|
console.log( 'Generating overallChart footfall chart...' );
|
|
1233
1468
|
|
|
@@ -1568,9 +1803,9 @@ const footfallTrend = async ( data ) => {
|
|
|
1568
1803
|
})
|
|
1569
1804
|
);
|
|
1570
1805
|
|
|
1571
|
-
chart.set("scrollbarX", am5.Scrollbar.new(root, {
|
|
1572
|
-
|
|
1573
|
-
}));
|
|
1806
|
+
// chart.set("scrollbarX", am5.Scrollbar.new(root, {
|
|
1807
|
+
// orientation: "horizontal"
|
|
1808
|
+
// }));
|
|
1574
1809
|
|
|
1575
1810
|
const xRenderer = am5xy.AxisRendererX.new(root, {
|
|
1576
1811
|
minGridDistance: 20,
|
|
@@ -1735,7 +1970,9 @@ const footfallTrend = async ( data ) => {
|
|
|
1735
1970
|
let weeklyChartBuffer;
|
|
1736
1971
|
try {
|
|
1737
1972
|
await page.setContent( chartHtmlContent, { waitUntil: 'domcontentloaded' } );
|
|
1973
|
+
|
|
1738
1974
|
await page.waitForSelector( '#Footfalltrend', { visible: true } );
|
|
1975
|
+
// await page.waitForTimeout( 10 );
|
|
1739
1976
|
weeklyChartBuffer = await page.screenshot( { encoding: 'binary' } );
|
|
1740
1977
|
} catch ( err ) {
|
|
1741
1978
|
// console.log( 'Error generating chart screenshot:', err );
|
|
@@ -17,6 +17,11 @@ export const registerHelpers = () => {
|
|
|
17
17
|
/* eslint-disable no-invalid-this */
|
|
18
18
|
return a !== b ? options.fn( this ) : options.inverse( this );
|
|
19
19
|
} );
|
|
20
|
+
|
|
21
|
+
// New helper: If value is empty, return "NA"
|
|
22
|
+
handlebars.registerHelper( 'ifEmpty', function( value ) {
|
|
23
|
+
return value && value.trim() !== '' ? value : 'NA';
|
|
24
|
+
} );
|
|
20
25
|
};
|
|
21
26
|
|
|
22
27
|
export default handlebars;
|
|
@@ -224,7 +224,7 @@
|
|
|
224
224
|
|
|
225
225
|
</head>
|
|
226
226
|
|
|
227
|
-
<body style="margin: 0;
|
|
227
|
+
<body style="margin: 0; padding: 10px 0; background: #EFEFEF; font-family: Inter;">
|
|
228
228
|
<div
|
|
229
229
|
style="font-size: 0px; line-height: 1px; mso-line-height-rule: exactly; display: none; max-width: 0px; max-height: 0px; opacity: 0; overflow: hidden; mso-hide: all">
|
|
230
230
|
</div>
|
|
@@ -232,13 +232,13 @@
|
|
|
232
232
|
style="width: 100%; table-layout: fixed; -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%">
|
|
233
233
|
<table class="bg-fffffe" cellpadding="0" cellspacing="0" border="0" role="presentation" bgcolor="white"
|
|
234
234
|
width="640.00"
|
|
235
|
-
style=" background-color: white; padding-bottom: 16px; width: 640px; border-spacing: 0; font-family: Inter, Tahoma, sans-serif; min-width: 640px; border-collapse: separate">
|
|
235
|
+
style=" background-color: white; padding-bottom: 16px; width: 640px; border-spacing: 0; font-family: Inter, Tahoma, sans-serif; min-width: 640px; border-collapse: separate; border-radius: 12px;">
|
|
236
236
|
<tr>
|
|
237
|
-
<td valign="top" width="100.00%" style="padding-top:
|
|
237
|
+
<td valign="top" width="100.00%" style="padding-top: 18px; width: 100%; vertical-align: top">
|
|
238
238
|
<table cellpadding="0" cellspacing="0" border="0" role="presentation" width="100.00%"
|
|
239
239
|
style="width: 100%; border-spacing: 0">
|
|
240
240
|
<tr>
|
|
241
|
-
<td style="padding-bottom:
|
|
241
|
+
<td style="padding-bottom: 9.5px">
|
|
242
242
|
<img src="{{data.domain}}/assets/emailers/Tango Logo mailer.png" width="170"
|
|
243
243
|
style="max-width: initial; width: 170px; display: block" />
|
|
244
244
|
</td>
|
|
@@ -262,7 +262,7 @@
|
|
|
262
262
|
<table cellspacing="0" cellpadding="0" border="0">
|
|
263
263
|
<tr>
|
|
264
264
|
<td width="295" align="center"
|
|
265
|
-
style="vertical-align: middle;
|
|
265
|
+
style="vertical-align: middle; padding-left:4px; padding-right:4px;">
|
|
266
266
|
<table width="100%" border="0" cellpadding="0" cellspacing="0">
|
|
267
267
|
<tr>
|
|
268
268
|
<td style="vertical-align: middle;" align="center">
|
|
@@ -280,7 +280,7 @@
|
|
|
280
280
|
<td style="vertical-align: middle;" align="center">
|
|
281
281
|
<div style="text-align:center;"><span
|
|
282
282
|
style="color:#384860;font-family:Inter,Arial,sans-serif;font-size:16px;letter-spacing:0.20000000298023224px;line-height:150%;text-align:center;">Your
|
|
283
|
-
Store's Key Footfall Insights for {{data.templateData.
|
|
283
|
+
Store's Key Footfall Insights for <br /> {{data.templateData.toDateFormat}}</span></div>
|
|
284
284
|
</td>
|
|
285
285
|
</tr>
|
|
286
286
|
</table>
|
|
@@ -857,40 +857,31 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
857
857
|
style="background: url('assets/image_c925bfaf.png') 50% / 100% no-repeat; width: 100%; height: 40px">
|
|
858
858
|
<p class="color-384860" width="100.00%" style="font-size: 14px; font-weight: 500; text-align: left; line-height: 20px; color: #384860; mso-line-height-rule: exactly; margin: 0; padding: 0; width: 100%">
|
|
859
859
|
<span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly; display: inline-flex; align-items: center;">
|
|
860
|
-
{{
|
|
861
|
-
{{data.lamdaMetrics.conversionMetrics.highEngagers.storeName}}
|
|
862
|
-
{{/eq}}
|
|
863
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
864
|
-
{{data.lamdaMetrics.conversionMetrics.highPotentialBuyers.storeName}}
|
|
865
|
-
{{/eq}}
|
|
860
|
+
{{data.lamdaMetrics.conversionMetrics.highData.storeName}}
|
|
866
861
|
</span>
|
|
867
862
|
<span>
|
|
868
|
-
- High performing store with highest change in
|
|
863
|
+
- High performing store with highest change in
|
|
869
864
|
{{#eq data.featureConfigs.conversionCalculation 'engagers-count'}}
|
|
870
865
|
Engagers
|
|
871
866
|
{{/eq}}
|
|
872
867
|
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
873
868
|
Potential Buyers
|
|
874
869
|
{{/eq}}
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
{{/eq}}
|
|
878
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
879
|
-
{{data.lamdaMetrics.conversionMetrics.highPotentialBuyers.vsSameDayLastWeekRate}}%
|
|
870
|
+
{{#eq data.featureConfigs.conversionCalculation 'footfall-count'}}
|
|
871
|
+
Footfall
|
|
880
872
|
{{/eq}}
|
|
881
|
-
|
|
873
|
+
|
|
874
|
+
({{data.lamdaMetrics.conversionMetrics.highData.vsSameDayLastWeekRate}}%
|
|
875
|
+
|
|
876
|
+
{{#eq data.lamdaMetrics.conversionMetrics.highData.vsSameDayLastWeekComparisonFlag true}}
|
|
882
877
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png" border="0" width="12" />
|
|
883
878
|
{{else}}
|
|
884
879
|
<img src="{{data.domain}}/assets/emailers/NegativeVector.png" border="0" width="12" />
|
|
885
880
|
{{/eq}}
|
|
886
881
|
vs same day last week and
|
|
887
|
-
{{
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
891
|
-
{{data.lamdaMetrics.conversionMetrics.highPotentialBuyers.vsMTDAvgRate}}%
|
|
892
|
-
{{/eq}}
|
|
893
|
-
{{#eq data.lamdaMetrics.conversionMetrics.highEngagers.vsMTDAvgComparisonFlag true}}
|
|
882
|
+
{{data.lamdaMetrics.conversionMetrics.highData.vsMTDAvgRate}}%
|
|
883
|
+
|
|
884
|
+
{{#eq data.lamdaMetrics.conversionMetrics.highData.vsMTDAvgComparisonFlag true}}
|
|
894
885
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png" border="0" width="12" />
|
|
895
886
|
{{else}}
|
|
896
887
|
<img src="{{data.domain}}/assets/emailers/NegativeVector.png" border="0" width="12" />
|
|
@@ -918,12 +909,7 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
918
909
|
style="background: url('assets/image_a402f201.png') 50% / 100% no-repeat; width: 100%; height: 40px">
|
|
919
910
|
<p class="color-384860" width="100.00%" style="font-size: 14px; font-weight: 500; text-align: left; line-height: 20px; color: #384860; mso-line-height-rule: exactly; margin: 0; padding: 0; width: 100%">
|
|
920
911
|
<span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly; display: inline-flex; align-items: center;">
|
|
921
|
-
|
|
922
|
-
{{data.lamdaMetrics.conversionMetrics.lowEngagers.storeName}}
|
|
923
|
-
{{/eq}}
|
|
924
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
925
|
-
{{data.lamdaMetrics.conversionMetrics.lowPotentialBuyers.storeName}}
|
|
926
|
-
{{/eq}}
|
|
912
|
+
{{data.lamdaMetrics.conversionMetrics.lowData.storeName}}
|
|
927
913
|
</span>
|
|
928
914
|
<span>
|
|
929
915
|
- Poor performing store with lowest change in
|
|
@@ -933,25 +919,20 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
933
919
|
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
934
920
|
Potential Buyers
|
|
935
921
|
{{/eq}}
|
|
936
|
-
|
|
937
|
-
|
|
922
|
+
{{#eq data.featureConfigs.conversionCalculation 'footfall-count'}}
|
|
923
|
+
Footfall
|
|
938
924
|
{{/eq}}
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
{{#eq data.lamdaMetrics.conversionMetrics.
|
|
925
|
+
|
|
926
|
+
({{data.lamdaMetrics.conversionMetrics.lowData.vsSameDayLastWeekRate}}%
|
|
927
|
+
|
|
928
|
+
{{#eq data.lamdaMetrics.conversionMetrics.lowData.vsSameDayLastWeekComparisonFlag true}}
|
|
943
929
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png" border="0" width="12" />
|
|
944
930
|
{{else}}
|
|
945
931
|
<img src="{{data.domain}}/assets/emailers/NegativeVector.png" border="0" width="12" />
|
|
946
932
|
{{/eq}}
|
|
947
933
|
vs same day last week and
|
|
948
|
-
{{
|
|
949
|
-
|
|
950
|
-
{{/eq}}
|
|
951
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
952
|
-
{{data.lamdaMetrics.conversionMetrics.lowPotentialBuyers.vsMTDAvgRate}}%
|
|
953
|
-
{{/eq}}
|
|
954
|
-
{{#eq data.lamdaMetrics.conversionMetrics.lowEngagers.vsMTDAvgComparisonFlag true}}
|
|
934
|
+
{{data.lamdaMetrics.conversionMetrics.lowData.vsMTDAvgRate}}%
|
|
935
|
+
{{#eq data.lamdaMetrics.conversionMetrics.lowData.vsMTDAvgComparisonFlag true}}
|
|
955
936
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png" border="0" width="12" />
|
|
956
937
|
{{else}}
|
|
957
938
|
<img src="{{data.domain}}/assets/emailers/NegativeVector.png" border="0" width="12" />
|
|
@@ -983,7 +964,7 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
983
964
|
<span>NA</span>
|
|
984
965
|
{{else}}
|
|
985
966
|
{{#each data.lamdaMetrics.lowOperationalHours}}
|
|
986
|
-
<span style="font-size: 14px; font-weight: 700">{{storeName}}
|
|
967
|
+
<span style="font-size: 14px; font-weight: 700">{{storeName}}{{#unless @last}},{{/unless}}</span>
|
|
987
968
|
{{/each}}
|
|
988
969
|
{{/eq}}
|
|
989
970
|
<span> - Store with lowest operational hours</span>
|
|
@@ -1013,7 +994,7 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
1013
994
|
<span>NA</span>
|
|
1014
995
|
{{else}}
|
|
1015
996
|
{{#each data.lamdaMetrics.fullDownTime}}
|
|
1016
|
-
<span style="font-size: 14px; font-weight: 700">{{storeName}}
|
|
997
|
+
<span style="font-size: 14px; font-weight: 700">{{storeName}}{{#unless @last}},{{/unless}}</span>
|
|
1017
998
|
{{/each}}
|
|
1018
999
|
{{/eq}}
|
|
1019
1000
|
<span> - Stores
|
|
@@ -1034,21 +1015,25 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
1034
1015
|
</td>
|
|
1035
1016
|
</tr>
|
|
1036
1017
|
<tr>
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1018
|
+
<td
|
|
1019
|
+
style="padding-top: 12px; padding-bottom: 12px; padding-left: 30px; padding-right: 30px;">
|
|
1020
|
+
<a href="https://dashboard.tangoeye.ai/">
|
|
1021
|
+
<table class="bg-00a3ff" cellpadding="0" cellspacing="0" border="0" role="presentation"
|
|
1022
|
+
bgcolor="#00a3ff" width="580.00" height="48.00"
|
|
1023
|
+
style="border-radius: 8px; border: 1px solid #00a3ff; box-shadow: 0px 1px 2px rgba(16, 24, 40, 0.05); background-color: #00a3ff; width: 580px; height: 48px; border-spacing: 0; border-collapse: separate">
|
|
1024
|
+
<tr>
|
|
1025
|
+
<td valign="middle" width="100.00%" height="46.00"
|
|
1026
|
+
style="width: 100%; vertical-align: middle; height: 46px; text-align: center; cursor:pointer !important">
|
|
1027
|
+
<span class="color-fffffe"
|
|
1028
|
+
style="font-size: 16px; font-weight: 600; text-transform: capitalize; color: white; margin: 0; padding: 0; line-height: 24px; display: inline-block;text-decoration: none;">
|
|
1029
|
+
View Detailed Analysis
|
|
1030
|
+
</span>
|
|
1031
|
+
|
|
1032
|
+
</td>
|
|
1033
|
+
</tr>
|
|
1034
|
+
</table>
|
|
1035
|
+
</a>
|
|
1036
|
+
</td>
|
|
1052
1037
|
</tr>
|
|
1053
1038
|
<tr>
|
|
1054
1039
|
<td align="left" style="padding-top: 12px; padding-bottom: 12px; padding-left: 29px; padding-right: 29px">
|
|
@@ -1060,7 +1045,7 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
1060
1045
|
</tr>
|
|
1061
1046
|
<tr>
|
|
1062
1047
|
<td align="center">
|
|
1063
|
-
<table cellspacing="0" cellpadding="0" border="0">
|
|
1048
|
+
<table cellspacing="0" cellpadding="0" border="0" style="margin-bottom: 5px;">
|
|
1064
1049
|
<tr>
|
|
1065
1050
|
<td style="vertical-align: middle;">
|
|
1066
1051
|
<table cellspacing="0" cellpadding="0" border="0">
|
|
@@ -208,7 +208,7 @@
|
|
|
208
208
|
</style>
|
|
209
209
|
</head>
|
|
210
210
|
|
|
211
|
-
<body style="margin: 0; padding: 0; background: #EFEFEF; font-family:Inter,Arial,sans-serif;
|
|
211
|
+
<body style="margin: 0; padding: 10px 0; background: #EFEFEF; font-family:Inter,Arial,sans-serif;
|
|
212
212
|
">
|
|
213
213
|
<div
|
|
214
214
|
style="font-size: 0px; line-height: 1px; mso-line-height-rule: exactly; display: none; max-width: 0px; max-height: 0px; opacity: 0; overflow: hidden; mso-hide: all">
|
|
@@ -218,14 +218,14 @@
|
|
|
218
218
|
<table class="bg-fffffe" cellpadding="0" cellspacing="0" border="0" role="presentation" bgcolor="white"
|
|
219
219
|
width="640.00"
|
|
220
220
|
style="background-color: white; width: 640px; border-spacing: 0; font-family:Inter,Arial,sans-serif;
|
|
221
|
-
min-width: 640px; border-collapse: separate">
|
|
221
|
+
min-width: 640px; border-collapse: separate; border-radius: 12px;">
|
|
222
222
|
<tr>
|
|
223
223
|
<td valign="top" width="100.00%"
|
|
224
|
-
style="padding-top:
|
|
224
|
+
style="padding-top: 18px; padding-bottom: 18px; width: 100%; vertical-align: top">
|
|
225
225
|
<table cellpadding="0" cellspacing="0" border="0" role="presentation" width="100.00%"
|
|
226
226
|
style="width: 100%; border-spacing: 0">
|
|
227
227
|
<tr>
|
|
228
|
-
<td style="padding-bottom:
|
|
228
|
+
<td style="padding-bottom: 4.5px">
|
|
229
229
|
<img src="{{data.domain}}/assets/emailers/Tango Logo mailer.png" width="170"
|
|
230
230
|
style="max-width: initial; width: 170px; display: block" />
|
|
231
231
|
</td>
|
|
@@ -263,8 +263,8 @@
|
|
|
263
263
|
<td align="center" style="padding-top: 6.73px">
|
|
264
264
|
<p class="color-fffffe" width="100.00%"
|
|
265
265
|
style="font-size: 16px; font-weight: 400; letter-spacing: 0.2px; color: white; margin: 0; padding: 0; width: 100%; line-height: 24px; text-align: center; mso-line-height-rule: exactly">
|
|
266
|
-
Your Store's Key Footfall Insights for
|
|
267
|
-
{{data.templateData.
|
|
266
|
+
Your Store's Key Footfall Insights for <br />
|
|
267
|
+
{{data.templateData.toDateFormat}}</p>
|
|
268
268
|
</td>
|
|
269
269
|
</tr>
|
|
270
270
|
</table>
|
|
@@ -951,21 +951,23 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
951
951
|
</tr>
|
|
952
952
|
<tr>
|
|
953
953
|
<td
|
|
954
|
-
style="padding-top: 12px; padding-bottom: 12px; padding-left: 30px; padding-right: 30px">
|
|
954
|
+
style="padding-top: 12px; padding-bottom: 12px; padding-left: 30px; padding-right: 30px;">
|
|
955
|
+
<a href="https://dashboard.tangoeye.ai/">
|
|
955
956
|
<table class="bg-00a3ff" cellpadding="0" cellspacing="0" border="0" role="presentation"
|
|
956
957
|
bgcolor="#00a3ff" width="580.00" height="48.00"
|
|
957
|
-
style="border-radius: 8px; border: 1px solid #00a3ff; box-shadow: 0px 1px 2px rgba(16, 24, 40, 0.05); background-color: #00a3ff; width: 580px; height: 48px; border-spacing: 0; border-collapse: separate
|
|
958
|
+
style="border-radius: 8px; border: 1px solid #00a3ff; box-shadow: 0px 1px 2px rgba(16, 24, 40, 0.05); background-color: #00a3ff; width: 580px; height: 48px; border-spacing: 0; border-collapse: separate">
|
|
958
959
|
<tr>
|
|
959
960
|
<td valign="middle" width="100.00%" height="46.00"
|
|
960
|
-
style="width: 100%; vertical-align: middle; height: 46px; text-align: center;">
|
|
961
|
-
<
|
|
961
|
+
style="width: 100%; vertical-align: middle; height: 46px; text-align: center; cursor:pointer !important">
|
|
962
|
+
<span class="color-fffffe"
|
|
962
963
|
style="font-size: 16px; font-weight: 600; text-transform: capitalize; color: white; margin: 0; padding: 0; line-height: 24px; display: inline-block;text-decoration: none;">
|
|
963
|
-
|
|
964
|
-
|
|
964
|
+
View Detailed Analysis
|
|
965
|
+
</span>
|
|
966
|
+
|
|
965
967
|
</td>
|
|
966
968
|
</tr>
|
|
967
969
|
</table>
|
|
968
|
-
|
|
970
|
+
</a>
|
|
969
971
|
</td>
|
|
970
972
|
</tr>
|
|
971
973
|
<tr>
|
|
@@ -980,7 +982,7 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
980
982
|
</tr>
|
|
981
983
|
<tr>
|
|
982
984
|
<td align="center">
|
|
983
|
-
<table cellspacing="0" cellpadding="0" border="0">
|
|
985
|
+
<table cellspacing="0" cellpadding="0" border="0" style="margin-bottom: 20px;">
|
|
984
986
|
<tr>
|
|
985
987
|
<td style="vertical-align: middle;">
|
|
986
988
|
<table cellspacing="0" cellpadding="0" border="0">
|
|
@@ -156,15 +156,15 @@
|
|
|
156
156
|
|
|
157
157
|
|
|
158
158
|
</head>
|
|
159
|
-
<body style="margin: 0; padding: 0; background: #EFEFEF; font-family: 'Inter';">
|
|
159
|
+
<body style="margin: 0; padding: 10px 0; background: #EFEFEF; font-family: 'Inter';">
|
|
160
160
|
<div style="font-size: 0px; line-height: 1px; mso-line-height-rule: exactly; display: none; max-width: 0px; max-height: 0px; opacity: 0; overflow: hidden; mso-hide: all"></div>
|
|
161
161
|
<center lang="und" dir="auto" style="width: 100%; table-layout: fixed; -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%">
|
|
162
|
-
<table class="bg-fffffe" cellpadding="0" cellspacing="0" border="0" role="presentation" bgcolor="white" width="640.00" style=" background-color: white; padding-bottom: 16px; width: 640px; border-spacing: 0; font-family: Inter, Tahoma, sans-serif; min-width: 640px; border-collapse: separate">
|
|
162
|
+
<table class="bg-fffffe" cellpadding="0" cellspacing="0" border="0" role="presentation" bgcolor="white" width="640.00" style=" background-color: white; padding-bottom: 16px; width: 640px; border-spacing: 0; font-family: Inter, Tahoma, sans-serif; min-width: 640px; border-collapse: separate; border-radius: 12px;">
|
|
163
163
|
<tr>
|
|
164
164
|
<td valign="top" width="100.00%" style="padding-top: 15px; width: 100%; vertical-align: top">
|
|
165
165
|
<table cellpadding="0" cellspacing="0" border="0" role="presentation" width="100.00%" style="width: 100%; border-spacing: 0">
|
|
166
166
|
<tr>
|
|
167
|
-
<td style="padding-bottom:
|
|
167
|
+
<td style="padding-bottom: 9.5px">
|
|
168
168
|
<img src="{{data.domain}}/assets/emailers/Tango Logo mailer.png" width="170" style="max-width: initial; width: 170px; display: block" />
|
|
169
169
|
</td>
|
|
170
170
|
</tr>
|
|
@@ -198,7 +198,8 @@
|
|
|
198
198
|
</tr>
|
|
199
199
|
<tr>
|
|
200
200
|
<td style="vertical-align: middle;" align="center">
|
|
201
|
-
<div style="text-align:center;"><span style="color:#384860;font-family:Inter,Arial,sans-serif;font-size:16px;letter-spacing:0.20000000298023224px;line-height:150%;text-align:center;">Your Store’s Key Footfall Insights for
|
|
201
|
+
<div style="text-align:center;"><span style="color:#384860;font-family:Inter,Arial,sans-serif;font-size:16px;letter-spacing:0.20000000298023224px;line-height:150%;text-align:center;">Your Store’s Key Footfall Insights for <br />
|
|
202
|
+
{{data.templateData.fromDateFormat}} - {{data.templateData.toDateFormat}}</span></div>
|
|
202
203
|
</td>
|
|
203
204
|
</tr>
|
|
204
205
|
</table>
|
|
@@ -751,12 +752,7 @@
|
|
|
751
752
|
<td valign="middle" width="521" height="40" style="padding-left: 6px; width: 521px; vertical-align: middle; height: 40px">
|
|
752
753
|
|
|
753
754
|
<div background="assets/image_d2366d91.png" width="100.00%" height="40" style="background: url('assets/image_c925bfaf.png') 50% / 100% no-repeat; width: 100%; height: 40px">
|
|
754
|
-
<p class="color-384860" width="100.00%" style="font-size: 14px; font-weight: 500; text-align: left; line-height: 20px; color: #384860; mso-line-height-rule: exactly; margin: 0; padding: 0; width: 100%"><span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly; display: inline-flex; align-items: center;">{{
|
|
755
|
-
{{data.lamdaMetrics.conversionMetrics.highEngagers.storeName}}
|
|
756
|
-
{{/eq}}
|
|
757
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
758
|
-
{{data.lamdaMetrics.conversionMetrics.highPotentialBuyers.storeName}}
|
|
759
|
-
{{/eq}}</span>
|
|
755
|
+
<p class="color-384860" width="100.00%" style="font-size: 14px; font-weight: 500; text-align: left; line-height: 20px; color: #384860; mso-line-height-rule: exactly; margin: 0; padding: 0; width: 100%"><span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly; display: inline-flex; align-items: center;">{{data.lamdaMetrics.conversionMetrics.highData.storeName}}</span>
|
|
760
756
|
<span>
|
|
761
757
|
- High performing store with highest change in
|
|
762
758
|
{{#eq data.featureConfigs.conversionCalculation 'engagers-count'}}
|
|
@@ -765,25 +761,21 @@
|
|
|
765
761
|
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
766
762
|
Potential Buyers
|
|
767
763
|
{{/eq}}
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
{{/eq}}
|
|
771
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
772
|
-
{{data.lamdaMetrics.conversionMetrics.highPotentialBuyers.vsSameDayLastWeekRate}}%
|
|
764
|
+
{{#eq data.featureConfigs.conversionCalculation 'footfall-count'}}
|
|
765
|
+
Footfall
|
|
773
766
|
{{/eq}}
|
|
774
|
-
|
|
767
|
+
|
|
768
|
+
({{data.lamdaMetrics.conversionMetrics.highData.vsSameDayLastWeekRate}}%
|
|
769
|
+
|
|
770
|
+
|
|
771
|
+
{{#eq data.lamdaMetrics.conversionMetrics.highData.vsSameDayLastWeekComparisonFlag true}}
|
|
775
772
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png" border="0" width="12" />
|
|
776
773
|
{{else}}
|
|
777
774
|
<img src="{{data.domain}}/assets/emailers/NegativeVector.png" border="0" width="12" />
|
|
778
775
|
{{/eq}}
|
|
779
776
|
vs same day last week and
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
{{/eq}}
|
|
783
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
784
|
-
{{data.lamdaMetrics.conversionMetrics.highPotentialBuyers.vsMTDAvgRate}}%
|
|
785
|
-
{{/eq}}
|
|
786
|
-
{{#eq data.lamdaMetrics.conversionMetrics.highEngagers.vsMTDAvgComparisonFlag true}}
|
|
777
|
+
{{data.lamdaMetrics.conversionMetrics.highData.vsMTDAvgRate}}%
|
|
778
|
+
{{#eq data.lamdaMetrics.conversionMetrics.highData.vsMTDAvgComparisonFlag true}}
|
|
787
779
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png" border="0" width="12" />
|
|
788
780
|
{{else}}
|
|
789
781
|
<img src="{{data.domain}}/assets/emailers/NegativeVector.png" border="0" width="12" />
|
|
@@ -810,12 +802,7 @@
|
|
|
810
802
|
style="background: url('assets/image_a402f201.png') 50% / 100% no-repeat; width: 100%; height: 40px">
|
|
811
803
|
<p class="color-384860" width="100.00%" style="font-size: 14px; font-weight: 500; text-align: left; line-height: 20px; color: #384860; mso-line-height-rule: exactly; margin: 0; padding: 0; width: 100%">
|
|
812
804
|
<span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly; display: inline-flex; align-items: center;">
|
|
813
|
-
{{
|
|
814
|
-
{{data.lamdaMetrics.conversionMetrics.lowEngagers.storeName}}
|
|
815
|
-
{{/eq}}
|
|
816
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
817
|
-
{{data.lamdaMetrics.conversionMetrics.lowPotentialBuyers.storeName}}
|
|
818
|
-
{{/eq}}
|
|
805
|
+
{{data.lamdaMetrics.conversionMetrics.lowData.storeName}}
|
|
819
806
|
</span>
|
|
820
807
|
<span>
|
|
821
808
|
- Poor performing store with lowest change in
|
|
@@ -825,25 +812,21 @@
|
|
|
825
812
|
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
826
813
|
Potential Buyers
|
|
827
814
|
{{/eq}}
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
{{/eq}}
|
|
831
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
832
|
-
{{data.lamdaMetrics.conversionMetrics.lowPotentialBuyers.vsSameDayLastWeekRate}}%
|
|
815
|
+
{{#eq data.featureConfigs.conversionCalculation 'footfall-count'}}
|
|
816
|
+
Footfall
|
|
833
817
|
{{/eq}}
|
|
834
|
-
|
|
818
|
+
|
|
819
|
+
({{data.lamdaMetrics.conversionMetrics.lowData.vsSameDayLastWeekRate}}%
|
|
820
|
+
|
|
821
|
+
{{#eq data.lamdaMetrics.conversionMetrics.lowData.vsSameDayLastWeekComparisonFlag true}}
|
|
835
822
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png" border="0" width="12" />
|
|
836
823
|
{{else}}
|
|
837
824
|
<img src="{{data.domain}}/assets/emailers/NegativeVector.png" border="0" width="12" />
|
|
838
825
|
{{/eq}}
|
|
839
826
|
vs same day last week and
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
{{
|
|
843
|
-
{{#eq data.featureConfigs.conversionCalculation 'billable-entities'}}
|
|
844
|
-
{{data.lamdaMetrics.conversionMetrics.lowPotentialBuyers.vsMTDAvgRate}}%
|
|
845
|
-
{{/eq}}
|
|
846
|
-
{{#eq data.lamdaMetrics.conversionMetrics.lowEngagers.vsMTDAvgComparisonFlag true}}
|
|
827
|
+
{{data.lamdaMetrics.conversionMetrics.lowData.vsMTDAvgRate}}%
|
|
828
|
+
|
|
829
|
+
{{#eq data.lamdaMetrics.conversionMetrics.lowData.vsMTDAvgComparisonFlag true}}
|
|
847
830
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png" border="0" width="12" />
|
|
848
831
|
{{else}}
|
|
849
832
|
<img src="{{data.domain}}/assets/emailers/NegativeVector.png" border="0" width="12" />
|
|
@@ -899,7 +882,7 @@
|
|
|
899
882
|
<span>NA</span>
|
|
900
883
|
{{else}}
|
|
901
884
|
{{#each data.lamdaMetrics.lowOperationalHours}}
|
|
902
|
-
<span style="font-size: 14px; font-weight: 700">{{storeName}}
|
|
885
|
+
<span style="font-size: 14px; font-weight: 700">{{storeName}}{{#unless @last}},{{/unless}}</span>
|
|
903
886
|
{{/each}}
|
|
904
887
|
{{/eq}}
|
|
905
888
|
<span> - Store with lowest
|
|
@@ -929,7 +912,7 @@
|
|
|
929
912
|
<span>NA</span>
|
|
930
913
|
{{else}}
|
|
931
914
|
{{#each data.lamdaMetrics.fullDownTime}}
|
|
932
|
-
<span style="font-size: 14px; font-weight: 700">{{storeName}}
|
|
915
|
+
<span style="font-size: 14px; font-weight: 700">{{storeName}}{{#unless @last}},{{/unless}}</span>
|
|
933
916
|
{{/each}}
|
|
934
917
|
{{/eq}}
|
|
935
918
|
<span> - Stores
|
|
@@ -948,21 +931,25 @@
|
|
|
948
931
|
</td>
|
|
949
932
|
</tr>
|
|
950
933
|
<tr>
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
934
|
+
<td
|
|
935
|
+
style="padding-top: 12px; padding-bottom: 12px; padding-left: 30px; padding-right: 30px;">
|
|
936
|
+
<a href="https://dashboard.tangoeye.ai/">
|
|
937
|
+
<table class="bg-00a3ff" cellpadding="0" cellspacing="0" border="0" role="presentation"
|
|
938
|
+
bgcolor="#00a3ff" width="580.00" height="48.00"
|
|
939
|
+
style="border-radius: 8px; border: 1px solid #00a3ff; box-shadow: 0px 1px 2px rgba(16, 24, 40, 0.05); background-color: #00a3ff; width: 580px; height: 48px; border-spacing: 0; border-collapse: separate">
|
|
940
|
+
<tr>
|
|
941
|
+
<td valign="middle" width="100.00%" height="46.00"
|
|
942
|
+
style="width: 100%; vertical-align: middle; height: 46px; text-align: center; cursor:pointer !important">
|
|
943
|
+
<span class="color-fffffe"
|
|
944
|
+
style="font-size: 16px; font-weight: 600; text-transform: capitalize; color: white; margin: 0; padding: 0; line-height: 24px; display: inline-block;text-decoration: none;">
|
|
945
|
+
View Detailed Insights
|
|
946
|
+
</span>
|
|
947
|
+
|
|
948
|
+
</td>
|
|
949
|
+
</tr>
|
|
950
|
+
</table>
|
|
951
|
+
</a>
|
|
952
|
+
</td>
|
|
966
953
|
</tr>
|
|
967
954
|
<tr>
|
|
968
955
|
<td align="left" style="padding-top: 12px; padding-bottom: 12px; padding-left: 29px; padding-right: 29px">
|
|
@@ -971,7 +958,7 @@
|
|
|
971
958
|
</tr>
|
|
972
959
|
<tr>
|
|
973
960
|
<td align="center">
|
|
974
|
-
<table cellspacing="0" cellpadding="0" border="0">
|
|
961
|
+
<table cellspacing="0" cellpadding="0" border="0" style="margin-bottom: 5px;">
|
|
975
962
|
<tr>
|
|
976
963
|
<td style="vertical-align: middle;">
|
|
977
964
|
<table cellspacing="0" cellpadding="0" border="0">
|
|
@@ -169,15 +169,15 @@
|
|
|
169
169
|
}
|
|
170
170
|
</style>
|
|
171
171
|
</head>
|
|
172
|
-
<body style="margin: 0; padding: 0; background: #EFEFEF; font-family: Inter;">
|
|
172
|
+
<body style="margin: 0; padding: 10px 0; background: #EFEFEF; font-family: Inter;">
|
|
173
173
|
<div style="font-size: 0px; line-height: 1px; mso-line-height-rule: exactly; display: none; max-width: 0px; max-height: 0px; opacity: 0; overflow: hidden; mso-hide: all"></div>
|
|
174
174
|
<center lang="und" dir="auto" style="width: 100%; table-layout: fixed; -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%">
|
|
175
|
-
<table class="bg-fffffe" cellpadding="0" cellspacing="0" border="0" role="presentation" bgcolor="white" width="640.00" style=" background-color: white; width: 640px; border-spacing: 0; font-family: Inter, Tahoma, sans-serif; min-width: 640px; border-collapse: separate">
|
|
175
|
+
<table class="bg-fffffe" cellpadding="0" cellspacing="0" border="0" role="presentation" bgcolor="white" width="640.00" style=" background-color: white; width: 640px; border-spacing: 0; font-family: Inter, Tahoma, sans-serif; min-width: 640px; border-collapse: separate; border-radius: 12px;">
|
|
176
176
|
<tr>
|
|
177
|
-
<td valign="top" width="100.00%" style="padding-top: 15px;
|
|
177
|
+
<td valign="top" width="100.00%" style="padding-top: 15px; width: 100%; vertical-align: top">
|
|
178
178
|
<table cellpadding="0" cellspacing="0" border="0" role="presentation" width="100.00%" style="width: 100%; border-spacing: 0">
|
|
179
179
|
<tr>
|
|
180
|
-
<td style="padding-bottom:
|
|
180
|
+
<td style="padding-bottom: 4.5px">
|
|
181
181
|
<img src="{{data.domain}}/assets/emailers/Tango Logo mailer.png" width="170" style="max-width: initial; width: 170px; display: block" />
|
|
182
182
|
</td>
|
|
183
183
|
</tr>
|
|
@@ -202,7 +202,7 @@
|
|
|
202
202
|
</tr>
|
|
203
203
|
<tr>
|
|
204
204
|
<td style="padding-top: 6.73px; padding-left: 14.8px; padding-right: 14.8px; mso-padding-left-alt: 0; margin-left: 14.8px">
|
|
205
|
-
<p class="color-fffffe" width="100.00%" style="font-size: 16px; font-weight: 400; letter-spacing: 0.2px; text-align: center; line-height: 24px; color: white; mso-line-height-rule: exactly; margin: 0; padding: 0; width: 100%">Your Store's Key Footfall Insights for <br />{{data.templateData.
|
|
205
|
+
<p class="color-fffffe" width="100.00%" style="font-size: 16px; font-weight: 400; letter-spacing: 0.2px; text-align: center; line-height: 24px; color: white; mso-line-height-rule: exactly; margin: 0; padding: 0; width: 100%">Your Store's Key Footfall Insights for <br />{{data.templateData.fromDateFormat}} - {{data.templateData.toDateFormat}}</p>
|
|
206
206
|
</td>
|
|
207
207
|
</tr>
|
|
208
208
|
</table>
|
|
@@ -721,8 +721,8 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
721
721
|
<td valign="top" width="529" height="40" style="padding-left: 6px; width: 529px; vertical-align: top; height: 40px">
|
|
722
722
|
<div background="assets/image_4e09cef6.png" width="100.00%" height="40" style="background: url('assets/image_b9dd4339.png') 50% / 100% no-repeat; width: 100%; height: 40px">
|
|
723
723
|
<p class="color-384860" width="100.00%" style="font-size: 14px; font-weight: 500; text-align: left; line-height: 20px; color: #384860; mso-line-height-rule: exactly; margin: 0; padding: 0; width: 100%">
|
|
724
|
-
<span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly">{{data.lamdaMetrics.highestWeekendFootfall.PeekFootfallDay}}</span><span> recorded the highest footfall, with </span>
|
|
725
|
-
<span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly">{{data.lamdaMetrics.highestWeekendFootfall.customerCount}}</span><span> customers between<br /></span><span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly">{{data.lamdaMetrics.
|
|
724
|
+
<span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly">{{data.lamdaMetrics.highestWeekendFootfall.PeekFootfallDay}}</span><span> recorded the highest weekend footfall, with </span>
|
|
725
|
+
<span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly">{{data.lamdaMetrics.highestWeekendFootfall.customerCount}}</span><span> customers between<br /></span><span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly">{{data.lamdaMetrics.highestWeekendFootfall.PeekFootfallBetween}} </span><span>(</span><span style="font-size: 14px; font-weight: 700; text-align: left; line-height: 20px; mso-line-height-rule: exactly;display: inline-flex; align-items: center;">{{data.lamdaMetrics.highestWeekendFootfall.vsLastWeekRate}}%
|
|
726
726
|
{{#eq data.lamdaMetrics.emailerCards.highestWeekendFootfall.vsLastWeekComparisonFlag true}}
|
|
727
727
|
<img src="{{data.domain}}/assets/emailers/PositiveVector.png"
|
|
728
728
|
border="0" width="12"/>
|
|
@@ -804,20 +804,25 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
804
804
|
</td>
|
|
805
805
|
</tr>
|
|
806
806
|
<tr>
|
|
807
|
-
<td
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
807
|
+
<td
|
|
808
|
+
style="padding-top: 12px; padding-bottom: 12px; padding-left: 30px; padding-right: 30px;">
|
|
809
|
+
<a href="https://dashboard.tangoeye.ai/">
|
|
810
|
+
<table class="bg-00a3ff" cellpadding="0" cellspacing="0" border="0" role="presentation"
|
|
811
|
+
bgcolor="#00a3ff" width="580.00" height="48.00"
|
|
812
|
+
style="border-radius: 8px; border: 1px solid #00a3ff; box-shadow: 0px 1px 2px rgba(16, 24, 40, 0.05); background-color: #00a3ff; width: 580px; height: 48px; border-spacing: 0; border-collapse: separate">
|
|
813
|
+
<tr>
|
|
811
814
|
<td valign="middle" width="100.00%" height="46.00"
|
|
812
|
-
style="width: 100%; vertical-align: middle; height: 46px; text-align: center;">
|
|
813
|
-
<
|
|
815
|
+
style="width: 100%; vertical-align: middle; height: 46px; text-align: center; cursor:pointer !important">
|
|
816
|
+
<span class="color-fffffe"
|
|
814
817
|
style="font-size: 16px; font-weight: 600; text-transform: capitalize; color: white; margin: 0; padding: 0; line-height: 24px; display: inline-block;text-decoration: none;">
|
|
815
|
-
|
|
816
|
-
|
|
818
|
+
View Detailed Insights
|
|
819
|
+
</span>
|
|
820
|
+
|
|
817
821
|
</td>
|
|
818
822
|
</tr>
|
|
819
|
-
|
|
820
|
-
|
|
823
|
+
</table>
|
|
824
|
+
</a>
|
|
825
|
+
</td>
|
|
821
826
|
</tr>
|
|
822
827
|
<tr>
|
|
823
828
|
<td align="left" style="padding-top: 12px; padding-bottom: 12px; padding-left: 29px; padding-right: 29px">
|
|
@@ -826,7 +831,7 @@ background: radial-gradient(circle at 16.16% 32.77%, rgba(255, 255, 255, 0.40) 0
|
|
|
826
831
|
</tr>
|
|
827
832
|
<tr>
|
|
828
833
|
<td align="center">
|
|
829
|
-
<table cellspacing="0" cellpadding="0" border="0">
|
|
834
|
+
<table cellspacing="0" cellpadding="0" border="0" style="margin-bottom: 20px;">
|
|
830
835
|
<tr>
|
|
831
836
|
<td style="vertical-align: middle;">
|
|
832
837
|
<table cellspacing="0" cellpadding="0" border="0">
|