tango-app-api-trax 3.4.1-alpha-17 → 3.4.1-alpha-18
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
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tango-app-api-trax",
|
|
3
|
-
"version": "3.4.1-alpha-
|
|
3
|
+
"version": "3.4.1-alpha-18",
|
|
4
4
|
"description": "Trax",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"nodemon": "^3.1.4",
|
|
28
28
|
"path": "^0.12.7",
|
|
29
29
|
"tango-api-schema": "^2.2.73",
|
|
30
|
-
"tango-app-api-middleware": "^3.1.
|
|
30
|
+
"tango-app-api-middleware": "^3.1.66",
|
|
31
31
|
"url": "^0.11.4",
|
|
32
32
|
"winston": "^3.13.1",
|
|
33
33
|
"winston-daily-rotate-file": "^5.0.0"
|
|
@@ -1127,7 +1127,7 @@ export async function pushNotification( req, res ) {
|
|
|
1127
1127
|
const description = `The ${data.checklistName} checklist is due. Complete it within ${data.time} minutes to avoid compliance.`;
|
|
1128
1128
|
const fcmToken = item.token;
|
|
1129
1129
|
try {
|
|
1130
|
-
await sendPushNotification( title, description,
|
|
1130
|
+
await sendPushNotification( title, description, fcmToken );
|
|
1131
1131
|
} catch ( e ) {
|
|
1132
1132
|
logger.error( {
|
|
1133
1133
|
message: 'push notification',
|
|
@@ -1543,7 +1543,7 @@ export async function taskPushNotification( req, res ) {
|
|
|
1543
1543
|
|
|
1544
1544
|
const fcmToken = item.token;
|
|
1545
1545
|
try {
|
|
1546
|
-
await sendPushNotification( title, description,
|
|
1546
|
+
await sendPushNotification( title, description, fcmToken );
|
|
1547
1547
|
} catch ( e ) {
|
|
1548
1548
|
logger.error( {
|
|
1549
1549
|
message: 'push notification',
|
|
@@ -1612,7 +1612,7 @@ export async function internalSendPushNotification( req, res ) {
|
|
|
1612
1612
|
// return res.sendError( 'Token not found', 400 );
|
|
1613
1613
|
return res.sendSuccess( 'Notification Send Successfully' );
|
|
1614
1614
|
}
|
|
1615
|
-
let responseData = await sendPushNotification( requestData.title, requestData.description,
|
|
1615
|
+
let responseData = await sendPushNotification( requestData.title, requestData.description, fcmToken );
|
|
1616
1616
|
// console.log( 'responseData =>', responseData );
|
|
1617
1617
|
if ( responseData ) {
|
|
1618
1618
|
return res.sendSuccess( 'Notification Send Successfully' );
|
|
@@ -3459,14 +3459,14 @@ async function insertPCBulkV4( getCLconfig, checklistId, currentdate, updatedche
|
|
|
3459
3459
|
const title = `${getCLconfig.checkListName}`;
|
|
3460
3460
|
const description = `Checklist has been updated and re-published!`;
|
|
3461
3461
|
const fcmToken = item;
|
|
3462
|
-
sendPushNotification( title, description,
|
|
3462
|
+
sendPushNotification( title, description, fcmToken );
|
|
3463
3463
|
} );
|
|
3464
3464
|
|
|
3465
3465
|
notifyUserList.forEach( ( item ) => {
|
|
3466
3466
|
const title = `New Checklist Assigned ${item.storeName}`;
|
|
3467
3467
|
const description = `The ${getCLconfig.checkListName} checklist has been assigned to ${item.storeName} for the first time.complete to avoid compliance.`;
|
|
3468
3468
|
const fcmToken = item.token;
|
|
3469
|
-
sendPushNotification( title, description,
|
|
3469
|
+
sendPushNotification( title, description, fcmToken );
|
|
3470
3470
|
} );
|
|
3471
3471
|
|
|
3472
3472
|
let updateUserList = notifyUserList.map( ( ele ) => ele.id );
|