feat: product items
This commit is contained in:
@@ -19,6 +19,27 @@ service Product {
|
|||||||
body: "*"
|
body: "*"
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
rpc Items(ItemsReq) returns (ItemsResp) {
|
||||||
|
option (google.api.http) = {
|
||||||
|
get: "/admin/v3/product"
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
message ItemsReq {
|
||||||
|
string name = 1 [(buf.validate.field).string = {max_len: 256}];
|
||||||
|
uint32 page = 2 [(buf.validate.field) = {
|
||||||
|
ignore: IGNORE_IF_ZERO_VALUE,
|
||||||
|
uint32: {gte: 1}
|
||||||
|
}];
|
||||||
|
uint32 page_size = 3 [(buf.validate.field) = {
|
||||||
|
ignore: IGNORE_IF_ZERO_VALUE,
|
||||||
|
uint32: {gte: 1, lte: 100}
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
|
||||||
|
message ItemsResp {
|
||||||
|
repeated Item items = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message AddReq {
|
message AddReq {
|
||||||
|
|||||||
Reference in New Issue
Block a user