Bumped the version to 7
Fixed double exception being thrown Currency pipe broke the accounts pipe
This commit is contained in:
1 parent
1c2c98e7b5
commit
7b4756fe1a
26 files changed
+55
-166
No files matched your search
@@ -1,4 +1,3 @@
|
||||
import traceback
|
||||
import uuid
|
||||
|
||||
from fastapi import APIRouter, HTTPException, status, Depends, Security
|
||||
@@ -46,9 +45,7 @@ def update(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
@router.delete("/{id_}")
|
||||
@@ -68,9 +65,7 @@ def delete(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
@router.get("/list")
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import traceback
|
||||
import uuid
|
||||
from typing import List, Optional
|
||||
|
||||
@@ -41,9 +40,7 @@ def save(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
@router.put("/{id_}", response_model=schemas.Role)
|
||||
@@ -66,9 +63,7 @@ def update(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
def add_permissions(role: Role, permissions: List[schemas.PermissionItem], db):
|
||||
@@ -97,9 +92,7 @@ def delete(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
@router.get("")
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import traceback
|
||||
import uuid
|
||||
from typing import List, Optional
|
||||
|
||||
@@ -41,9 +40,7 @@ def save(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
@router.get("/me", response_model=schemas.User)
|
||||
@@ -75,9 +72,7 @@ def update_me(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
@router.put("/{id_}", response_model=schemas.User)
|
||||
@@ -103,9 +98,7 @@ def update(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
def add_roles(user: User, roles: List[schemas.RoleItem], db: Session):
|
||||
@@ -134,9 +127,7 @@ def delete(
|
||||
)
|
||||
except Exception:
|
||||
db.rollback()
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR, detail=traceback.format_exc(),
|
||||
)
|
||||
raise
|
||||
|
||||
|
||||
@router.get("")
|
||||
|
||||
Reference in new issue
Block a user