@contrail/flexplm 1.1.27 → 1.1.29

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.
@@ -153,11 +153,11 @@ class BaseEntityProcessor {
153
153
  }
154
154
  const payload = await this.getOutgoingUpsertPayload(entityType, event);
155
155
  const flexResponse = await new flexplm_connect_1.FlexPLMConnect(this.config).sendToFlexPLM(payload);
156
- const flexPayload = flexResponse?.results?.data?.payload[0];
156
+ const flexPayload = flexResponse?.data?.payload[0];
157
157
  if (flexPayload) {
158
158
  const inboundData = await this.getTransformedData(flexPayload);
159
- const inboundEntityUpdates = await this.getUpdatesForEntity(event.newData, inboundData);
160
- flexResponse['inboundEntityUpdates'] = inboundEntityUpdates;
159
+ const outboundEntityUpdates = await this.getUpdatesForEntity(event.newData, inboundData);
160
+ flexResponse['outboundEntityUpdates'] = outboundEntityUpdates;
161
161
  }
162
162
  return flexResponse;
163
163
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contrail/flexplm",
3
- "version": "1.1.27",
3
+ "version": "1.1.29",
4
4
  "description": "Library used for integration with flexplm.",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",
@@ -199,11 +199,11 @@ export abstract class BaseEntityProcessor {
199
199
  const payload = await this.getOutgoingUpsertPayload(entityType, event);
200
200
  const flexResponse: any = await new FlexPLMConnect(this.config).sendToFlexPLM(payload);
201
201
 
202
- const flexPayload = flexResponse?.results?.data?.payload[0];
202
+ const flexPayload = flexResponse?.data?.payload[0];
203
203
  if(flexPayload) {
204
204
  const inboundData = await this.getTransformedData(flexPayload);
205
- const inboundEntityUpdates = await this.getUpdatesForEntity(event.newData, inboundData)
206
- flexResponse['inboundEntityUpdates'] = inboundEntityUpdates;
205
+ const outboundEntityUpdates = await this.getUpdatesForEntity(event.newData, inboundData)
206
+ flexResponse['outboundEntityUpdates'] = outboundEntityUpdates;
207
207
  }
208
208
 
209
209
  return flexResponse;