CA-251526 - Change template order in New VM wizard

Moved "Legacy Windows" template to the bottom of the Windows templates
to discourage users from selecting it and avoid it being selected by default
at the top of the list as was the case.

Signed-off-by: Letsibogo Ramadi <letsibogo.ramadi@citrix.com>
This commit is contained in:
Letsibogo Ramadi 2017-05-04 14:09:26 +01:00
parent 76b3c05b9a
commit 0c7cf8678b
2 changed files with 21 additions and 15 deletions

View File

@ -301,6 +301,7 @@ namespace XenAdmin.Wizards.NewVMWizard
switch (templateType)
{
case VM.VmTemplateType.Windows:
case VM.VmTemplateType.LegacyWindows:
return Messages.NEWVMWIZARD_TEMPLATEPAGE_WINDOWS;
case VM.VmTemplateType.Centos:
return Messages.NEWVMWIZARD_TEMPLATEPAGE_CENTOS;
@ -339,6 +340,7 @@ namespace XenAdmin.Wizards.NewVMWizard
case VM.VmTemplateType.Custom:
return Resources._000_UserTemplate_h32bit_16;
case VM.VmTemplateType.Windows:
case VM.VmTemplateType.LegacyWindows:
return Resources.windows_h32bit_16;
case VM.VmTemplateType.Centos:
return Resources.centos_16x;

View File

@ -1018,21 +1018,22 @@ namespace XenAPI
NoTemplate = 0,//it's not a template
Custom = 1,
Windows = 2,
Centos = 3,
CoreOS = 4,
Debian = 5,
NeoKylin = 6,
Oracle = 7,
RedHat = 8,
SciLinux = 9,
Suse = 10,
Ubuntu = 11,
Citrix = 12,
Solaris = 13,
Misc = 14,
Snapshot = 15,
SnapshotFromVmpp = 16,
Count = 17 //bump this if values are added
LegacyWindows = 3,
Centos = 4,
CoreOS = 5,
Debian = 6,
NeoKylin = 7,
Oracle = 8,
RedHat = 9,
SciLinux = 10,
Suse = 11,
Ubuntu = 12,
Citrix = 13,
Solaris = 14,
Misc = 15,
Snapshot = 16,
SnapshotFromVmpp = 17,
Count = 18 //bump this if values are added
}
public VmTemplateType TemplateType
@ -1074,6 +1075,9 @@ namespace XenAPI
if (os.Contains("scientific"))
return VmTemplateType.SciLinux;
if (os.Contains("legacy windows"))
return VmTemplateType.LegacyWindows;
if (os.Contains("windows"))
return VmTemplateType.Windows;