From 4e080c9afc98c6db23e3b2dede914897ba587ec1 Mon Sep 17 00:00:00 2001 From: PCoder Date: Thu, 28 Sep 2017 02:36:49 +0530 Subject: [PATCH] Invoice: Get VM name from id and configuration --- hosting/views.py | 1 + 1 file changed, 1 insertion(+) diff --git a/hosting/views.py b/hosting/views.py index e694f55b..4d736aa8 100644 --- a/hosting/views.py +++ b/hosting/views.py @@ -694,6 +694,7 @@ class OrdersHostingDetailView(LoginRequiredMixin, try: vm_detail = VMDetail.objects.get(vm_id=obj.vm_id) context['vm'] = vm_detail.__dict__ + context['vm']['name'] = '{}-{}'.format(context['vm']['configuration'], context['vm']['vm_id']) except VMDetail.DoesNotExist: try: manager = OpenNebulaManager(