Commit 498f628f authored by Rafael Monnerat's avatar Rafael Monnerat

ors-amarisoft: drop ru_type and ru_link_type

  Use key/object structure instead const, since it provides better struture whenever render the form.

  It is required to still update instance for follow up the change
parent 38410da2
...@@ -5,8 +5,6 @@ ...@@ -5,8 +5,6 @@
"type": "object", "type": "object",
"required": [ "required": [
"ru_type",
"ru_link_type",
"n_antenna_dl", "n_antenna_dl",
"n_antenna_ul", "n_antenna_ul",
"tx_gain", "tx_gain",
...@@ -14,15 +12,6 @@ ...@@ -14,15 +12,6 @@
], ],
"properties": { "properties": {
"ru_type": {
"type": "string",
"options": { "hidden": true }
},
"ru_link_type": {
"type": "string",
"options": { "hidden": true }
},
"n_antenna_dl": { "n_antenna_dl": {
"title": "Number of DL antennas", "title": "Number of DL antennas",
"type": "integer" "type": "integer"
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
"title": "Radio Unit", "title": "Radio Unit",
"type": "object", "type": "object",
"oneOf": [ "anyOf": [
{ "$ref": "sdr/input-schema.json" }, { "$ref": "sdr/input-schema.json" },
{ "$ref": "lopcomm/input-schema.json" }, { "$ref": "lopcomm/input-schema.json" },
{ "$ref": "sunwave/input-schema.json" } { "$ref": "sunwave/input-schema.json" }
......
{ {
"$schema": "https://json-schema.org/draft/2020-12/schema", "$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Lopcomm ORAN", "title": "Lopcomm ORAN",
"type": "object", "type": "object",
"properties": {
"loopcomm": {
"title": "Lopcomm ORAN",
"properties": {
"cpri": {
"title": "CPRI Link Type",
"required": [ "required": [
"ru_type",
"ru_link_type",
"n_antenna_dl", "n_antenna_dl",
"n_antenna_ul", "n_antenna_ul",
"tx_gain", "tx_gain",
"rx_gain", "rx_gain",
"cpri_link", "cpri_link",
"mac_addr" "mac_addr"
], ],
"properties": { "properties": {
"$ref": "../../ru/common.json#/properties", "$ref": "../../ru/common.json#/properties",
"ru_type": {
"$ref": "#/properties/ru_type",
"const": "lopcomm",
"template": "lopcomm"
},
"ru_link_type": {
"$ref": "#/properties/ru_link_type",
"const": "cpri",
"template": "cpri"
},
"n_antenna_dl": { "n_antenna_dl": {
"$ref": "#/properties/n_antenna_dl", "$ref": "#/properties/n_antenna_dl",
"default": 2 "default": 2
...@@ -62,11 +50,17 @@ ...@@ -62,11 +50,17 @@
} }
} }
}, },
"reset_schedule": { "reset_schedule": {
"title": "Cron schedule for RRH reset", "title": "Cron schedule for RRH reset",
"description": "Refer https://crontab.guru/ to make a reset schedule for RRH, for example, '0 1 * * *' means the RRH will reset every day at 1 am", "description": "Refer https://crontab.guru/ to make a reset schedule for RRH, for example, '0 1 * * *' means the RRH will reset every day at 1 am",
"type": "string" "type": "string"
} }
} }
},
"type": "object"
},
"type": "object"
},
"type": "object"
}
} }
...@@ -5,31 +5,26 @@ ...@@ -5,31 +5,26 @@
"description": "Radio Unit constituted of several SDR boards", "description": "Radio Unit constituted of several SDR boards",
"type": "object", "type": "object",
"properties": {
"sdr": {
"title": "SDR transiver",
"properties": {
"sdr": {
"title": "SDR Link Type",
"required": [ "required": [
"ru_type",
"ru_link_type",
"n_antenna_dl", "n_antenna_dl",
"n_antenna_ul", "n_antenna_ul",
"tx_gain", "tx_gain",
"rx_gain", "rx_gain",
"sdr_dev_list" "sdr_dev_list"
], ],
"properties": { "properties": {
"$ref": "../../ru/common.json#/properties", "$ref": "../../ru/common.json#/properties",
"ru_type": {
"$ref": "#/properties/ru_type",
"const": "sdr",
"template": "sdr"
},
"ru_link_type": { "ru_link_type": {
"$ref": "#/properties/ru_link_type", "$ref": "#/properties/ru_link_type",
"const": "sdr", "const": "sdr",
"template": "sdr" "default": "sdr"
}, },
"sdr_dev_list": { "sdr_dev_list": {
"title": "SDR boards", "title": "SDR boards",
"description": "Which SDR boards to use as combined RF port", "description": "Which SDR boards to use as combined RF port",
...@@ -42,4 +37,11 @@ ...@@ -42,4 +37,11 @@
"uniqueItems": true "uniqueItems": true
} }
} }
},
"type": "object"
},
"type": "object"
},
"type": "object"
}
} }
...@@ -4,32 +4,23 @@ ...@@ -4,32 +4,23 @@
"title": "Sunwave M2RU", "title": "Sunwave M2RU",
"type": "object", "type": "object",
"properties": {
"sunwave": {
"title": "Sunwave M2RU",
"properties": {
"cpri": {
"title": "CPRI Link Type",
"required": [ "required": [
"ru_type",
"ru_link_type",
"n_antenna_dl", "n_antenna_dl",
"n_antenna_ul", "n_antenna_ul",
"tx_gain", "tx_gain",
"rx_gain", "rx_gain",
"cpri_link", "cpri_link",
"mac_addr" "mac_addr"
], ],
"properties": { "properties": {
"$ref": "../../ru/common.json#/properties", "$ref": "../../ru/common.json#/properties",
"ru_type": {
"$ref": "#/properties/ru_type",
"const": "sunwave",
"template": "sunwave"
},
"ru_link_type": {
"$ref": "#/properties/ru_link_type",
"const": "cpri",
"template": "cpri"
},
"n_antenna_dl": { "n_antenna_dl": {
"$ref": "#/properties/n_antenna_dl", "$ref": "#/properties/n_antenna_dl",
"default": 2 "default": 2
...@@ -59,4 +50,11 @@ ...@@ -59,4 +50,11 @@
} }
} }
} }
}.
"type": "object"
},
"type": "object"
},
"type": "object"
}
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment