Bases: exceptions.Exception
Bases: openstack_dashboard.api.rest.utils._RestResponse
Bases: openstack_dashboard.api.rest.utils._RestResponse
Provide a decorator to wrap a view method so that it may exist in an entirely AJAX environment:
if authenticated is true then we’ll make sure the current user is authenticated.
If data_required is true then we’ll assert that there is a JSON body present.
The wrapped view method should return either:
Methods returning nothing (or None explicitly) will result in a 204 “NO CONTENT” being returned to the caller.
Extract REST filter parameters from the request GET args.
Client processes some keywords separately from filters and takes them as separate inputs. This will ignore those keys to avoid potential conflicts.
The sole purpose of this decorator is to restore original form values along with their types stored on client-side under key $$originalJSON. This in turn prevents the loss of field types when they are passed with header ‘Content-Type: multipart/form-data’, which is needed to pass a binary blob as a part of POST request.