|
@@ -1178,6 +1178,7 @@ void HttpServer::HandleCreateUser(const httplib::Request& req, httplib::Response
|
|
|
auto body = nlohmann::json::parse(req.body);
|
|
auto body = nlohmann::json::parse(req.body);
|
|
|
|
|
|
|
|
CreateUserRequest create_req;
|
|
CreateUserRequest create_req;
|
|
|
|
|
+ create_req.actor_id = auth_user->user_id;
|
|
|
if (body.contains("email")) {
|
|
if (body.contains("email")) {
|
|
|
create_req.email = body["email"].get<std::string>();
|
|
create_req.email = body["email"].get<std::string>();
|
|
|
}
|
|
}
|
|
@@ -1391,6 +1392,7 @@ void HttpServer::HandleUpdateUser(const httplib::Request& req, httplib::Response
|
|
|
auto body = nlohmann::json::parse(req.body);
|
|
auto body = nlohmann::json::parse(req.body);
|
|
|
|
|
|
|
|
UpdateUserRequest update_req;
|
|
UpdateUserRequest update_req;
|
|
|
|
|
+ update_req.actor_id = auth_user->user_id;
|
|
|
if (body.contains("email")) {
|
|
if (body.contains("email")) {
|
|
|
update_req.email = body["email"].get<std::string>();
|
|
update_req.email = body["email"].get<std::string>();
|
|
|
}
|
|
}
|
|
@@ -1536,6 +1538,7 @@ void HttpServer::HandleCreateWorkspace(const httplib::Request& req, httplib::Res
|
|
|
auto body = nlohmann::json::parse(req.body);
|
|
auto body = nlohmann::json::parse(req.body);
|
|
|
|
|
|
|
|
CreateWorkspaceRequest create_req;
|
|
CreateWorkspaceRequest create_req;
|
|
|
|
|
+ create_req.actor_id = auth_user->user_id;
|
|
|
if (body.contains("name")) {
|
|
if (body.contains("name")) {
|
|
|
create_req.name = body["name"].get<std::string>();
|
|
create_req.name = body["name"].get<std::string>();
|
|
|
}
|
|
}
|
|
@@ -1750,6 +1753,7 @@ void HttpServer::HandleUpdateWorkspace(const httplib::Request& req, httplib::Res
|
|
|
auto body = nlohmann::json::parse(req.body);
|
|
auto body = nlohmann::json::parse(req.body);
|
|
|
|
|
|
|
|
UpdateWorkspaceRequest update_req;
|
|
UpdateWorkspaceRequest update_req;
|
|
|
|
|
+ update_req.actor_id = auth_user->user_id;
|
|
|
if (body.contains("name")) {
|
|
if (body.contains("name")) {
|
|
|
update_req.name = body["name"].get<std::string>();
|
|
update_req.name = body["name"].get<std::string>();
|
|
|
}
|
|
}
|
|
@@ -1903,6 +1907,7 @@ void HttpServer::HandleCreateGroup(const httplib::Request& req, httplib::Respons
|
|
|
|
|
|
|
|
CreateGroupRequest create_req;
|
|
CreateGroupRequest create_req;
|
|
|
create_req.workspace_id = workspace_id;
|
|
create_req.workspace_id = workspace_id;
|
|
|
|
|
+ create_req.actor_id = auth_user->user_id;
|
|
|
if (body.contains("name")) {
|
|
if (body.contains("name")) {
|
|
|
create_req.name = body["name"].get<std::string>();
|
|
create_req.name = body["name"].get<std::string>();
|
|
|
}
|
|
}
|
|
@@ -2184,6 +2189,7 @@ void HttpServer::HandleUpdateGroup(const httplib::Request& req, httplib::Respons
|
|
|
auto body = nlohmann::json::parse(req.body);
|
|
auto body = nlohmann::json::parse(req.body);
|
|
|
|
|
|
|
|
UpdateGroupRequest update_req;
|
|
UpdateGroupRequest update_req;
|
|
|
|
|
+ update_req.actor_id = auth_user->user_id;
|
|
|
if (body.contains("name")) {
|
|
if (body.contains("name")) {
|
|
|
update_req.name = body["name"].get<std::string>();
|
|
update_req.name = body["name"].get<std::string>();
|
|
|
}
|
|
}
|