+22
-22
@@ -96,16 +96,16 @@ service SmmCore {
|
||||
};
|
||||
}
|
||||
|
||||
// positions
|
||||
rpc AddPosition(AddPositionReq) returns (Position) {
|
||||
// wastes
|
||||
rpc AddWaste(AddWasteReq) returns (Waste) {
|
||||
option (google.api.http) = {
|
||||
post: "/positions",
|
||||
post: "/wastes",
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
rpc DeletePosition(DeletePositionReq) returns (Position) {
|
||||
rpc DeleteWaste(DeleteWasteReq) returns (Waste) {
|
||||
option (google.api.http) = {
|
||||
delete: "/positions/{id}"
|
||||
delete: "/wastes/{id}"
|
||||
};
|
||||
}
|
||||
|
||||
@@ -127,7 +127,7 @@ message AddUserReq {
|
||||
}
|
||||
|
||||
message User {
|
||||
string id = 1;
|
||||
int32 id = 1;
|
||||
string username = 2;
|
||||
}
|
||||
|
||||
@@ -143,14 +143,14 @@ message AddBudgetReq {
|
||||
}
|
||||
|
||||
message Budget {
|
||||
string id = 1;
|
||||
int32 id = 1;
|
||||
string name = 2;
|
||||
int32 start_day = 3;
|
||||
int32 monthly_limit = 4;
|
||||
}
|
||||
|
||||
message UpdateBudgetReq {
|
||||
string id = 1;
|
||||
int32 id = 1;
|
||||
string name = 2;
|
||||
int32 start_day = 3;
|
||||
int32 monthly_limit = 4;
|
||||
@@ -163,16 +163,16 @@ message Budgets {
|
||||
}
|
||||
|
||||
message DeleteBudgetReq {
|
||||
string id = 1;
|
||||
int32 id = 1;
|
||||
}
|
||||
|
||||
message AddUserToBudgetReq {
|
||||
string user_id = 1;
|
||||
string budget_id = 2;
|
||||
int32 user_id = 1;
|
||||
int32 budget_id = 2;
|
||||
}
|
||||
|
||||
message GetBudgetUsersReq {
|
||||
string id = 1;
|
||||
int32 id = 1;
|
||||
}
|
||||
|
||||
message Users {
|
||||
@@ -180,8 +180,8 @@ message Users {
|
||||
}
|
||||
|
||||
message RemoveUserFromBudgetReq {
|
||||
string user_id = 1;
|
||||
string budget_id = 2;
|
||||
int32 user_id = 1;
|
||||
int32 budget_id = 2;
|
||||
}
|
||||
|
||||
message AddCategoryReq {
|
||||
@@ -192,7 +192,7 @@ message AddCategoryReq {
|
||||
}
|
||||
|
||||
message Category {
|
||||
string id = 1;
|
||||
int32 id = 1;
|
||||
string name = 2;
|
||||
int32 budget_id = 3;
|
||||
bool favorite = 4;
|
||||
@@ -200,7 +200,7 @@ message Category {
|
||||
}
|
||||
|
||||
message UpdateCategoryReq {
|
||||
string id = 1;
|
||||
int32 id = 1;
|
||||
string name = 2;
|
||||
bool favorite = 3;
|
||||
int32 monthly_limit = 4;
|
||||
@@ -216,25 +216,25 @@ message Categories {
|
||||
}
|
||||
|
||||
message DeleteCategoriesReq {
|
||||
string id = 1;
|
||||
int32 id = 1;
|
||||
}
|
||||
|
||||
message AddPositionReq {
|
||||
message AddWasteReq {
|
||||
string name = 1;
|
||||
int32 price = 2;
|
||||
float amount = 3;
|
||||
int32 category_id = 4;
|
||||
}
|
||||
|
||||
message Position {
|
||||
string id = 1;
|
||||
message Waste {
|
||||
int32 id = 1;
|
||||
string name = 2;
|
||||
int32 price = 3;
|
||||
float amount = 4;
|
||||
}
|
||||
|
||||
message DeletePositionReq {
|
||||
string id = 1;
|
||||
message DeleteWasteReq {
|
||||
int32 id = 1;
|
||||
}
|
||||
|
||||
message GetCategoriesStatReq {
|
||||
|
||||
Reference in New Issue
Block a user