Obtaing pricing from order
This commit is contained in:
		
					parent
					
						
							
								3ed5823c93
							
						
					
				
			
			
				commit
				
					
						ef09ae4dab
					
				
			
		
					 1 changed files with 4 additions and 4 deletions
				
			
		| 
						 | 
					@ -1208,8 +1208,8 @@ class InvoiceDetailView(LoginRequiredMixin, DetailView):
 | 
				
			||||||
                    cpu=context['vm']['cores'],
 | 
					                    cpu=context['vm']['cores'],
 | 
				
			||||||
                    ssd_size=context['vm']['disk_size'],
 | 
					                    ssd_size=context['vm']['disk_size'],
 | 
				
			||||||
                    memory=context['vm']['memory'],
 | 
					                    memory=context['vm']['memory'],
 | 
				
			||||||
                    pricing_name=(obj.vm_pricing.name
 | 
					                    pricing_name=(obj.order.vm_pricing.name
 | 
				
			||||||
                                  if obj.vm_pricing else 'default')
 | 
					                                  if obj.order.vm_pricing else 'default')
 | 
				
			||||||
                )
 | 
					                )
 | 
				
			||||||
                context['vm']['vat'] = vat
 | 
					                context['vm']['vat'] = vat
 | 
				
			||||||
                context['vm']['price'] = price
 | 
					                context['vm']['price'] = price
 | 
				
			||||||
| 
						 | 
					@ -1229,8 +1229,8 @@ class InvoiceDetailView(LoginRequiredMixin, DetailView):
 | 
				
			||||||
                        cpu=context['vm']['cores'],
 | 
					                        cpu=context['vm']['cores'],
 | 
				
			||||||
                        ssd_size=context['vm']['disk_size'],
 | 
					                        ssd_size=context['vm']['disk_size'],
 | 
				
			||||||
                        memory=context['vm']['memory'],
 | 
					                        memory=context['vm']['memory'],
 | 
				
			||||||
                        pricing_name=(obj.vm_pricing.name
 | 
					                        pricing_name=(obj.order.vm_pricing.name
 | 
				
			||||||
                                      if obj.vm_pricing else 'default')
 | 
					                                      if obj.order.vm_pricing else 'default')
 | 
				
			||||||
                    )
 | 
					                    )
 | 
				
			||||||
                    context['vm']['vat'] = vat
 | 
					                    context['vm']['vat'] = vat
 | 
				
			||||||
                    context['vm']['price'] = price
 | 
					                    context['vm']['price'] = price
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue