tango-app-api-trax 3.4.1-alpha-2 → 3.4.1-alpha-4

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-2",
3
+ "version": "3.4.1-alpha-4",
4
4
  "description": "Trax",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -26,7 +26,7 @@
26
26
  "mongodb": "^6.8.0",
27
27
  "nodemon": "^3.1.4",
28
28
  "path": "^0.12.7",
29
- "tango-api-schema": "^2.2.70",
29
+ "tango-api-schema": "^2.2.73",
30
30
  "tango-app-api-middleware": "^3.1.55",
31
31
  "url": "^0.11.4",
32
32
  "winston": "^3.13.1",
@@ -1027,7 +1027,8 @@ export async function sopMobilechecklistMultiSectionFormatterv1( req, res, next
1027
1027
  try {
1028
1028
  let requestData = req.body;
1029
1029
  requestData.questionAnswers = typeof requestData.questionAnswers == 'string' ? JSON.parse( requestData.questionAnswers ) : requestData.questionAnswers;
1030
- let getChecklistQA = await processedchecklist.findOne( { _id: new ObjectId( requestData.processedcheckListId ) }, { questionAnswers: 1 } );
1030
+ let getDetails = await processedchecklist.findOne( { _id: new ObjectId( requestData.processedcheckListId ) }, { checkListId: 1 } );
1031
+ let getChecklistQA = await PCLconfig.findOne( { _id: getDetails.checkListId }, { questionAnswers: 1 } );
1031
1032
  let reqAnswers = requestData.questionAnswers;
1032
1033
  logger.error( { functionName: 'updatedPayload', message: reqAnswers } );
1033
1034
  let CLQAnswers = getChecklistQA.questionAnswers;
@@ -1349,7 +1350,7 @@ export async function sopMobilechecklistMultiSectionFormatterv1( req, res, next
1349
1350
  let des = [];
1350
1351
  if ( requestSection[i].answer != 'null' && requestSection[i].answer != '' && requestSection[i].answer != null ) {
1351
1352
  let validationAnswer = '';
1352
- if ( requestSection[i].answer.split( '?' ).length > 1 ) {
1353
+ if ( requestSection[i].answer.includes( 'https' ) ) {
1353
1354
  validationAnswer = decodeURIComponent( requestSection[i].answer.split( '?' )[0] );
1354
1355
  }
1355
1356
  if ( validationAnswer.length ) {
@@ -2521,7 +2522,7 @@ export async function checklistv1( req, res ) {
2521
2522
  ...projectExtraConditions,
2522
2523
  client_id: { $ifNull: [ '$client_id', '' ] },
2523
2524
  coverage: { $ifNull: [ '$coverage', '' ] },
2524
- taskType: { $ifNull: [ '$type', '' ] },
2525
+ taskType: { $ifNull: [ '$planoType', '' ] },
2525
2526
  },
2526
2527
  },
2527
2528
  ];