mirror of
https://github.com/node-ebics/node-ebics-client.git
synced 2024-11-21 21:52:07 +00:00
Update GenericOrder.js file
Add toTransferXML method Add encryptedOrderData method Clean some lines
This commit is contained in:
parent
7979999466
commit
140c2ccd69
@ -24,8 +24,6 @@ module.exports = class GenericOrder {
|
||||
doubleQuotes: true,
|
||||
indent: '',
|
||||
newline: '',
|
||||
// indent: "\t",
|
||||
// newline: "\r\n",
|
||||
pretty: true
|
||||
}
|
||||
};
|
||||
@ -137,6 +135,45 @@ module.exports = class GenericOrder {
|
||||
return js2xmlparser.parse(this.root(), xmlObj, this.xmlOptions);
|
||||
}
|
||||
|
||||
toTransferXML(){
|
||||
const xmlObj = {
|
||||
"@": {
|
||||
"xmlns:ds": "http://www.w3.org/2000/09/xmldsig#",
|
||||
xmlns: "urn:org:ebics:H004",
|
||||
Version: "H004",
|
||||
Revision: "1"
|
||||
},
|
||||
|
||||
header: {
|
||||
"@": { authenticate: true },
|
||||
static: {
|
||||
HostID: this.hostId,
|
||||
TransactionID: this.transactionId
|
||||
},
|
||||
mutable: {
|
||||
TransactionPhase: 'Transfer',
|
||||
SegmentNumber: {
|
||||
"@": { lastSegment: true },
|
||||
"#": 1
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
AuthSignature: this.authSignature(),
|
||||
|
||||
body: {
|
||||
DataTransfer: {
|
||||
OrderData: this.encryptedOrderData()
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
return js2xmlparser.parse(this.root(), xmlObj, this.xmlOptions);
|
||||
}
|
||||
|
||||
encryptedOrderData() {
|
||||
}
|
||||
|
||||
toXML() {
|
||||
return js2xmlparser.parse(this.root(), this._schema, this.xmlOptions);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user