I am a beginner in the realm of AngularJS and currently facing an issue that needs resolution. I have implemented two select boxes which are populated with data fetched from an external JSON file. My objective is to dynamically update the options in the second select box based on the selection made in the first one. Each item in the first select box contains a unique key called relation, which I intend to use as a trigger for the dynamic update of options in the second select box.
Seeking assistance from anyone familiar with this scenario. I attempted to create a function but unfortunately, it did not yield the desired outcome. Thank you in advance for any help provided. Below is the structure of the JSON data:
{
"filterElements": [
{
"parameters": [
{
"paraName": "paraOne",
"relation": "default"
},
{
"paraName": "paraTwo",
"relation": "default"
},
{
"paraName": "paraThree",
"relation": "defaultshort"
}
]
},
{
"relations": [
{
"defaultrelation":
[
"equals",
"does not equal",
"greater than",
"less than"
]
},
{
"defaultshort":
[
"equals",
"does not equal"
]
}
]
}
]
}