tango-app-api-infra 3.1.34-beta.7 → 3.1.34-beta.8
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
CHANGED
|
@@ -91,7 +91,7 @@ export async function basicList( req, res ) {
|
|
|
91
91
|
for ( let client of clientList ) {
|
|
92
92
|
clients.push( client.clientId );
|
|
93
93
|
}
|
|
94
|
-
let storeList = await findStore( { 'clientId': { $in: clients }, 'status': 'active', 'edge.firstFile': true },
|
|
94
|
+
let storeList = await findStore( { 'clientId': { $in: clients }, 'status': 'active', 'edge.firstFile': true,"storeProfile.open":{$exists:true},"storeProfile.close":{$exists:true},'storeProfile.timeZone':{$exists:true} },
|
|
95
95
|
{ 'storeName': 1, 'storeId': 1, 'ticketConfigs': 1, 'clientId': 1, 'storeProfile.open': 1, 'storeProfile.close': 1, 'storeProfile.timeZone': 1 } );
|
|
96
96
|
logger.info( { 'storeList': storeList, 'message': 'storeList' } );
|
|
97
97
|
|
|
@@ -826,7 +826,10 @@ export async function edgeApplogsCheck( req, res ) {
|
|
|
826
826
|
const occurringTimeParsed = dayjs( `${req.body.date} ${findissue.edgelog.occuringTime}` );
|
|
827
827
|
const ticketCreatedParsed = dayjs( `${req.body.date} ${istTimestamp}` );
|
|
828
828
|
const isOccurringTimeEarlier = occurringTimeParsed.isBefore( ticketCreatedParsed );
|
|
829
|
-
|
|
829
|
+
const existsInArray = finalresult.some( ( item ) =>
|
|
830
|
+
item.ticketId === ticket.ticketId,
|
|
831
|
+
);
|
|
832
|
+
if ( isOccurringTimeEarlier&&!existsInArray ) {
|
|
830
833
|
findissueEdgeApp = {
|
|
831
834
|
ticketId: ticket.ticketId,
|
|
832
835
|
edgelog: findissue,
|
|
@@ -844,7 +847,10 @@ export async function edgeApplogsCheck( req, res ) {
|
|
|
844
847
|
const stroreopenTime = dayjs( `${req.body.date} ${store.storeProfile.open}` );
|
|
845
848
|
const isOccurringTimeEarlier = occurringTimeParsed.isBefore( ticketCreatedParsed );
|
|
846
849
|
const afterStoreOpen = occurringTimeParsed.isAfter( stroreopenTime );
|
|
847
|
-
|
|
850
|
+
const existsInArray = finalresult.some( ( item ) =>
|
|
851
|
+
item.ticketId === ticket.ticketId,
|
|
852
|
+
);
|
|
853
|
+
if ( isOccurringTimeEarlier&&afterStoreOpen&&!existsInArray ) {
|
|
848
854
|
logincount.push( findissue.edgelog.occuringTime );
|
|
849
855
|
if ( logincount.length >3 ) {
|
|
850
856
|
findissueEdgeApp = {
|
|
@@ -956,7 +962,10 @@ export async function edgeApplogsCheck( req, res ) {
|
|
|
956
962
|
const occurringTimeParsed = dayjs( `${req.body.date} ${findissue.edgelog.occuringTime}` );
|
|
957
963
|
const ticketCreatedParsed = dayjs( `${req.body.date} ${istTimestamp}` );
|
|
958
964
|
const isOccurringTimeEarlier = occurringTimeParsed.isBefore( ticketCreatedParsed );
|
|
959
|
-
|
|
965
|
+
const existsInArray = finalresult.some( ( item ) =>
|
|
966
|
+
item.ticketId === ticket.ticketId,
|
|
967
|
+
);
|
|
968
|
+
if ( isOccurringTimeEarlier&&!existsInArray ) {
|
|
960
969
|
findissueEdgeApp = {
|
|
961
970
|
ticketId: ticket.ticketId,
|
|
962
971
|
edgelog: findissue,
|