tango-app-api-task 3.4.0-alpha-2 → 3.4.0-alpha-3

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-task",
3
- "version": "3.4.0-alpha-2",
3
+ "version": "3.4.0-alpha-3",
4
4
  "description": "Task",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -1000,7 +1000,7 @@ export async function taskConfig( req, res ) {
1000
1000
  };
1001
1001
  await checklistLogs.create( logInsertData );
1002
1002
 
1003
- checklistDetails = await taskService.findOne( { _id: inputBody._id, isdeleted: false, client_id: inputBody.clientId } );
1003
+ checklistDetails = await taskService.findOne( { _id: inputBody._id, isdeleted: false, client_id: inputBody.clientId, checkListName: 1 } );
1004
1004
 
1005
1005
  if ( !checklistDetails ) {
1006
1006
  return res.sendError( 'No data found', 204 );
@@ -1092,7 +1092,7 @@ export async function taskConfig( req, res ) {
1092
1092
  client_id: inputBody.clientId,
1093
1093
  createAt: new Date(),
1094
1094
  sourceCheckList_id: configDetails._id,
1095
- checkListName: configDetails.checkListName,
1095
+ checkListName: checklistDetails.checkListName,
1096
1096
  fromCheckListName: '',
1097
1097
  type: 'task',
1098
1098
  action: 'updated',
@@ -1140,7 +1140,7 @@ export async function taskConfig( req, res ) {
1140
1140
  client_id: inputBody.client_id,
1141
1141
  createAt: new Date(),
1142
1142
  sourceCheckList_id: inputBody._id,
1143
- checkListName: inputBody.checkListName,
1143
+ checkListName: checklistDetails.checkListName,
1144
1144
  fromCheckListName: '',
1145
1145
  type: 'task',
1146
1146
  action: inputBody.publish ? 'published' : 'unpublished',
@@ -2789,7 +2789,7 @@ export const updatePublish = async ( req, res ) => {
2789
2789
 
2790
2790
  if ( req.body.checklistId ) {
2791
2791
  query = { _id: req.body.checklistId };
2792
- getCheckDetails = await taskService.findOne( { _id: req.body.checklistId, client_id: req.body.clientId } );
2792
+ getCheckDetails = await taskService.findOne( { _id: req.body.checklistId, client_id: req.body.clientId, checkListName: 1 } );
2793
2793
  }
2794
2794
 
2795
2795
  if ( !getCheckDetails ) {