feat: Enhance user permissions and update event handling with improved response structures
This commit is contained in:
1 parent
01e20baa45
commit
8402415649
11 files changed
+147
-43
No files matched your search
@@ -43,3 +43,14 @@ pub fn common_response(status: StatusCode, message: &str) -> Response {
|
||||
)
|
||||
.into_response()
|
||||
}
|
||||
|
||||
pub fn success_created_response<T: Serialize>(params: ResponseSuccessDto<T>) -> Response {
|
||||
(
|
||||
StatusCode::CREATED,
|
||||
Json(json!({
|
||||
"data": params.data,
|
||||
"version": "0.1.0",
|
||||
})),
|
||||
)
|
||||
.into_response()
|
||||
}
|
||||
Reference in new issue
Block a user