summaryrefslogtreecommitdiffstats
path: root/sdnr/wt/odlux
diff options
context:
space:
mode:
authorKAPIL SINGAL <ks220y@att.com>2020-03-09 20:30:13 +0000
committerGerrit Code Review <gerrit@onap.org>2020-03-09 20:30:13 +0000
commitb8d303a0d4e097da5d32f7062b9999605d93965c (patch)
tree5168b3b671bcba6a129c00faef29c1f561a11aff /sdnr/wt/odlux
parentc6152aa0eec8c0062489501cf3e12f87423ac592 (diff)
parent040ec967ff4b6bdf92e7d24ec6d3ac75002a3f4b (diff)
Merge "Fix behavior of config app" into frankfurt
Diffstat (limited to 'sdnr/wt/odlux')
-rw-r--r--sdnr/wt/odlux/apps/configurationApp/src/yang/yangParser.ts8
1 files changed, 5 insertions, 3 deletions
diff --git a/sdnr/wt/odlux/apps/configurationApp/src/yang/yangParser.ts b/sdnr/wt/odlux/apps/configurationApp/src/yang/yangParser.ts
index 5322e1f6f..27859f7b6 100644
--- a/sdnr/wt/odlux/apps/configurationApp/src/yang/yangParser.ts
+++ b/sdnr/wt/odlux/apps/configurationApp/src/yang/yangParser.ts
@@ -650,12 +650,14 @@ export class YangParser {
const lists = this.extractNodes(statement, "list");
if (lists && lists.length > 0) {
subViews.push(...lists.reduce<ViewSpecification[]>((acc, cur) => {
+ let elmConfig = config;
if (!cur.arg) {
throw new Error(`Module: [${context.name}]${currentPath}. Found list without name.`);
}
const key = this.extractValue(cur, "key") || undefined;
- if (config && !key) {
- throw new Error(`Module: [${context.name}]${currentPath}. Found configurable list without key.`);
+ if (elmConfig && !key) {
+ console.error(new Error(`Module: [${context.name}]${currentPath}. Found configurable list without key.`));
+ elmConfig = false;
}
const [currentView, subViews] = this.extractSubViews(cur, currentId, context, `${currentPath}/${context.name}:${cur.arg}`);
elements.push({
@@ -665,7 +667,7 @@ export class YangParser {
uiType: "object",
viewId: currentView.id,
key: key,
- config: config
+ config: elmConfig
});
acc.push(currentView, ...subViews);
return acc;