diff --git a/yace/data/product-list.json b/yace/data/product-list.json index a57741c..f43369c 100644 --- a/yace/data/product-list.json +++ b/yace/data/product-list.json @@ -2,23 +2,23 @@ "products": [ { "id": 1, - "label": "Controller v1.0" + "label": "Product A 1.0" }, { "id": 2, - "label": "Controller v2.0" + "label": "Product A 1.1" }, { "id": 3, - "label": "Controller v3.0" + "label": "Product B 1.0" }, - { - "id": 4, - "label": "Controller v4.0" - }, - { - "id": "994_44", - "label": "Sensor 994 v4.4" - } + { + "id": 4, + "label": "Product C 4.2" + }, + { + "id": 5, + "label": "Product C 4.3" + } ] } \ No newline at end of file diff --git a/yace/data/products/1.json b/yace/data/products/1.json index dcca939..cedf6e9 100644 --- a/yace/data/products/1.json +++ b/yace/data/products/1.json @@ -1,16 +1,22 @@ { "branches": [ { - "category": "product_family", - "name": "controller", + "category": "vendor", + "name": "Example Company", "branches": [ { - "category": "product_version", - "name": "1.0", - "product": { - "name": "controller 1.0", - "product_id": "1" - } + "category": "product_name", + "name": "Product A", + "branches": [ + { + "category": "product_version", + "name": "1.0", + "product": { + "name": "Product A 1.0", + "product_id": "1" + } + } + ] } ] } diff --git a/yace/data/products/2.json b/yace/data/products/2.json index 828f7bf..565788a 100644 --- a/yace/data/products/2.json +++ b/yace/data/products/2.json @@ -1,16 +1,22 @@ { "branches": [ { - "category": "product_family", - "name": "controller", + "category": "vendor", + "name": "Example Company", "branches": [ { - "category": "product_version", - "name": "2.0", - "product": { - "name": "controller 2.0", - "product_id": "2" - } + "category": "product_name", + "name": "Product A", + "branches": [ + { + "category": "product_version", + "name": "1.1", + "product": { + "name": "Product A 1.1", + "product_id": "2" + } + } + ] } ] } diff --git a/yace/data/products/3.json b/yace/data/products/3.json index 252cb6e..dc7af76 100644 --- a/yace/data/products/3.json +++ b/yace/data/products/3.json @@ -1,16 +1,22 @@ { "branches": [ { - "category": "product_family", - "name": "controller", + "category": "vendor", + "name": "Example Company", "branches": [ { - "category": "product_version", - "name": "3.0", - "product": { - "name": "controller 3.0", - "product_id": "3" - } + "category": "product_name", + "name": "Product B", + "branches": [ + { + "category": "product_version", + "name": "1.0", + "product": { + "name": "Product B 1.0", + "product_id": "3" + } + } + ] } ] } diff --git a/yace/data/products/4.json b/yace/data/products/4.json index 252cb6e..bd82fe8 100644 --- a/yace/data/products/4.json +++ b/yace/data/products/4.json @@ -1,16 +1,22 @@ { "branches": [ { - "category": "product_family", - "name": "controller", + "category": "vendor", + "name": "Example Company", "branches": [ { - "category": "product_version", - "name": "3.0", - "product": { - "name": "controller 3.0", - "product_id": "3" - } + "category": "product_name", + "name": "Product C", + "branches": [ + { + "category": "product_version", + "name": "4.2", + "product": { + "name": "Product C 4.2", + "product_id": "4" + } + } + ] } ] } diff --git a/yace/data/products/5.json b/yace/data/products/5.json new file mode 100644 index 0000000..fc08c82 --- /dev/null +++ b/yace/data/products/5.json @@ -0,0 +1,24 @@ +{ + "branches": [ + { + "category": "vendor", + "name": "Example Company", + "branches": [ + { + "category": "product_name", + "name": "Product C", + "branches": [ + { + "category": "product_version", + "name": "4.3", + "product": { + "name": "Product C 4.3", + "product_id": "5" + } + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/yace/data/products/994_44.json b/yace/data/products/994_44.json deleted file mode 100644 index 44a7508..0000000 --- a/yace/data/products/994_44.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "branches": [ - { - "category": "product_family", - "name": "sensor", - "branches": [ - { - "category": "product_version", - "name": "3.0", - "product": { - "name": "sensor 994 v4.4", - "product_id": "994_44" - } - } - ] - } - ] -} \ No newline at end of file diff --git a/yace/index.html b/yace/index.html index 8cd8409..d081757 100644 --- a/yace/index.html +++ b/yace/index.html @@ -10,7 +10,7 @@
- +
@@ -22,7 +22,7 @@

Overview

diff --git a/yace/js/components/notesList.js b/yace/js/components/notesList.js index 7bbd362..81574f4 100644 --- a/yace/js/components/notesList.js +++ b/yace/js/components/notesList.js @@ -1,5 +1,6 @@ import Component from '../lib/component.js'; import store from '../store/index.js'; +import TextArea from './textarea.js'; import TextInput from './textinput.js'; import ComboInput from './comboinput.js'; @@ -24,13 +25,13 @@ export default class NotesList extends Component { // If there are no items to show, render a little status instead if(store.state.csaf?.document?.notes == undefined) { self.element.innerHTML = ` -

Notes

+

Notes

`; } else { // Loop the items and generate a list of elements self.element.innerHTML = ` -

Notes

+

Notes

${store.state.csaf?.document?.notes.map((notesItem, index) => { return `
@@ -52,7 +53,7 @@ export default class NotesList extends Component { store.state.csaf?.document?.notes.forEach((notesItem, index) => { let noteTitle = new TextInput("#input_document\\.notes\\." + index + "\\.title", "Title", "document.notes." + index + ".title", true, ""); noteTitle.render(); - let noteText = new TextInput("#input_document\\.notes\\." + index + "\\.text", "Text", "document.notes." + index + ".text", true, ""); + let noteText = new TextArea("#input_document\\.notes\\." + index + "\\.text", "Text", "document.notes." + index + ".text", true, ""); noteText.render(); let noteCombo = new ComboInput( "#input_document\\.notes\\." + index + "\\.category", diff --git a/yace/js/components/referencesList.js b/yace/js/components/referencesList.js index 0f407f0..64b29cc 100644 --- a/yace/js/components/referencesList.js +++ b/yace/js/components/referencesList.js @@ -24,13 +24,13 @@ export default class ReferencesList extends Component { // If there are no items to show, render a little status instead if(store.state.csaf?.document?.references == undefined) { self.element.innerHTML = ` -

References

+

References

`; } else { // Loop the items and generate a list of elements self.element.innerHTML = ` -

Revision

+

Revision

${store.state.csaf?.document?.references.map((item, index) => { return `
diff --git a/yace/js/components/revisionList.js b/yace/js/components/revisionList.js index 5a39962..ed129a6 100644 --- a/yace/js/components/revisionList.js +++ b/yace/js/components/revisionList.js @@ -24,7 +24,7 @@ export default class RevisionList extends Component { // If there are no items to show, render a little status instead if(store.state.csaf?.document?.tracking?.revision_history == undefined) { self.element.innerHTML = ` -

Revision

+

Revision