Skip to content

Commit

Permalink
Merge pull request #363 from catenax-ng/feature/TRACEFOSS-1535-update…
Browse files Browse the repository at this point in the history
…-aspect-models

feature: TRACEFOSS-1535 test data for updated aspect models
  • Loading branch information
ds-mwesener authored Jul 10, 2023
2 parents ad37a91 + 110b9c6 commit 07ec474
Show file tree
Hide file tree
Showing 34 changed files with 10,324 additions and 9,445 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
## [Unreleased]

### Added

- Added back button in notification detailed view
- Added alert detail view
- EDC SPI Dependency for using provided models
Expand All @@ -20,6 +21,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- Changed request parameter for registerjob request to irs to match requirements of irs
- Migration of edc 0.4.1 endpoints and api flow
- fixed bug where language switcher did not update to the selected language
- Changed SerialPartTypization aspect model to SerialPart
- Changed AssemblyPartRelationship aspect model to SingleLevelBomAsBuilt

### Removed

Expand Down
2 changes: 1 addition & 1 deletion charts/traceability-foss/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ dependencies:
condition: pgadmin4.enabled
- name: irs-helm
repository: https://eclipse-tractusx.github.io/item-relationship-service
version: 6.0.1
version: 6.1.0
condition: irs-helm.enabled
- condition: tractusx-connector.enabled
name: tractusx-connector
Expand Down
20 changes: 10 additions & 10 deletions dev/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,25 +30,25 @@ In order to upload data to EDC Provider, please use [IRS project script](https:/
Sample invocation (DEV)

```
python transform-and-upload.py -f CX_Testdata_MessagingTest_v0.0.3.json -s https://tracex-submodel-server.dev.demo.catena-x.net -edc https://trace-x-edc.dev.demo.catena-x.net -a https://trace-x-registry.dev.demo.catena-x.net/semantics/registry -p id-3.0-trace -k <apiKey>
python transform-and-upload.py -f CX_Testdata_MessagingTest_v0.0.4.json -s https://tracex-submodel-server.dev.demo.catena-x.net -edc https://trace-x-edc.dev.demo.catena-x.net -a https://trace-x-registry.dev.demo.catena-x.net/semantics/registry -p id-3.0-trace -k <apiKey>
```

Sample invocation (TEST)

```
python transform-and-upload.py -f CX_Testdata_MessagingTest_v0.0.3.json -s https://tracex-submodel-server-test.dev.demo.catena-x.net -edc https://trace-x-test-edc.dev.demo.catena-x.net -a https://trace-x-registry-test.dev.demo.catena-x.net/semantics/registry -p id-3.0-trace -k <apiKey>
python transform-and-upload.py -f CX_Testdata_MessagingTest_v0.0.4.json -s https://tracex-submodel-server-test.dev.demo.catena-x.net -edc https://trace-x-test-edc.dev.demo.catena-x.net -a https://trace-x-registry-test.dev.demo.catena-x.net/semantics/registry -p id-3.0-trace -k <apiKey>
```

Sample invocation (E2E A)

```
python transform-and-upload.py -f CX_Testdata_MessagingTest_v0.0.3.json -s https://tracex-submodel-server-e2e-a.dev.demo.catena-x.net -edc https://trace-x-edc-e2e-a.dev.demo.catena-x.net -a https://trace-x-registry-e2e-a.dev.demo.catena-x.net/semantics/registry -p id-3.0-trace -k <apiKey>
python transform-and-upload.py -f CX_Testdata_MessagingTest_v0.0.4.json -s https://tracex-submodel-server-e2e-a.dev.demo.catena-x.net -edc https://trace-x-edc-e2e-a.dev.demo.catena-x.net -a https://trace-x-registry-e2e-a.dev.demo.catena-x.net/semantics/registry -p id-3.0-trace -k <apiKey>
```

Sample invocation (E2E B)

```
python transform-and-upload.py -f CX_Testdata_MessagingTest_v0.0.3.json -s https://tracex-submodel-server-e2e-b.dev.demo.catena-x.net -edc https://trace-x-edc-e2e-b.dev.demo.catena-x.net -a https://trace-x-registry-e2e-b.dev.demo.catena-x.net/semantics/registry -p id-3.0-trace -k <apiKey>
python transform-and-upload.py -f CX_Testdata_MessagingTest_v0.0.4.json -s https://tracex-submodel-server-e2e-b.dev.demo.catena-x.net -edc https://trace-x-edc-e2e-b.dev.demo.catena-x.net -a https://trace-x-registry-e2e-b.dev.demo.catena-x.net/semantics/registry -p id-3.0-trace -k <apiKey>
```

where:
Expand Down Expand Up @@ -162,7 +162,7 @@ Consists of a List of the following structured entries:
"childCatenaXId" : "urn:uuid:7eeeac86-7b69-444d-81e6-655d0f1513bd"
} ]
} ],
"urn:bamm:io.catenax.serial_part_typization:1.1.0#SerialPartTypization" : [ {
"urn:bamm:io.catenax.serial_part:1.0.0#SerialPart" : [ {
"localIdentifiers" : [ {
"value" : "BPNL00000003CML1",
"key" : "manufacturerId"
Expand Down Expand Up @@ -212,10 +212,10 @@ Is achieved by defining the order of the BPNLs of the desired manufacturers. See
]
```
...AZQP -> ...3ML1 -> ...CNKC
and adding an AssemlyPartRelationship Aspect with the corresponding childCatenaXId:
and adding an SingleLevelBomAsBuilt Aspect with the corresponding childCatenaXId:
```json
{
"urn:bamm:io.catenax.assembly_part_relationship:1.1.0#AssemblyPartRelationship" : [ {
"urn:bamm:io.catenax.single_level_bom_as_built:1.0.0#SingleLevelBomAsBuilt" : [ {
"catenaXId" : "urn:uuid:7eeeac86-7b69-444d-81e6-655d0f1513bd",
"childParts" : [ {
"quantity" : {
Expand Down Expand Up @@ -243,12 +243,12 @@ Is achieved through adding the SingleLevelusageBuilt - Codeblock and the corresp
[{
"catenaXId" : "urn:uuid:f11ddc62-3bd5-468f-b7b0-110fe13ed0cd",
"bpnl" : "BPNL00000003CNKC",
"urn:bamm:io.catenax.assembly_part_relationship:1.1.1#AssemblyPartRelationship": "[...]",
"urn:bamm:io.catenax.serial_part_typization:1.1.0#SerialPartTypization" : "[...]"
"urn:bamm:io.catenax.single_level_bom_as_built:1.0.0#SingleLevelBomAsBuilt": "[...]",
"urn:bamm:io.catenax.serial_part:1.0.0#SerialPart" : "[...]"
}, {
"catenaXId" : "urn:uuid:4e390dab-707f-446e-bfbe-653f6f5b1f37",
"bpnl" : "BPNL00000003AZQP",
"urn:bamm:io.catenax.serial_part_typization:1.1.0#SerialPartTypization" : "",
"urn:bamm:io.catenax.serial_part:1.0.0#SerialPart" : "",
"urn:bamm:io.catenax.single_level_usage_as_built:1.0.1#SingleLevelUsageAsBuilt": [
{
"parentParts": [
Expand Down
2 changes: 1 addition & 1 deletion docs/src/docs/arc42/introduction-goals/requirements.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
== Essential features
* List and view manufactured parts based on BoM AsBuild
* Show detailed information on manufactured parts from AAS description assets and Aspects
* Uses Submodels SerialPartTypization, AssemblyPartRelationship and Batch
* Uses Submodels SerialPart, AssemblyPartRelationship and Batch
* List and view Supplier parts (AssemblyPartRelationship) based on BoM AsBuild lifecycle
* View parts and parts relations in a visualized parts tree
* Send and receive top-down notifications (quality investigations) along the supply chain
Expand Down
4 changes: 2 additions & 2 deletions docs/src/docs/user/user-manual.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Supported languages:

== Parts
List view of the own manufactured parts and batches.
Gives detailed information on the assets registered in the Digital Twin Registry of Catena-X for the company. This includes data based on the aspect models of Use Case Traceability: SerialPartTypization, AssemblyPartRelationship, Batch.
Gives detailed information on the assets registered in the Digital Twin Registry of Catena-X for the company. This includes data based on the aspect models of Use Case Traceability: SerialPart, AssemblyPartRelationship, Batch.

image::https://raw.githubusercontent.com/eclipse-tractusx/traceability-foss/main/docs/src/images/arc42/user-guide/parts-list-detailed-view.PNG[]

Expand Down Expand Up @@ -72,7 +72,7 @@ Once the quality investigation is created you will get a pop-up and can directly

== Other parts
List view of the supplied with parts and batches (Supplier parts).
Gives detailed information on the assets registered in the Digital Twin Registry of Catena-X for the supplier companies. This includes data that is ingested based on the aspect model AssemblyPartRelationship of the child parts for Use Case Traceability aspect models: SerialPartTypization, Batch.
Gives detailed information on the assets registered in the Digital Twin Registry of Catena-X for the supplier companies. This includes data that is ingested based on the aspect model AssemblyPartRelationship of the child parts for Use Case Traceability aspect models: SerialPart, Batch.

image::https://raw.githubusercontent.com/eclipse-tractusx/traceability-foss/main/docs/src/images/arc42/user-guide/supplier-parts-list-detailed-view.PNG[]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,12 @@ entity AsBuiltAsset {
}

note right
SerialPartTypization and Batch
SerialPart and Batch
end note

enum SemanticDataModel {
BATCH,
SERIALPARTTYPIZATION
SERIALPART
}

entity AsPlannedAsset {
Expand Down
24 changes: 12 additions & 12 deletions frontend/src/app/mocks/services/otherParts-mock/otherParts.model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export const otherPartsAssets = [
underInvestigation: true,
qualityType: 'Ok',
van: 'myvan2',
semanticDataModel: 'SERIALPARTTYPIZATION'
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:fccbc75e-6ccd-46e2-ba93-4a3125dfb5a5',
Expand All @@ -90,7 +90,7 @@ export const otherPartsAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: 'myvan3',
semanticDataModel: 'SERIALPARTTYPIZATION'
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:dad03189-4ce7-47a4-bfc5-e7b77dc6cf68',
Expand Down Expand Up @@ -148,7 +148,7 @@ export const otherPartsAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: 'myvan5',
semanticDataModel: 'SERIALPARTTYPIZATION'
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:d411568e-d950-44ff-87c2-492ac6beabe9',
Expand All @@ -171,7 +171,7 @@ export const otherPartsAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: 'myvanX',
semanticDataModel: 'SERIALPARTTYPIZATION'
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:c8504172-21a7-4b02-9cc7-cfaa0fc29bd8',
Expand Down Expand Up @@ -252,7 +252,7 @@ export const otherPartsAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: 'myvanX',
semanticDataModel: 'SERIALPARTTYPIZATION'
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:6599279a-3fe4-479f-bc11-fcd97bb42607',
Expand Down Expand Up @@ -287,7 +287,7 @@ export const otherPartsAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: 'myvanX',
semanticDataModel: 'SERIALPARTTYPIZATION'
semanticDataModel: 'SERIALPART',
},
/* Commented out for now because of amount of effort to change to new structure
{
Expand All @@ -306,7 +306,7 @@ export const otherPartsAssets = [
specificAssetIds: {},
childDescriptions: [],
qualityType: 'Ok',
semanticDataModel: 'SERIALPARTTYPIZATION',
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:b8f04288-6685-47cd-b38d-67c88ba1b02d',
Expand Down Expand Up @@ -336,7 +336,7 @@ export const otherPartsAssets = [
{ id: 'urn:uuid:24468d86-6718-479a-adc6-f9b65f6ada56', idShort: '--' },
],
qualityType: 'Ok',
semanticDataModel: 'SERIALPARTTYPIZATION',
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:09c704a5-c1a7-4b73-9038-e4af72e44dd6',
Expand Down Expand Up @@ -372,7 +372,7 @@ export const otherPartsAssets = [
specificAssetIds: {},
childDescriptions: [],
qualityType: 'Ok',
semanticDataModel: 'SERIALPARTTYPIZATION',
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:8869d78f-b127-406c-b261-1060e30560f2',
Expand Down Expand Up @@ -408,7 +408,7 @@ export const otherPartsAssets = [
specificAssetIds: {},
childDescriptions: [],
qualityType: 'Ok',
semanticDataModel: 'SERIALPARTTYPIZATION',
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:0f6b767a-7f8f-4edd-902c-ee563255a5f8',
Expand Down Expand Up @@ -438,7 +438,7 @@ export const otherPartsAssets = [
{ id: 'urn:uuid:440e2c89-6db5-4044-9aa3-c020b276ade9', idShort: '--' },
],
qualityType: 'Ok',
semanticDataModel: 'SERIALPARTTYPIZATION',
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:06ce2095-d52d-4ab9-a31f-fa6a6b07f685',
Expand All @@ -460,7 +460,7 @@ export const otherPartsAssets = [
{ id: 'urn:uuid:5f5bba9c-e24b-4c83-86a0-ec7484f57b7b', idShort: '--' },
],
qualityType: 'Ok',
semanticDataModel: 'SERIALPARTTYPIZATION',
semanticDataModel: 'SERIALPART',
},
{
id: 'urn:uuid:e35abf46-5a66-47b6-b74b-1753287d576d',
Expand Down
14 changes: 7 additions & 7 deletions frontend/src/app/mocks/services/parts-mock/parts.model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ export const mockBmwAssets = [
underInvestigation: false,
qualityType: QualityType.Ok,
van: null,
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
},
{
id: 'urn:uuid:ab863676-a37c-41e7-a5f9-efaa071dbbf5',
Expand Down Expand Up @@ -182,7 +182,7 @@ export const mockBmwAssets = [
van: null,
activeAlert: false,
underInvestigation: false,
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
},

{
Expand Down Expand Up @@ -240,7 +240,7 @@ export const mockBmwAssets = [
activeAlert: false,
underInvestigation: false,
qualityType: QualityType.Ok,
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
},

{
Expand Down Expand Up @@ -300,7 +300,7 @@ export const mockBmwAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: null,
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
},

{
Expand All @@ -327,7 +327,7 @@ export const mockBmwAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: null,
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
},
{
id: 'urn:uuid:9a80e5ee-6c27-47f5-912a-56945e26b9a6',
Expand All @@ -354,7 +354,7 @@ export const mockBmwAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: null,
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
},
{
id: 'urn:uuid:bf5ae91d-02f8-4e33-b130-90ec402ac0db',
Expand All @@ -380,7 +380,7 @@ export const mockBmwAssets = [
underInvestigation: false,
qualityType: 'Ok',
van: null,
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
},
{
id: 'urn:uuid:d261e0fa-36f5-4128-875e-0f5735f5a535',
Expand Down
10 changes: 5 additions & 5 deletions frontend/src/app/mocks/services/parts-mock/parts.test.model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export const MOCK_part_5 = {
underInvestigation: false,
qualityType: QualityType.LifeThreatening,
van: 'myvan5',
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
};

export const MOCK_part_4 = {
Expand All @@ -67,7 +67,7 @@ export const MOCK_part_4 = {
underInvestigation: false,
qualityType: QualityType.Critical,
van: 'myvan4',
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
};

export const MOCK_part_3 = {
Expand All @@ -85,13 +85,13 @@ export const MOCK_part_3 = {
nameAtCustomer: 'A 180 Limousine',
},
owner: Owner.OWN,
childRelations: [{ id: MOCK_part_5.id, idShort: MOCK_part_5.idShort }],
childRelations: [ { id: MOCK_part_5.id, idShort: MOCK_part_5.idShort } ],
parentRelations: [],
activeAlert: false,
underInvestigation: false,
qualityType: QualityType.Major,
van: 'myvan3',
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION,
semanticDataModel: SemanticDataModel.SERIALPART,
};

export const MOCK_part_2 = {
Expand All @@ -115,7 +115,7 @@ export const MOCK_part_2 = {
underInvestigation: false,
qualityType: QualityType.Minor,
van: 'myvan2',
semanticDataModel: SemanticDataModel.SERIALPARTTYPIZATION
semanticDataModel: SemanticDataModel.SERIALPART,
};

export const MOCK_part_1 = {
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/app/modules/page/parts/model/parts.model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ export enum QualityType {
}

export enum SemanticDataModel {
BATCH= 'BATCH',
SERIALPARTTYPIZATION = 'SERIALPARTTYPIZATION',
BATCH = 'BATCH',
SERIALPART = 'SERIALPART',
PARTASPLANNED = 'PARTASPLANNED'
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ describe('Relations facade', () => {
title: 'MOCK_part_4',
},
],
state: 'SERIALPARTTYPIZATION',
state: 'SERIALPART',
text: 'BMW 520d Touring',
title: 'BMW 520d Touring | mysemanticmodelId2',
},
Expand All @@ -156,7 +156,7 @@ describe('Relations facade', () => {
title: 'MOCK_part_5',
},
],
state: 'SERIALPARTTYPIZATION',
state: 'SERIALPART',
text: 'A 180 Limousine',
title: 'A 180 Limousine | mysemanticModelId3',
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ describe('D3 Minimap', () => {
it('should render minimap status colors', async () => {
const component = await renderTree();
component.detectChanges();
expect((await waitFor(() => screen.getAllByTestId('tree--element__circle-SERIALPARTTYPIZATION'))).length).toBe(2);
expect((await waitFor(() => screen.getAllByTestId('tree--element__circle-SERIALPART'))).length).toBe(2);
expect((await waitFor(() => screen.getAllByTestId('tree--element__circle-BATCH'))).length).toBe(1);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class AssetTestData {

List<Asset> readAndConvertAssetsForTests() {
try {
InputStream file = AssetTestData.class.getResourceAsStream("/data/irs_assets_v2.json")
InputStream file = AssetTestData.class.getResourceAsStream("/data/irs_assets_v3.json")
JobDetailResponse response = mapper.readValue(file, JobDetailResponse.class)
def assets = response.convertAssets()
return assets
Expand Down
Loading

0 comments on commit 07ec474

Please sign in to comment.