@icure/be-fhc-api 0.5.11 → 0.5.13
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 +1 -1
- package/x-api/message-x-api.js +3 -11
package/package.json
CHANGED
package/x-api/message-x-api.js
CHANGED
|
@@ -41,7 +41,7 @@ class MessageXApi {
|
|
|
41
41
|
requestDate: requestDate ? moment(requestDate).format("DD/MM/YYYY") : ""
|
|
42
42
|
},
|
|
43
43
|
subject: "Lists request",
|
|
44
|
-
senderReferences: req.commonOutput
|
|
44
|
+
senderReferences: req.commonOutput ? Object.assign(Object.assign(Object.assign({}, (req.commonOutput.inputReference ? { inputReference: req.commonOutput.inputReference } : {})), (req.commonOutput.nipReference ? { nipReference: req.commonOutput.nipReference } : {})), (req.commonOutput.outputReference ? { outputReference: req.commonOutput.outputReference } : {})) : undefined,
|
|
45
45
|
})
|
|
46
46
|
.then(msg => this.api.createMessage(msg))
|
|
47
47
|
.then(msg => {
|
|
@@ -346,11 +346,7 @@ class MessageXApi {
|
|
|
346
346
|
subject: inss
|
|
347
347
|
? `${msgName} from IO ${dmgMessage.io} for ${inss}`
|
|
348
348
|
: `${msgName} from IO ${dmgMessage.io}`,
|
|
349
|
-
senderReferences: {
|
|
350
|
-
inputReference: dmgMessage.commonOutput && dmgMessage.commonOutput.inputReference,
|
|
351
|
-
outputReference: dmgMessage.commonOutput && dmgMessage.commonOutput.outputReference,
|
|
352
|
-
nipReference: dmgMessage.commonOutput && dmgMessage.commonOutput.nipReference
|
|
353
|
-
}
|
|
349
|
+
senderReferences: dmgMessage.commonOutput ? Object.assign(Object.assign(Object.assign({}, (dmgMessage.commonOutput.inputReference ? { inputReference: dmgMessage.commonOutput.inputReference } : {})), (dmgMessage.commonOutput.nipReference ? { nipReference: dmgMessage.commonOutput.nipReference } : {})), (dmgMessage.commonOutput.outputReference ? { outputReference: dmgMessage.commonOutput.outputReference } : {})) : undefined
|
|
354
350
|
})
|
|
355
351
|
.then(msg => this.api.createMessage(msg))
|
|
356
352
|
.then(msg => {
|
|
@@ -621,11 +617,7 @@ class MessageXApi {
|
|
|
621
617
|
received: +new Date(),
|
|
622
618
|
subject: messageType,
|
|
623
619
|
parentId: parentMessage.id,
|
|
624
|
-
senderReferences: {
|
|
625
|
-
inputReference: efactMessage.commonOutput.inputReference,
|
|
626
|
-
outputReference: efactMessage.commonOutput.outputReference,
|
|
627
|
-
nipReference: efactMessage.commonOutput.nipReference
|
|
628
|
-
}
|
|
620
|
+
senderReferences: efactMessage.commonOutput ? Object.assign(Object.assign(Object.assign({}, (efactMessage.commonOutput.inputReference ? { inputReference: efactMessage.commonOutput.inputReference } : {})), (efactMessage.commonOutput.nipReference ? { nipReference: efactMessage.commonOutput.nipReference } : {})), (efactMessage.commonOutput.outputReference ? { outputReference: efactMessage.commonOutput.outputReference } : {})) : undefined
|
|
629
621
|
})
|
|
630
622
|
.then(msg => this.api.createMessage(msg))
|
|
631
623
|
.then(msg => Promise.all([
|