mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Fixes #2485: Fix cancel button when assigning a service to a device/VM
This commit is contained in:
@ -8,6 +8,7 @@ v2.4.6 (FUTURE)
|
||||
|
||||
* [#2483](https://github.com/digitalocean/netbox/issues/2483) - Set max item count of API-populated form fields to MAX_PAGE_SIZE
|
||||
* [#2484](https://github.com/digitalocean/netbox/issues/2484) - Local config context not available on the Virtual Machine Edit Form
|
||||
* [#2485](https://github.com/digitalocean/netbox/issues/2485) - Fix cancel button when assigning a service to a device/VM
|
||||
|
||||
---
|
||||
|
||||
|
@ -991,6 +991,9 @@ class ServiceCreateView(PermissionRequiredMixin, ObjectEditView):
|
||||
obj.virtual_machine = get_object_or_404(VirtualMachine, pk=url_kwargs['virtualmachine'])
|
||||
return obj
|
||||
|
||||
def get_return_url(self, request, service):
|
||||
return service.parent.get_absolute_url()
|
||||
|
||||
|
||||
class ServiceEditView(ServiceCreateView):
|
||||
permission_required = 'ipam.change_service'
|
||||
|
Reference in New Issue
Block a user