diff --git a/misc/acrn-config/config_app/templates/scenario.html b/misc/acrn-config/config_app/templates/scenario.html
index 49ad0db92..c7bea32da 100644
--- a/misc/acrn-config/config_app/templates/scenario.html
+++ b/misc/acrn-config/config_app/templates/scenario.html
@@ -85,11 +85,19 @@
{% if 'configurable' not in vm.attrib or vm.attrib['configurable'] != '0'%}
+ {% if vm.tag != 'vm' %}
+ {% set vm_type = 'hv' %}
+
+ {% endif %}
{% if 'desc' in vm.attrib or vm.attrib['desc'] == 'specific for Kata' %}
@@ -106,13 +114,13 @@
title="{{elem.attrib['desc'] if 'desc' in elem.attrib else elem.tag}}">{{elem.tag}}
- {% if ','.join(['vm', elem.tag]) not in scenario_item_values %}
+ {% if ','.join([vm.tag, elem.tag]) not in scenario_item_values %}
{% if 'readonly' in elem.attrib and elem.attrib['readonly'] == 'true' %}
-
{% else %}
-
{% endif %}
@@ -120,12 +128,12 @@
{% if 'readonly' in elem.attrib and elem.attrib['readonly'] == 'true' %}
{% endif %}
-
+
{% elif elem.getchildren() != [] and ('configurable' not in elem.attrib or elem.attrib['configurable']
!= '0')%}
@@ -159,41 +167,41 @@
title="{{sub_elem.attrib['desc'] if 'desc' in sub_elem.attrib else sub_elem.tag}}">
{{sub_elem.tag}}
- {% if ','.join(['vm', elem.tag, sub_elem.tag]) not in scenario_item_values and elem.tag != 'vcpu_affinity' %}
+ {% if ','.join([vm.tag, elem.tag, sub_elem.tag]) not in scenario_item_values and elem.tag != 'vcpu_affinity' %}
{% if sub_elem.tag in ['bootargs', 'kern_args'] %}
{% if 'readonly' in sub_elem.attrib and sub_elem.attrib['readonly'] == 'true' %}
{% else %}
+ id="{{vm_type+','+elem.tag+','+sub_elem.tag}}">{{sub_elem_text}}
{% endif %}
{% else %}
{% if 'readonly' in sub_elem.attrib and sub_elem.attrib['readonly'] == 'true' %}
{% else %}
{% endif %}
{% endif %}
{% else %}
- {% set item_key = ','.join(['vm', elem.tag, sub_elem.tag]) if elem.tag != 'vcpu_affinity' else
- ','.join(['vm', elem.tag])%}
+ {% set item_key = ','.join([vm.tag, elem.tag, sub_elem.tag]) if elem.tag != 'vcpu_affinity' else
+ ','.join([vm.tag, elem.tag])%}
{% if 'readonly' in sub_elem.attrib and sub_elem.attrib['readonly'] == 'true' %}
+ id="{{vm_type+','+elem.tag+','+sub_elem.tag}}" disabled>
{% else %}
+ id="{{vm_type+','+elem.tag+','+sub_elem.tag}}">
{% endif %}
{% for item_value in scenario_item_values[item_key] %}
{% if item_value == sub_elem_text %}
@@ -215,36 +223,36 @@
{% endif %}
{% do first_child.append(1) %}
-
+
{% else %}
{% if not first_child %}
{% do first_child.append(1) %}
{% else %}
{% endif %}
- {% if (','.join(['vm', elem.tag, sub_elem.tag]) not in scenario_item_values) and
+ {% if (','.join([vm.tag, elem.tag, sub_elem.tag]) not in scenario_item_values) and
(elem.tag!='vuart' or sub_elem.tag!='base') %}
+ id="{{vm_type+','+elem.tag+':id='+elem.attrib['id']+','+sub_elem.tag}}_config">
{% if 'readonly' in sub_elem.attrib and sub_elem.attrib['readonly'] == 'true' %}
{% else %}
{% endif %}
@@ -252,14 +260,14 @@
{% if 'readonly' in sub_elem.attrib and sub_elem.attrib['readonly'] == 'true' %}
+ id="{{vm_type+','+elem.tag+':id='+elem.attrib['id']+','+sub_elem.tag}}">
{% else %}
+ id="{{vm_type+','+elem.tag+':id='+elem.attrib['id']+','+sub_elem.tag}}">
{% endif %}
{% set key = ('vm='+vm.attrib['id']+','+elem.tag+'='+elem.attrib['id']+','+sub_elem.tag)
if (elem.tag=='vuart' and sub_elem.tag=='base')
- else ','.join(['vm', elem.tag, sub_elem.tag]) %}
+ else ','.join([vm.tag, elem.tag, sub_elem.tag]) %}
{% for item_value in scenario_item_values[key] %}
{% if item_value == sub_elem_text %}
@@ -270,7 +278,7 @@
{% endif %}
-
{% endif %}
@@ -285,14 +293,14 @@
{% if 'readonly' in elem.attrib and elem.attrib['readonly'] == 'true' %}
{% else %}
{% endif %}
- {% if ','.join(['vm', elem.tag]) not in scenario_item_values %}
+ {% if ','.join([vm.tag, elem.tag]) not in scenario_item_values %}
{% set x=1 %}
{% for sub_elem in elem.getchildren() %}
@@ -302,7 +310,7 @@
{% for sub_elem in elem.getchildren() %}
{% do selected_list.append(sub_elem.text) %}
{% endfor %}
- {% for item_value in scenario_item_values[','.join(['vm', elem.tag])] %}
+ {% for item_value in scenario_item_values[','.join([vm.tag, elem.tag])] %}
{% if item_value in selected_list %}
{% else %}
@@ -312,7 +320,7 @@
{% endif %}