add places operations

This commit is contained in:
2026-07-14 01:25:57 +07:00
parent 2b11c49b3c
commit 7a657926f1
12 changed files with 502 additions and 175 deletions
+11 -8
View File
@@ -252,7 +252,7 @@ service EveningDetectiveServer {
rpc AddScenarioPlace(AddScenarioPlaceReq) returns (AddScenarioPlaceRsp) {
option (google.api.http) = {
post: "/api/scenarios/places"
post: "/api/scenarios/{id}/places"
body: "*"
};
option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation) = {
@@ -263,7 +263,7 @@ service EveningDetectiveServer {
rpc UpdateScenarioPlace(UpdateScenarioPlaceReq) returns (UpdateScenarioPlaceRsp) {
option (google.api.http) = {
put : "/api/scenarios/places/{code}"
put : "/api/scenarios/{id}/places/{code}"
body: "*"
};
option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation) = {
@@ -274,7 +274,7 @@ service EveningDetectiveServer {
rpc DeleteScenarioPlace(DeleteScenarioPlaceReq) returns (DeleteScenarioPlaceRsp) {
option (google.api.http) = {
delete: "/api/scenarios/places/{code}"
delete: "/api/scenarios/{id}/places/{code}"
};
option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation) = {
tags : "Точки сценария";
@@ -425,7 +425,7 @@ message GetScenarioReq {
}
message GetScenarioRsp {
string error = 1;
string error = 1;
Scenario scenario = 2;
}
@@ -491,7 +491,8 @@ message DeleteScenarioRsp {
}
message AddScenarioPlaceReq {
Place place = 1;
int32 id = 1;
Place place = 2;
}
message AddScenarioPlaceRsp {
@@ -499,8 +500,9 @@ message AddScenarioPlaceRsp {
}
message UpdateScenarioPlaceReq {
string code = 1;
Place place = 2;
int32 id = 1;
string code = 2;
Place place = 3;
}
message UpdateScenarioPlaceRsp {
@@ -508,7 +510,8 @@ message UpdateScenarioPlaceRsp {
}
message DeleteScenarioPlaceReq {
string code = 1;
int32 id = 1;
string code = 2;
}
message DeleteScenarioPlaceRsp {