@yousolution/node-red-contrib-you-sap-service-layer 0.1.0 → 0.1.1
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/CHANGELOG.md +6 -0
- package/nodes/SQLQuery.js +1 -1
- package/nodes/authenticateSap.html +18 -1
- package/nodes/authenticateSap.js +18 -4
- package/nodes/crossJoinSap.js +1 -1
- package/nodes/listSap.js +1 -1
- package/nodes/nextLink.html +68 -59
- package/nodes/patchSap.html +9 -0
- package/nodes/support.js +13 -13
- package/package.json +2 -1
- package/test/support.spec.js +28 -28
- package/data/package.json +0 -14
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
|
|
5
|
+
# [0.1.1] - 2022-12-09
|
|
6
|
+
|
|
7
|
+
- Added label output to nextLink block
|
|
8
|
+
- Fix authentication for subflows compatibility
|
|
9
|
+
- Bug fix
|
|
10
|
+
|
|
5
11
|
# [0.1.0] - 2022-07-28
|
|
6
12
|
|
|
7
13
|
- Added sqlQuery node to execute saved sql from SAP Service Layer
|
package/nodes/SQLQuery.js
CHANGED
|
@@ -29,7 +29,7 @@ module.exports = function (RED) {
|
|
|
29
29
|
const login = Support.login;
|
|
30
30
|
const result = await Support.sendRequest({ node, msg, config, axios, login, options });
|
|
31
31
|
msg.payload = result.data;
|
|
32
|
-
msg.nextLink = result.data['odata.nextLink'];
|
|
32
|
+
msg.nextLink = result.data['odata.nextLink'] || result.data['@odata.nextLink'];
|
|
33
33
|
msg.statusCode = result.status;
|
|
34
34
|
node.status({ fill: 'green', shape: 'dot', text: 'success' });
|
|
35
35
|
node.send(msg);
|
|
@@ -9,8 +9,10 @@
|
|
|
9
9
|
version: {value: ''}
|
|
10
10
|
},
|
|
11
11
|
credentials: {
|
|
12
|
-
company: {type: "string"},
|
|
12
|
+
company: {type: "string"},
|
|
13
|
+
companyType: {type: 'string'},
|
|
13
14
|
user: {type:"string"},
|
|
15
|
+
userType: {type: 'string'},
|
|
14
16
|
password: {type:"password"}
|
|
15
17
|
},
|
|
16
18
|
inputs:1,
|
|
@@ -18,6 +20,19 @@
|
|
|
18
20
|
icon: 'font-awesome/fa-lock',
|
|
19
21
|
label: function() {
|
|
20
22
|
return this.name||"Sap authenticate";
|
|
23
|
+
},
|
|
24
|
+
oneditprepare: function() {
|
|
25
|
+
$("#node-input-company").typedInput({
|
|
26
|
+
default:"msg",
|
|
27
|
+
types:["msg", "str"],
|
|
28
|
+
typeField: "#node-input-companyType"
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
$("#node-input-user").typedInput({
|
|
32
|
+
default:"msg",
|
|
33
|
+
types:["msg", "str"],
|
|
34
|
+
typeField: "#node-input-userType"
|
|
35
|
+
});
|
|
21
36
|
}
|
|
22
37
|
});
|
|
23
38
|
</script>
|
|
@@ -49,11 +64,13 @@
|
|
|
49
64
|
<div class="form-row">
|
|
50
65
|
<label for="node-input-company"><i class="fa fa-tag"></i> Company</label>
|
|
51
66
|
<input type="text" id="node-input-company" placeholder="company">
|
|
67
|
+
<input type="hidden" id="node-input-companyType">
|
|
52
68
|
</div>
|
|
53
69
|
|
|
54
70
|
<div class="form-row">
|
|
55
71
|
<label for="node-input-user"><i class="fa fa-tag"></i> User</label>
|
|
56
72
|
<input type="text" id="node-input-user" placeholder="user">
|
|
73
|
+
<input type="hidden" id="node-input-userType">
|
|
57
74
|
</div>
|
|
58
75
|
|
|
59
76
|
<div class="form-row">
|
package/nodes/authenticateSap.js
CHANGED
|
@@ -9,9 +9,9 @@ module.exports = function (RED) {
|
|
|
9
9
|
// reset status
|
|
10
10
|
node.status({});
|
|
11
11
|
|
|
12
|
-
const
|
|
12
|
+
const globalContext = node.context().global;
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
globalContext.set(`_YOU_SapServiceLayer_${node.id}`, {
|
|
15
15
|
host: config.host,
|
|
16
16
|
port: config.port,
|
|
17
17
|
version: config.version,
|
|
@@ -27,6 +27,18 @@ module.exports = function (RED) {
|
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
node.on('input', async (msg, send, done) => {
|
|
30
|
+
// If Company setted from msg
|
|
31
|
+
if (node.credentials.companyType == 'msg') {
|
|
32
|
+
const company = msg[node.credentials.company];
|
|
33
|
+
globalContext.set(`_YOU_SapServiceLayer_${node.id}.credentials.CompanyDB`, company);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// If User setted from msg
|
|
37
|
+
if (node.credentials.userType == 'msg') {
|
|
38
|
+
const user = msg[node.credentials.user];
|
|
39
|
+
globalContext.set(`_YOU_SapServiceLayer_${node.id}.credentials.UserName`, user);
|
|
40
|
+
}
|
|
41
|
+
|
|
30
42
|
// reset status
|
|
31
43
|
node.status({});
|
|
32
44
|
|
|
@@ -36,7 +48,7 @@ module.exports = function (RED) {
|
|
|
36
48
|
return;
|
|
37
49
|
}
|
|
38
50
|
|
|
39
|
-
const headers =
|
|
51
|
+
const headers = globalContext.get(`_YOU_SapServiceLayer_${node.id}.headers`);
|
|
40
52
|
|
|
41
53
|
msg._YOU_SapServiceLayer = {
|
|
42
54
|
idAuth: node.id,
|
|
@@ -45,7 +57,7 @@ module.exports = function (RED) {
|
|
|
45
57
|
if (!headers) {
|
|
46
58
|
try {
|
|
47
59
|
const result = await Support.login(node, node.id);
|
|
48
|
-
|
|
60
|
+
globalContext.set(`_YOU_SapServiceLayer_${node.id}.headers`, result.headers['set-cookie']);
|
|
49
61
|
} catch (error) {
|
|
50
62
|
msg.payload = error;
|
|
51
63
|
if (error.response && error.response.data) {
|
|
@@ -65,7 +77,9 @@ module.exports = function (RED) {
|
|
|
65
77
|
RED.nodes.registerType('authenticateSap', AuthenticateSapNode, {
|
|
66
78
|
credentials: {
|
|
67
79
|
company: { type: 'text' },
|
|
80
|
+
companyType: { type: 'text' },
|
|
68
81
|
user: { type: 'text' },
|
|
82
|
+
userType: { type: 'text' },
|
|
69
83
|
password: { type: 'password' },
|
|
70
84
|
},
|
|
71
85
|
});
|
package/nodes/crossJoinSap.js
CHANGED
|
@@ -21,7 +21,7 @@ module.exports = function (RED) {
|
|
|
21
21
|
const result = await Support.sendRequest({ node, msg, config, axios, login, options });
|
|
22
22
|
msg.payload = result.data;
|
|
23
23
|
msg.statusCode = result.status;
|
|
24
|
-
msg.nextLink = result.data['odata.nextLink'];
|
|
24
|
+
msg.nextLink = result.data['odata.nextLink'] || result.data['@odata.nextLink'];
|
|
25
25
|
node.status({ fill: 'green', shape: 'dot', text: 'success' });
|
|
26
26
|
node.send(msg);
|
|
27
27
|
} catch (error) {
|
package/nodes/listSap.js
CHANGED
|
@@ -20,7 +20,7 @@ module.exports = function (RED) {
|
|
|
20
20
|
const login = Support.login;
|
|
21
21
|
const result = await Support.sendRequest({ node, msg, config, axios, login, options });
|
|
22
22
|
msg.payload = result.data;
|
|
23
|
-
msg.nextLink = result.data['odata.nextLink'];
|
|
23
|
+
msg.nextLink = result.data['odata.nextLink'] || result.data['@odata.nextLink'];
|
|
24
24
|
msg.statusCode = result.status;
|
|
25
25
|
node.status({ fill: 'green', shape: 'dot', text: 'success' });
|
|
26
26
|
node.send(msg);
|
package/nodes/nextLink.html
CHANGED
|
@@ -1,91 +1,100 @@
|
|
|
1
1
|
<script type="text/javascript">
|
|
2
|
-
RED.nodes.registerType('nextLink',{
|
|
2
|
+
RED.nodes.registerType('nextLink', {
|
|
3
3
|
category: 'Sap',
|
|
4
4
|
color: '#FFC300',
|
|
5
5
|
defaults: {
|
|
6
|
-
name: {value: ''},
|
|
7
|
-
nextLink: {value: ''}
|
|
6
|
+
name: { value: '' },
|
|
7
|
+
nextLink: { value: '' },
|
|
8
8
|
},
|
|
9
|
-
inputs:1,
|
|
10
|
-
outputs:2,
|
|
9
|
+
inputs: 1,
|
|
10
|
+
outputs: 2,
|
|
11
|
+
outputLabels: ['next', 'end'],
|
|
12
|
+
// outputLabels: function (index) {
|
|
13
|
+
// if (index == 0) {
|
|
14
|
+
// return 'next iteration';
|
|
15
|
+
// }
|
|
16
|
+
// return 'last iteration';
|
|
17
|
+
// },
|
|
11
18
|
icon: 'font-awesome/fa-arrows-h',
|
|
12
|
-
label: function() {
|
|
13
|
-
return this.name||
|
|
19
|
+
label: function () {
|
|
20
|
+
return this.name || 'Next link';
|
|
14
21
|
},
|
|
15
|
-
oneditprepare: function() {
|
|
16
|
-
$(
|
|
17
|
-
type:
|
|
18
|
-
types:[
|
|
19
|
-
typeField:
|
|
20
|
-
value: 'nextLink'
|
|
22
|
+
oneditprepare: function () {
|
|
23
|
+
$('#node-input-nextLink').typedInput({
|
|
24
|
+
type: 'msg',
|
|
25
|
+
types: ['msg'],
|
|
26
|
+
typeField: '#node-input-nextLink-type',
|
|
27
|
+
value: 'nextLink',
|
|
21
28
|
});
|
|
22
|
-
}
|
|
29
|
+
},
|
|
23
30
|
});
|
|
24
31
|
</script>
|
|
25
32
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
33
|
<script type="text/html" data-template-name="nextLink">
|
|
30
34
|
<div class="form-row">
|
|
31
35
|
<label for="node-input-name"><i class="fa fa-tag"></i> Name</label>
|
|
32
|
-
<input type="text" id="node-input-name" placeholder="Name"
|
|
36
|
+
<input type="text" id="node-input-name" placeholder="Name" />
|
|
33
37
|
</div>
|
|
34
38
|
|
|
35
39
|
<div class="form-row">
|
|
36
40
|
<label for="node-input-type"><i class="fa fa-gears"></i> NextLink</label>
|
|
37
|
-
<input type="text" id="node-input-nextLink"
|
|
38
|
-
<input type="hidden" id="node-input-nextLink-type"
|
|
41
|
+
<input type="text" id="node-input-nextLink" />
|
|
42
|
+
<input type="hidden" id="node-input-nextLink-type" />
|
|
39
43
|
</div>
|
|
40
44
|
</script>
|
|
41
|
-
|
|
45
|
+
|
|
42
46
|
<!-- Documentation -->
|
|
43
47
|
<script type="text/html" data-help-name="nextLink">
|
|
44
48
|
<p>Next link</p>
|
|
45
|
-
|
|
49
|
+
|
|
46
50
|
<h3>Inputs</h3>
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
</
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
<
|
|
56
|
-
</
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
51
|
+
<dl class="message-properties">
|
|
52
|
+
<dt>
|
|
53
|
+
Name
|
|
54
|
+
<span class="property-type">string</span>
|
|
55
|
+
</dt>
|
|
56
|
+
<dd>the node's name</dd>
|
|
57
|
+
<dt>
|
|
58
|
+
NextLink
|
|
59
|
+
<span class="property-type">string</span>
|
|
60
|
+
</dt>
|
|
61
|
+
<dd>the url link to next Service Layer page</dd>
|
|
62
|
+
</dl>
|
|
63
|
+
|
|
64
|
+
<h3>Outputs</h3>
|
|
65
|
+
<ol class="node-ports">
|
|
66
|
+
<li>
|
|
67
|
+
Standard output
|
|
68
|
+
<dl class="message-properties">
|
|
69
|
+
<dt>payload <span class="property-type">msg</span></dt>
|
|
70
|
+
<dd>It returns the message with next link to the next page.</dd>
|
|
71
|
+
</dl>
|
|
72
|
+
</li>
|
|
73
|
+
<li>
|
|
74
|
+
Standard output
|
|
75
|
+
<dl class="message-properties">
|
|
76
|
+
<dt>payload <span class="property-type">msg</span></dt>
|
|
77
|
+
<dd>It returns the message when the last page is reached.</dd>
|
|
78
|
+
</dl>
|
|
79
|
+
</li>
|
|
80
|
+
</ol>
|
|
81
|
+
|
|
74
82
|
<h3>Details</h3>
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
</p>
|
|
78
|
-
<!-- <p><code>msg.payload</code> is used as the payload of the published message.
|
|
83
|
+
<p>this node is used to get the next page of result of items from service layer. See the examples to understand how to use it.</p>
|
|
84
|
+
<!-- <p><code>msg.payload</code> is used as the payload of the published message.
|
|
79
85
|
If it contains an Object it will be converted to a JSON string before being sent.
|
|
80
86
|
If it contains a binary Buffer the message will be published as-is.</p>
|
|
81
87
|
<p>The topic used can be configured in the node or, if left blank, can be set
|
|
82
88
|
by <code>msg.topic</code>.</p>
|
|
83
89
|
<p>Likewise the QoS and retain values can be configured in the node or, if left
|
|
84
90
|
blank, set by <code>msg.qos</code> and <code>msg.retain</code> respectively.</p> -->
|
|
85
|
-
|
|
91
|
+
|
|
86
92
|
<h3>References</h3>
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
</
|
|
91
|
-
|
|
93
|
+
<ul>
|
|
94
|
+
<li><a href="https://sap-samples.github.io/smb-summit-hackathon/b1sl.html" target="_black">Service layer API docs</a> - for more details</li>
|
|
95
|
+
<li>
|
|
96
|
+
<a href="https://github.com/yousolution-cloud/node-red-contrib-you-sap-service-layer">@yousolution-cloud/node-red-contrib-you-sap-service-layer</a> - the
|
|
97
|
+
nodes github repository
|
|
98
|
+
</li>
|
|
99
|
+
</ul>
|
|
100
|
+
</script>
|
package/nodes/patchSap.html
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
color: '#FFC300',
|
|
5
5
|
defaults: {
|
|
6
6
|
name: {value: ''},
|
|
7
|
+
method: {value: 'PATCH'},
|
|
7
8
|
entity: {value: ''},
|
|
8
9
|
udo: {value: ''},
|
|
9
10
|
udt: {value: ''},
|
|
@@ -84,6 +85,14 @@
|
|
|
84
85
|
<input type="text" id="node-input-name" placeholder="Name">
|
|
85
86
|
</div>
|
|
86
87
|
|
|
88
|
+
<div class="form-row">
|
|
89
|
+
<label for="node-input-type"><i class="fa fa-cog"></i> Method</label>
|
|
90
|
+
<select name="node-input-method" id="node-input-method">
|
|
91
|
+
<option value="PATCH">PATCH</option>
|
|
92
|
+
<option value="PUT">PUT</option>
|
|
93
|
+
</select>
|
|
94
|
+
</div>
|
|
95
|
+
|
|
87
96
|
<div class="form-row">
|
|
88
97
|
<label for="node-input-type"><i class="fa fa-cube"></i> Entity</label>
|
|
89
98
|
<select name="node-input-entity" id="node-input-entity">
|
package/nodes/support.js
CHANGED
|
@@ -62,15 +62,15 @@ const thickIdApi = [
|
|
|
62
62
|
];
|
|
63
63
|
|
|
64
64
|
async function login(node, idAuth) {
|
|
65
|
-
const
|
|
65
|
+
const globalContext = node.context().global;
|
|
66
66
|
|
|
67
|
-
const host =
|
|
68
|
-
const port =
|
|
69
|
-
const version =
|
|
67
|
+
const host = globalContext.get(`_YOU_SapServiceLayer_${idAuth}.host`);
|
|
68
|
+
const port = globalContext.get(`_YOU_SapServiceLayer_${idAuth}.port`);
|
|
69
|
+
const version = globalContext.get(`_YOU_SapServiceLayer_${idAuth}.version`);
|
|
70
70
|
|
|
71
71
|
const url = `https://${host}:${port}/b1s/${version}/Login`;
|
|
72
72
|
|
|
73
|
-
const credentials =
|
|
73
|
+
const credentials = globalContext.get(`_YOU_SapServiceLayer_${idAuth}.credentials`);
|
|
74
74
|
const dataString = JSON.stringify(credentials);
|
|
75
75
|
|
|
76
76
|
const options = {
|
|
@@ -107,14 +107,14 @@ async function sendRequest({ node, msg, config, axios, login, options }) {
|
|
|
107
107
|
} catch (error) {
|
|
108
108
|
// Refresh headers re-login
|
|
109
109
|
if (error.response && (error.response.status == 401 || error.response.status == 301)) {
|
|
110
|
-
const
|
|
110
|
+
const globalCotext = node.context().global;
|
|
111
111
|
// try {
|
|
112
112
|
// update cookies for session timeout
|
|
113
113
|
const result = await login(node, requestOptions.idAuthNode);
|
|
114
|
-
|
|
114
|
+
globalCotext.set(`_YOU_SapServiceLayer_${requestOptions.idAuthNode}.headers`, result.headers['set-cookie']);
|
|
115
115
|
|
|
116
116
|
try {
|
|
117
|
-
const headers =
|
|
117
|
+
const headers = globalCotext.get(`_YOU_SapServiceLayer_${requestOptions.idAuthNode}.headers`).join(';');
|
|
118
118
|
|
|
119
119
|
requestOptions.axiosOptions.headers.Cookie = headers;
|
|
120
120
|
|
|
@@ -319,17 +319,17 @@ function generateRequest(node, msg, config, options) {
|
|
|
319
319
|
|
|
320
320
|
function getSapParams(node, msg) {
|
|
321
321
|
try {
|
|
322
|
-
const
|
|
322
|
+
const globalContext = node.context().global;
|
|
323
323
|
|
|
324
324
|
const idAuthNode = msg._YOU_SapServiceLayer.idAuth;
|
|
325
|
-
const host =
|
|
326
|
-
const port =
|
|
327
|
-
const version =
|
|
325
|
+
const host = globalContext.get(`_YOU_SapServiceLayer_${idAuthNode}.host`);
|
|
326
|
+
const port = globalContext.get(`_YOU_SapServiceLayer_${idAuthNode}.port`);
|
|
327
|
+
const version = globalContext.get(`_YOU_SapServiceLayer_${idAuthNode}.version`);
|
|
328
328
|
|
|
329
329
|
// if (!flowContext.get(`_YOU_SapServiceLayer_${idAuthNode}.headers`)) {
|
|
330
330
|
// throw new Error('Authentication failed');
|
|
331
331
|
// }
|
|
332
|
-
const cookies =
|
|
332
|
+
const cookies = globalContext.get(`_YOU_SapServiceLayer_${idAuthNode}.headers`).join(';');
|
|
333
333
|
|
|
334
334
|
return { idAuthNode: idAuthNode, host: host, port: port, version: version, cookies: cookies };
|
|
335
335
|
} catch (error) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yousolution/node-red-contrib-you-sap-service-layer",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "Unofficial module SAP Service Layer for NODE-RED",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"scripts": {
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
],
|
|
20
20
|
"author": "Andrea Trentin <andrea.trentin@yousolution.cloud>",
|
|
21
21
|
"node-red": {
|
|
22
|
+
"version": ">=2.0.0",
|
|
22
23
|
"nodes": {
|
|
23
24
|
"authenticateSap": "/nodes/authenticateSap.js",
|
|
24
25
|
"listSap": "/nodes/listSap.js",
|
package/test/support.spec.js
CHANGED
|
@@ -19,7 +19,7 @@ describe('support library', () => {
|
|
|
19
19
|
const node = {
|
|
20
20
|
context: () => {
|
|
21
21
|
return {
|
|
22
|
-
|
|
22
|
+
global: {
|
|
23
23
|
get: (param) => {
|
|
24
24
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
25
25
|
return 'host';
|
|
@@ -96,7 +96,7 @@ describe('support library', () => {
|
|
|
96
96
|
const node = {
|
|
97
97
|
context: () => {
|
|
98
98
|
return {
|
|
99
|
-
|
|
99
|
+
global: {
|
|
100
100
|
get: (param) => {
|
|
101
101
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
102
102
|
return 'host';
|
|
@@ -163,7 +163,7 @@ describe('support library', () => {
|
|
|
163
163
|
const node = {
|
|
164
164
|
context: () => {
|
|
165
165
|
return {
|
|
166
|
-
|
|
166
|
+
global: {
|
|
167
167
|
get: (param) => {
|
|
168
168
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
169
169
|
return 'host';
|
|
@@ -211,7 +211,7 @@ describe('support library', () => {
|
|
|
211
211
|
const node = {
|
|
212
212
|
context: () => {
|
|
213
213
|
return {
|
|
214
|
-
|
|
214
|
+
global: {
|
|
215
215
|
get: (param) => {
|
|
216
216
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
217
217
|
return 'host';
|
|
@@ -262,7 +262,7 @@ describe('support library', () => {
|
|
|
262
262
|
const node = {
|
|
263
263
|
context: () => {
|
|
264
264
|
return {
|
|
265
|
-
|
|
265
|
+
global: {
|
|
266
266
|
get: (param) => {
|
|
267
267
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
268
268
|
return 'host';
|
|
@@ -312,7 +312,7 @@ describe('support library', () => {
|
|
|
312
312
|
const node = {
|
|
313
313
|
context: () => {
|
|
314
314
|
return {
|
|
315
|
-
|
|
315
|
+
global: {
|
|
316
316
|
get: (param) => {
|
|
317
317
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
318
318
|
return 'host';
|
|
@@ -364,7 +364,7 @@ describe('support library', () => {
|
|
|
364
364
|
const node = {
|
|
365
365
|
context: () => {
|
|
366
366
|
return {
|
|
367
|
-
|
|
367
|
+
global: {
|
|
368
368
|
get: (param) => {
|
|
369
369
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
370
370
|
return 'host';
|
|
@@ -405,7 +405,7 @@ describe('support library', () => {
|
|
|
405
405
|
const node = {
|
|
406
406
|
context: () => {
|
|
407
407
|
return {
|
|
408
|
-
|
|
408
|
+
global: {
|
|
409
409
|
get: (param) => {
|
|
410
410
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
411
411
|
return 'host';
|
|
@@ -457,7 +457,7 @@ describe('support library', () => {
|
|
|
457
457
|
const node = {
|
|
458
458
|
context: () => {
|
|
459
459
|
return {
|
|
460
|
-
|
|
460
|
+
global: {
|
|
461
461
|
get: (param) => {
|
|
462
462
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
463
463
|
return 'host';
|
|
@@ -498,7 +498,7 @@ describe('support library', () => {
|
|
|
498
498
|
const node = {
|
|
499
499
|
context: () => {
|
|
500
500
|
return {
|
|
501
|
-
|
|
501
|
+
global: {
|
|
502
502
|
get: (param) => {
|
|
503
503
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
504
504
|
return 'host';
|
|
@@ -559,7 +559,7 @@ describe('support library', () => {
|
|
|
559
559
|
const node = {
|
|
560
560
|
context: () => {
|
|
561
561
|
return {
|
|
562
|
-
|
|
562
|
+
global: {
|
|
563
563
|
get: (param) => {
|
|
564
564
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
565
565
|
return 'host';
|
|
@@ -609,7 +609,7 @@ describe('support library', () => {
|
|
|
609
609
|
const node = {
|
|
610
610
|
context: () => {
|
|
611
611
|
return {
|
|
612
|
-
|
|
612
|
+
global: {
|
|
613
613
|
get: (param) => {
|
|
614
614
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
615
615
|
return 'host';
|
|
@@ -661,7 +661,7 @@ describe('support library', () => {
|
|
|
661
661
|
const node = {
|
|
662
662
|
context: () => {
|
|
663
663
|
return {
|
|
664
|
-
|
|
664
|
+
global: {
|
|
665
665
|
get: (param) => {
|
|
666
666
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
667
667
|
return 'host';
|
|
@@ -713,7 +713,7 @@ describe('support library', () => {
|
|
|
713
713
|
const node = {
|
|
714
714
|
context: () => {
|
|
715
715
|
return {
|
|
716
|
-
|
|
716
|
+
global: {
|
|
717
717
|
get: (param) => {
|
|
718
718
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
719
719
|
return 'host';
|
|
@@ -755,7 +755,7 @@ describe('support library', () => {
|
|
|
755
755
|
const node = {
|
|
756
756
|
context: () => {
|
|
757
757
|
return {
|
|
758
|
-
|
|
758
|
+
global: {
|
|
759
759
|
get: (param) => {
|
|
760
760
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
761
761
|
return 'host';
|
|
@@ -797,7 +797,7 @@ describe('support library', () => {
|
|
|
797
797
|
const node = {
|
|
798
798
|
context: () => {
|
|
799
799
|
return {
|
|
800
|
-
|
|
800
|
+
global: {
|
|
801
801
|
get: (param) => {
|
|
802
802
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
803
803
|
return 'host';
|
|
@@ -839,7 +839,7 @@ describe('support library', () => {
|
|
|
839
839
|
const node = {
|
|
840
840
|
context: () => {
|
|
841
841
|
return {
|
|
842
|
-
|
|
842
|
+
global: {
|
|
843
843
|
get: (param) => {
|
|
844
844
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
845
845
|
return 'host';
|
|
@@ -891,7 +891,7 @@ describe('support library', () => {
|
|
|
891
891
|
const node = {
|
|
892
892
|
context: () => {
|
|
893
893
|
return {
|
|
894
|
-
|
|
894
|
+
global: {
|
|
895
895
|
get: (param) => {
|
|
896
896
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
897
897
|
return 'host';
|
|
@@ -942,7 +942,7 @@ describe('support library', () => {
|
|
|
942
942
|
const node = {
|
|
943
943
|
context: () => {
|
|
944
944
|
return {
|
|
945
|
-
|
|
945
|
+
global: {
|
|
946
946
|
get: (param) => {
|
|
947
947
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
948
948
|
return 'host';
|
|
@@ -993,7 +993,7 @@ describe('support library', () => {
|
|
|
993
993
|
const node = {
|
|
994
994
|
context: () => {
|
|
995
995
|
return {
|
|
996
|
-
|
|
996
|
+
global: {
|
|
997
997
|
get: (param) => {
|
|
998
998
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
999
999
|
return 'host';
|
|
@@ -1044,7 +1044,7 @@ describe('support library', () => {
|
|
|
1044
1044
|
const node = {
|
|
1045
1045
|
context: () => {
|
|
1046
1046
|
return {
|
|
1047
|
-
|
|
1047
|
+
global: {
|
|
1048
1048
|
get: (param) => {
|
|
1049
1049
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
1050
1050
|
return 'host';
|
|
@@ -1081,7 +1081,7 @@ describe('support library', () => {
|
|
|
1081
1081
|
const node = {
|
|
1082
1082
|
context: () => {
|
|
1083
1083
|
return {
|
|
1084
|
-
|
|
1084
|
+
global: {
|
|
1085
1085
|
get: (param) => {},
|
|
1086
1086
|
},
|
|
1087
1087
|
};
|
|
@@ -1103,7 +1103,7 @@ describe('support library', () => {
|
|
|
1103
1103
|
const node = {
|
|
1104
1104
|
context: () => {
|
|
1105
1105
|
return {
|
|
1106
|
-
|
|
1106
|
+
global: {
|
|
1107
1107
|
get: (param) => {
|
|
1108
1108
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
1109
1109
|
return 'host';
|
|
@@ -1147,7 +1147,7 @@ describe('support library', () => {
|
|
|
1147
1147
|
const node = {
|
|
1148
1148
|
context: () => {
|
|
1149
1149
|
return {
|
|
1150
|
-
|
|
1150
|
+
global: {
|
|
1151
1151
|
get: (param) => {
|
|
1152
1152
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
1153
1153
|
return 'host';
|
|
@@ -1189,7 +1189,7 @@ describe('support library', () => {
|
|
|
1189
1189
|
const node = {
|
|
1190
1190
|
context: () => {
|
|
1191
1191
|
return {
|
|
1192
|
-
|
|
1192
|
+
global: {
|
|
1193
1193
|
get: (param) => {
|
|
1194
1194
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
1195
1195
|
return 'host';
|
|
@@ -1247,7 +1247,7 @@ describe('support library', () => {
|
|
|
1247
1247
|
const node = {
|
|
1248
1248
|
context: () => {
|
|
1249
1249
|
return {
|
|
1250
|
-
|
|
1250
|
+
global: {
|
|
1251
1251
|
get: (param) => {
|
|
1252
1252
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
1253
1253
|
return 'host';
|
|
@@ -1296,7 +1296,7 @@ describe('support library', () => {
|
|
|
1296
1296
|
send: () => {},
|
|
1297
1297
|
context: () => {
|
|
1298
1298
|
return {
|
|
1299
|
-
|
|
1299
|
+
global: {
|
|
1300
1300
|
get: (param) => {
|
|
1301
1301
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
1302
1302
|
return 'host';
|
|
@@ -1354,7 +1354,7 @@ describe('support library', () => {
|
|
|
1354
1354
|
send: () => {},
|
|
1355
1355
|
context: () => {
|
|
1356
1356
|
return {
|
|
1357
|
-
|
|
1357
|
+
global: {
|
|
1358
1358
|
get: (param) => {
|
|
1359
1359
|
if (param == '_YOU_SapServiceLayer_1.host') {
|
|
1360
1360
|
return 'host';
|
package/data/package.json
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "node-red-project",
|
|
3
|
-
"description": "A Node-RED Project",
|
|
4
|
-
"version": "0.0.1",
|
|
5
|
-
"private": true,
|
|
6
|
-
"dependencies": {
|
|
7
|
-
"@types/node-red": "^1.1.1",
|
|
8
|
-
"@yousolution/node-red-contrib-you-sap-service-layer": "file:yousolution-node-red-contrib-you-sap-service-layer-0.1.0.tgz",
|
|
9
|
-
"@yousolution/node-red-contrib-you-yousolution.cloud": "0.0.1",
|
|
10
|
-
"faker": "^6.6.6",
|
|
11
|
-
"node-red-contrib-sse-client": "~0.2.2",
|
|
12
|
-
"node-red-node-email": "~1.14.0"
|
|
13
|
-
}
|
|
14
|
-
}
|