1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2024-12-24 15:15:22 +00:00

add warning for dublicate instance name on other host

This commit is contained in:
catborise 2018-10-04 10:14:08 +03:00
parent d75df231a8
commit e1910c75ff

View file

@ -99,6 +99,8 @@ def create_instance(request, compute_id):
if data['name'] in instances:
msg = _("A virtual machine with this name already exists")
error_messages.append(msg)
if Instance.objects.filter(name__exact=data['name']):
messages.warning(request,_("There is an instance with same name. Are you sure?"))
if not error_messages:
if data['hdd_size']:
if not data['mac']: