diff --git a/importers/xml_examples/Retail/01_Green_to_pink_shipment.xml b/importers/xml_examples/Retail/01_Green_to_pink_shipment.xml
new file mode 100755
index 0000000000..fb58604923
--- /dev/null
+++ b/importers/xml_examples/Retail/01_Green_to_pink_shipment.xml
@@ -0,0 +1,140 @@
+
+
+
+
+ 1.0
+
+ urn:ot:object:actor:id:Company_Green
+
+ Abraham Smith
+ abraham_Smith@green.com
+
+
+
+ urn:ot:object:actor:id:Company_Pink
+
+ Betty Johnson
+ betty@pink.com
+
+
+
+ GS1
+ V1.3
+ 100001
+ Shipment
+ 2018-01-01T00:31:52Z
+
+
+
+ BusinessProcess
+ Shipment/version2-251
+ EDI-Shipment
+
+
+
+
+
+
+
+
+
+ Green
+ Company producer
+ 0xBbAaAd7BD40602B78C0649032D2532dEFa23A4C0
+
+
+ Pink
+ Company
+ 0xFfDDAd7BD40602B78C0649032D2532dEFa23A4C0
+
+
+
+
+
+
+
+ Building
+ Producer Warehouses
+
+ urn:epc:id:sgln:Building_Green_V1
+ urn:epc:id:sgln:Building_Green_V2
+
+
+ urn:ot:object:actor:id:Company_Green
+
+
+
+ Building
+ Pink distributor warehouse
+
+ urn:ot:object:actor:id:Company_Pink
+
+
+
+
+
+
+
+
+ Beverage
+ Wine Pallet
+
+
+
+
+
+
+
+ urn:ot:object:product:id:Product_1
+ 2017-31-12T00:01:54Z
+ 2020-31-12T00:01:54Z
+
+
+
+
+
+
+
+
+
+
+
+ 2018-01-01T01:00:00.000-04:00
+ -04:00
+
+ urn:epc:id:sgtin:Batch_1
+
+ OBSERVE
+ urn:epcglobal:cbv:bizstep:shipping
+ urn:epcglobal:cbv:disp:active
+
+ urn:epc:id:sgln:Building_Green_V2
+
+
+ urn:epc:id:sgln:Building_Green
+
+
+
+
+ urn:epc:id:sgtin:Batch_1
+ 10
+ KG
+
+
+
+ 1
+ urn:ot:event:Transport
+ urn:ot:event:Ownership
+ Sales
+
+
+
+
+ urn:epc:id:sgln:Building_Pink
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/importers/xml_examples/Retail/02_Green_to_Pink_receipt.xml b/importers/xml_examples/Retail/02_Green_to_Pink_receipt.xml
new file mode 100755
index 0000000000..78c1f649ec
--- /dev/null
+++ b/importers/xml_examples/Retail/02_Green_to_Pink_receipt.xml
@@ -0,0 +1,140 @@
+
+
+
+
+ 1.0
+
+ urn:ot:object:actor:id:Company_Pink
+
+ Betty Johnson
+ betty@pink.com
+
+
+
+ urn:ot:object:actor:id:Company_Green
+
+ Abraham Smith
+ abraham_Smith@green.com
+
+
+
+ GS1
+ V1.3
+ 100002
+ Shipment
+ 2018-01-02T11:32:52Z
+
+
+
+ BusinessProcess
+ Receipt/version2-251
+ EDI-Receipt
+
+
+
+
+
+
+
+
+
+ Green
+ Company producer
+ 0xBbAaAd7BD40602B78C0649032D2532dEFa23A4C0
+
+
+ Pink
+ Company
+ 0xFfDDAd7BD40602B78C0649032D2532dEFa23A4C0
+
+
+
+
+
+
+
+ Building
+ Producer Warehouses
+
+ urn:ot:object:actor:id:Company_Green
+
+
+
+ Building
+ Pink distributor warehouse
+
+ urn:epc:id:sgln:Building_Pink_V3
+ urn:epc:id:sgln:Building_Pink_V4
+
+
+ urn:ot:object:actor:id:Company_Pink
+
+
+
+
+
+
+
+
+ Beverage
+ Wine Pallet
+
+
+
+
+
+
+
+ urn:ot:object:product:id:Product_1
+ 2017-31-12T00:01:54Z
+ 2020-31-12T00:01:54Z
+
+
+
+
+
+
+
+
+
+
+
+ 2018-01-02T11:00:00.000-04:00
+ -04:00
+
+ urn:epc:id:sgtin:Batch_1
+
+ OBSERVE
+ urn:epcglobal:cbv:bizstep:receiving
+ urn:epcglobal:cbv:disp:active
+
+ urn:epc:id:sgln:Building_Pink_V3
+
+
+ urn:epc:id:sgln:Building_Pink
+
+
+
+
+ urn:epc:id:sgtin:Batch_1
+ 10
+ KG
+
+
+
+ 1
+ urn:ot:events:Transport
+ urn:ot:events:Ownership
+ Sales
+
+
+
+
+ urn:epc:id:sgln:Building_Pink
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/importers/xml_examples/Retail/03_Pink_to_Orange_shipment.xml b/importers/xml_examples/Retail/03_Pink_to_Orange_shipment.xml
new file mode 100755
index 0000000000..c643c03773
--- /dev/null
+++ b/importers/xml_examples/Retail/03_Pink_to_Orange_shipment.xml
@@ -0,0 +1,139 @@
+
+
+
+
+ 1.0
+
+ urn:ot:object:actor:id:Company_Pink
+
+ Betty Johnson
+ betty@pink.com
+
+
+
+ urn:ot:object:actor:id:Company_Orange
+
+ Carter Novitzki
+ c.novitzki@orange.com
+
+
+
+ GS1
+ V1.3
+ 200002
+ Shipment
+ 2018-02-02T00:31:52Z
+
+
+
+ BusinessProcess
+ Shipment/version2-251
+ EDI-Shipment
+
+
+
+
+
+
+
+
+
+ Green
+ Company Retail
+ 0xCcAB7BD40602B78C0649032D2532dEFa23A4C0
+
+
+ Pink
+ Company
+ 0xFfDDAd7BD40602B78C0649032D2532dEFa23A4C0
+
+
+
+
+
+
+ Building
+ Retail Store Orange
+
+ urn:ot:object:actor:id:Company_Orange
+
+
+
+ Building
+ Pink distributor warehouse
+
+ urn:epc:id:sgln:Building_Pink_V3
+ urn:epc:id:sgln:Building_Pink_V4
+
+
+ urn:ot:object:actor:id:Company_Pink
+
+
+
+
+
+
+
+
+ Beverage
+ Wine Pallet
+
+
+
+
+
+
+
+ urn:ot:object:product:id:Product_1
+ 2017-31-12T00:01:54Z
+ 2020-31-12T00:01:54Z
+
+
+
+
+
+
+
+
+
+
+
+ 2018-02-02T06:00:00.000-04:00
+ -04:00
+
+ urn:epc:id:sgtin:Batch_1_PINKSHIP1
+
+ OBSERVE
+ urn:epcglobal:cbv:bizstep:shipping
+ urn:epcglobal:cbv:disp:active
+
+ urn:epc:id:sgln:Building_Pink_V4
+
+
+ urn:epc:id:sgln:Building_Pink
+
+
+
+
+ urn:epc:id:sgtin:Batch_1_PINKSHIP1
+ 3
+ KG
+
+
+
+ 1
+ urn:ot:events:Transport
+ urn:ot:events:Ownership
+ Sales
+
+
+
+
+ urn:epc:id:sgln:Building_Orange
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/importers/xml_examples/Retail/04_Pink_to_Orange_receipt.xml b/importers/xml_examples/Retail/04_Pink_to_Orange_receipt.xml
new file mode 100755
index 0000000000..73b4c4e66e
--- /dev/null
+++ b/importers/xml_examples/Retail/04_Pink_to_Orange_receipt.xml
@@ -0,0 +1,138 @@
+
+
+
+
+ 1.0
+
+ urn:ot:object:actor:id:Company_Orange
+
+ Carter Novitzki
+ c.novitzki@orange.com
+
+
+
+ urn:ot:object:actor:id:Company_Pink
+
+ Betty Johnson
+ betty@pink.com
+
+
+
+ GS1
+ V1.3
+ 200001
+ Shipment
+ 2018-02-02T00:31:52Z
+
+
+
+ BusinessProcess
+ Shipment/version2-251
+ EDI-Shipment
+
+
+
+
+
+
+
+
+
+ Green
+ Company Retail
+ 0xCcAB7BD40602B78C0649032D2532dEFa23A4C0
+
+
+ Pink
+ Company
+ 0xFfDDAd7BD40602B78C0649032D2532dEFa23A4C0
+
+
+
+
+
+
+ Building
+ Retail Store Orange
+
+ urn:epc:id:sgln:Building_Orange_V5
+
+
+ urn:ot:object:actor:id:Company_Orange
+
+
+
+ Building
+ Pink distributor warehouse
+
+ urn:ot:object:actor:id:Company_Pink
+
+
+
+
+
+
+
+
+ Beverage
+ Wine Pallet
+
+
+
+
+
+
+
+ urn:ot:object:product:id:Product_1
+ 2017-31-12T00:01:54Z
+ 2020-31-12T00:01:54Z
+
+
+
+
+
+
+
+
+
+
+
+ 2018-02-03T07:00:00.000-04:00
+ -02:00
+
+ urn:epc:id:sgtin:Batch_1_PINKSHIP1
+
+ OBSERVE
+ urn:epcglobal:cbv:bizstep:receipt
+ urn:epcglobal:cbv:disp:active
+
+ urn:epc:id:sgln:Building_Orange_V5
+
+
+ urn:epc:id:sgln:Building_Orange
+
+
+
+
+ urn:epc:id:sgtin:Batch_1_PINKSHIP1
+ 3
+ KG
+
+
+
+ ORANGERCPT1
+ urn:ot:events:Transport
+ urn:ot:events:Ownership
+ Sales
+
+
+
+
+ urn:epc:id:sgln:Building_Orange
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/importers/xml_examples/Retail/05_Pink_to_Red_shipment.xml b/importers/xml_examples/Retail/05_Pink_to_Red_shipment.xml
new file mode 100755
index 0000000000..722e6f6470
--- /dev/null
+++ b/importers/xml_examples/Retail/05_Pink_to_Red_shipment.xml
@@ -0,0 +1,139 @@
+
+
+
+
+ 1.0
+
+ urn:ot:object:actor:id:Company_Pink
+
+ Betty Johnson
+ betty@pink.com
+
+
+
+ urn:ot:object:actor:id:Company_Red
+
+ Carter Novitzki
+ c.novitzki@red.com
+
+
+
+ GS1
+ V1.3
+ 200002
+ Shipment
+ 2018-03-03T00:31:52Z
+
+
+
+ BusinessProcess
+ Shipment/version2-251
+ EDI-Shipment
+
+
+
+
+
+
+
+
+
+ Green
+ Company Retail
+ 0xCcAB7BD40602B78C0649032D2532dEFa23A4C0
+
+
+ Pink
+ Company
+ 0xFfDDAd7BD40602B78C0649032D2532dEFa23A4C0
+
+
+
+
+
+
+ Building
+ Retail Store Red
+
+ urn:ot:object:actor:id:Company_Red
+
+
+
+ Building
+ Pink distributor warehouse
+
+ urn:epc:id:sgln:Building_Pink_V3
+ urn:epc:id:sgln:Building_Pink_V4
+
+
+ urn:ot:object:actor:id:Company_Pink
+
+
+
+
+
+
+
+
+ Beverage
+ Wine Pallet
+
+
+
+
+
+
+
+ urn:ot:object:product:id:Product_1
+ 2017-31-12T00:01:54Z
+ 2020-31-12T00:01:54Z
+
+
+
+
+
+
+
+
+
+
+
+ 2018-03-03T06:00:00.000-04:00
+ -04:00
+
+ urn:epc:id:sgtin:Batch_1_PINKSHIP2
+
+ OBSERVE
+ urn:epcglobal:cbv:bizstep:shipping
+ urn:epcglobal:cbv:disp:active
+
+ urn:epc:id:sgln:Building_Pink_V4
+
+
+ urn:epc:id:sgln:Building_Pink
+
+
+
+
+ urn:epc:id:sgtin:Batch_1_PINKSHIP2
+ 6
+ KG
+
+
+
+ 1
+ urn:ot:events:Transport
+ urn:ot:events:Ownership
+ Sales
+
+
+
+
+ urn:epc:id:sgln:Building_Red
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/importers/xml_examples/Retail/06_Pink_to_Red_receipt.xml b/importers/xml_examples/Retail/06_Pink_to_Red_receipt.xml
new file mode 100755
index 0000000000..1dda6fe252
--- /dev/null
+++ b/importers/xml_examples/Retail/06_Pink_to_Red_receipt.xml
@@ -0,0 +1,138 @@
+
+
+
+
+ 1.0
+
+ urn:ot:object:actor:id:Company_Red
+
+ Carter Novitzki
+ c.novitzki@red.com
+
+
+
+ urn:ot:object:actor:id:Company_Pink
+
+ Betty Johnson
+ betty@pink.com
+
+
+
+ GS1
+ V1.3
+ 200002
+ Shipment
+ 2018-03-03T00:31:52Z
+
+
+
+ BusinessProcess
+ Shipment/version2-251
+ EDI-Shipment
+
+
+
+
+
+
+
+
+
+ Green
+ Company Retail
+ 0xCcAB7BD40602B78C0649032D2532dEFa23A4C0
+
+
+ Pink
+ Company
+ 0xFfDDAd7BD40602B78C0649032D2532dEFa23A4C0
+
+
+
+
+
+
+ Building
+ Retail Store Red
+
+ urn:epc:id:sgln:Building_Red_V5
+
+
+ urn:ot:object:actor:id:Company_Red
+
+
+
+ Building
+ Pink distributor warehouse
+
+ urn:ot:object:actor:id:Company_Pink
+
+
+
+
+
+
+
+
+ Beverage
+ Wine Pallet
+
+
+
+
+
+
+
+ urn:ot:object:product:id:Product_1
+ 2017-31-12T00:01:54Z
+ 2020-31-12T00:01:54Z
+
+
+
+
+
+
+
+
+
+
+
+ 2018-04-03T08:00:00.000-04:00
+ -02:00
+
+ urn:epc:id:sgtin:Batch_1_PINKSHIP2
+
+ OBSERVE
+ urn:epcglobal:cbv:bizstep:receipt
+ urn:epcglobal:cbv:disp:active
+
+ urn:epc:id:sgln:Building_Red_V5
+
+
+ urn:epc:id:sgln:Building_Red
+
+
+
+
+ urn:epc:id:sgtin:Batch_1_PINKSHIP2
+ 6
+ KG
+
+
+
+ RedRCPT2
+ urn:ot:events:Transport
+ urn:ot:events:Ownership
+ Sales
+
+
+
+
+ urn:epc:id:sgln:Building_Red
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/importers/xml_examples/Retail_with_aggregation/01_Green_packing.xml b/importers/xml_examples/Retail_with_aggregation/01_Green_packing.xml
index 0de0ead1da..a36d4e51fe 100644
--- a/importers/xml_examples/Retail_with_aggregation/01_Green_packing.xml
+++ b/importers/xml_examples/Retail_with_aggregation/01_Green_packing.xml
@@ -166,7 +166,7 @@
urn:ot:event:Transform
Packing
-
+
diff --git a/modules/GS1Importer.js b/modules/GS1Importer.js
index e33b34dbb9..b4835d8a07 100644
--- a/modules/GS1Importer.js
+++ b/modules/GS1Importer.js
@@ -342,9 +342,6 @@ class GS1Importer {
classId = objectEventTransformationId; // TODO map to class ID
}
- // TODO implement ADD and DELETE if event type is aggregation
- // TODO kill parent pallet
-
const data = {
object_class_id: classId,
categories: eventCategories,
@@ -579,7 +576,7 @@ class GS1Importer {
currentEventEdges.push({
_key: this.helper.createKey('event_batch', senderId, eventKey, parentID),
- _from: `ot_vertices/${eventKey}`,
+ _from: `${eventKey}`,
_to: `${EDGE_KEY_TEMPLATE + parentID}`,
edge_type: 'PALLET',
identifiers: {
@@ -589,7 +586,7 @@ class GS1Importer {
currentEventEdges.push({
_key: this.helper.createKey('event_batch', senderId, parentID, eventKey),
_from: `${EDGE_KEY_TEMPLATE + parentID}`,
- _to: `ot_vertices/${eventKey}`,
+ _to: `${eventKey}`,
edge_type: 'PALLET',
identifiers: {
uid: `event_batch_${parentID}_${eventId}`,
diff --git a/test/modules/utilities.test.js b/test/modules/utilities.test.js
index bf4ebe9ce1..07a7d4c446 100644
--- a/test/modules/utilities.test.js
+++ b/test/modules/utilities.test.js
@@ -20,7 +20,7 @@ describe('Utilities module', () => {
myConfig = await Utilities.loadConfig();
});
- it.only('node_config should contain certain entries', () => {
+ it('node_config should contain certain entries', () => {
assert.hasAllKeys(
myConfig, ['node_wallet', 'node_private_key', 'node_rpc_ip', 'node_port',
'node_kademlia_id', 'selected_graph_database', 'selected_blockchain', 'request_timeout', 'ssl_keypath',