config_tools: hide tty and sock in UI

For virtio console, in order to hide tty and sock backend types,
change "xs:sequence" to "xs:all" in the XML schema
to slice the backend type list and update backend type to
"BasicVirtioConsoleBackendType" to call the sliced value.

Tracked-On: #6691
Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
This commit is contained in:
Kunhui-Li 2022-05-20 15:59:46 +08:00 committed by acrnsi-robot
parent 57e0b966e9
commit af10a3bb0a
2 changed files with 3 additions and 3 deletions

View File

@ -96,7 +96,7 @@ export default {
data() {
return {
ConsoleUseType: this.rootSchema.definitions['VirtioConsoleUseType']['enum'],
ConsoleBackendType: this.rootSchema.definitions['VirtioConsoleBackendType']['enum'],
ConsoleBackendType: this.rootSchema.definitions['BasicVirtioConsoleBackendType']['enum'],
defaultVal: vueUtils.getPathVal(this.rootFormData, this.curNodePath)
};
},

View File

@ -362,7 +362,7 @@ The size is a subset of the VM's total memory size specified on the Basic tab.</
</xs:simpleType>
<xs:complexType name="VirtioConsoleConfiguration">
<xs:sequence>
<xs:all>
<xs:element name="use_type" type="VirtioConsoleUseType" minOccurs="0">
<xs:annotation acrn:title="Use type">
<xs:documentation>Specify device type in guest, ether HVC console when user config it as virtio console or /dev/vportXpY
@ -389,7 +389,7 @@ device file when user config it as virtio serial port, which can be read and wri
<xs:documentation>The device path for the tty backend type.</xs:documentation>
</xs:annotation>
</xs:element>
</xs:sequence>
</xs:all>
</xs:complexType>
<xs:complexType name="VirtioInputConfiguration">