@manyos/smileconnect-api 1.71.6 → 1.71.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.
@@ -198,6 +198,7 @@ function queryCMDBObject(clientConfig, query, customFields, customOptions, inclu
198
198
  async function handleCMDBObjectResult(cmdbObject, mapping, clientConfig, includeArray, globalRelationObjects, deleteFields, globalScriptParams) {
199
199
  const internalReconId = cmdbObject['Reconciliation Identity'];
200
200
  const internalId = cmdbObject['Instance Id'];
201
+ const classId = cmdbObject['Class Id'];
201
202
 
202
203
  deleteFields.forEach(internalRequiredField => {
203
204
  delete cmdbObject[internalRequiredField];
package/docs/releases.md CHANGED
@@ -1,6 +1,13 @@
1
1
  # Release Notes
2
2
 
3
3
  ## API
4
+ ### 1.71.8 - 22.10.25
5
+ Fix error when include classAttributes was used in CI Search
6
+
7
+ ### 1.71.7 - 10.07.25
8
+ Return 404 if ticketWorklog is not found
9
+ Return 404 if task is not found
10
+
4
11
  ### 1.71.6 - 01.07.25
5
12
  Enhance stability of oauth2 Adapter
6
13
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@manyos/smileconnect-api",
3
- "version": "1.71.6",
3
+ "version": "1.71.8",
4
4
  "description": "A proxy and abstraction layer for BMCs IT Service Management Suite",
5
5
  "main": "app.js",
6
6
  "scripts": {
@@ -112,8 +112,12 @@ module.exports = (function () {
112
112
  );
113
113
 
114
114
  const result = await task.getTaskByRootRequest(req.user.config, parentId, taskId, req.globalScriptParams, includeString);
115
- req.includeObjectsList = result.included;
116
- req.result = {data:result.data || {}};
115
+ if (result.data) {
116
+ req.includeObjectsList = result.included;
117
+ req.result = {data:result.data || {}};
118
+ } else {
119
+ req.responseStatus = 404;
120
+ }
117
121
  next();
118
122
  });
119
123
 
@@ -260,9 +264,13 @@ module.exports = (function () {
260
264
  "self" : `/v1/${req.parentType}/${req.parentId}/tasks/${taskId}/worklogs/${worklogId}`
261
265
  };
262
266
  log.debug('res', urls);
263
- req.includeObjectsList = result.included;
264
- req.result = {data:result.data || {}};
265
- req.result.urls = urls;
267
+ if (result.data) {
268
+ req.includeObjectsList = result.included;
269
+ req.result = {data: result.data || {}};
270
+ req.result.urls = urls;
271
+ } else {
272
+ req.responseStatus = 404;
273
+ }
266
274
  next();
267
275
  });
268
276
 
@@ -346,4 +354,4 @@ module.exports = (function () {
346
354
  });
347
355
 
348
356
  return taskRoutes;
349
- })();
357
+ })();
@@ -68,7 +68,11 @@ module.exports = (function() {
68
68
  worklogId
69
69
  );
70
70
  ticketWorkLogController.getWorklog(req.ticketConfig, req.user.config, ticketId, worklogId, undefined, req.globalScriptParams).then(function (result) {
71
- req.result = result;
71
+ if (!result.data) {
72
+ req.responseStatus = 404;
73
+ } else {
74
+ req.result = result;
75
+ }
72
76
  next();
73
77
  }).catch(function (reason) {
74
78
  next(reason);
@@ -210,4 +214,4 @@ module.exports = (function() {
210
214
  });
211
215
 
212
216
  return ticketWorkLogRoutes;
213
- })();
217
+ })();