ForestAdmin/django-forest

View on GitHub
django_forest/actions/hooks/views/load.py

Summary

Maintainability
A
0 mins
Test Coverage
A
100%
from django_forest.actions.hooks.views.utils import HookView


class LoadView(HookView):
    def handle_action(self, action, action_name, request):
        if self.hook_exists(action, action_name, 'load'):
            return action['hooks']['load'](action['fields'], request)