Simplified "has permission" logic and fixed a major flow in "{resoruce}/grid" not applying correct data to _actions

Function has_resource_permission() need to live in depends.py as it cause circular dependencies if in common.py
This commit is contained in:
swevm
2021-01-21 10:48:02 +01:00
parent 861aea95ab
commit 1d79c1ff73
3 changed files with 21 additions and 28 deletions

View File

@@ -1,6 +1,7 @@
import importlib
from copy import deepcopy
from fastapi import HTTPException
from passlib.context import CryptContext
from tortoise import Tortoise