feat: import services and standardize Go 1.26.5
This commit is contained in:
35
apps/ec/delivery/proto/blocks.proto
Normal file
35
apps/ec/delivery/proto/blocks.proto
Normal file
@@ -0,0 +1,35 @@
|
||||
syntax = "proto3";
|
||||
package feed;
|
||||
option go_package = "./;feed";
|
||||
|
||||
message FetchRequest {
|
||||
int64 page_no=1; // 页数
|
||||
int64 page_size=2; // 每页记录数
|
||||
map<string,string> params=3; // 条件参数,key=val,eg key:category_id=?,vlaue=11
|
||||
}
|
||||
|
||||
message IdentRequest{
|
||||
int64 id = 1; // 唯一ID
|
||||
string identity = 2; // 唯一码
|
||||
}
|
||||
|
||||
message VersionRequest {
|
||||
int64 version=1; // 时序版本号
|
||||
}
|
||||
|
||||
|
||||
message SearchRequest {
|
||||
string keyword=1; //关键词
|
||||
}
|
||||
|
||||
|
||||
message StatusReply{
|
||||
int64 status = 1; // 状态码
|
||||
string identity=2; // 标识码
|
||||
string message=3; //状态说明
|
||||
int64 timeseq=4; // 响应时间序列
|
||||
}
|
||||
|
||||
message Empty{
|
||||
}
|
||||
|
||||
41
apps/ec/delivery/proto/car.proto
Normal file
41
apps/ec/delivery/proto/car.proto
Normal file
@@ -0,0 +1,41 @@
|
||||
syntax = "proto3";
|
||||
package delivery;
|
||||
option go_package = "./delivery";
|
||||
import "blocks.proto";
|
||||
|
||||
// Delivery(配送)微服务
|
||||
service Car {
|
||||
// 配送车辆列表
|
||||
rpc CarList(FetchRequest) returns (CarListReply) {};
|
||||
|
||||
// 添加配送车辆信息
|
||||
rpc CarAdd(CarItem) returns (StatusReply) {};
|
||||
|
||||
// 获取配送车辆信息
|
||||
rpc CarGet(IdentRequest)returns (CarItem) {};
|
||||
|
||||
// 修改配送车辆信息
|
||||
rpc CarSet(CarItem) returns (StatusReply) {};
|
||||
|
||||
// 删除配送车辆信息
|
||||
rpc CarDel(IdentRequest) returns (StatusReply) {};
|
||||
|
||||
}
|
||||
message CarListReply{
|
||||
int64 count = 1;
|
||||
repeated CarItem list = 2;
|
||||
}
|
||||
|
||||
|
||||
|
||||
message CarItem{
|
||||
string identity = 1; // 唯一标识
|
||||
string brand = 2; // 品牌
|
||||
string version = 3; // 型号
|
||||
string license_number = 4; // 车牌号
|
||||
string team_identity = 5; // 团队唯一标识
|
||||
string contacts = 6; // 联系人姓名
|
||||
string phone = 7; // 联系人电话
|
||||
int64 status = 8; // 状态:1正常;-1禁用
|
||||
string picture = 9; // 车辆图片
|
||||
}
|
||||
35
apps/ec/delivery/proto/member.proto
Normal file
35
apps/ec/delivery/proto/member.proto
Normal file
@@ -0,0 +1,35 @@
|
||||
syntax = "proto3";
|
||||
package delivery;
|
||||
option go_package = "./delivery";
|
||||
import "blocks.proto";
|
||||
|
||||
// Delivery(配送)微服务
|
||||
service Member {
|
||||
// 获取配送员列表
|
||||
rpc MemberList(FetchRequest) returns (MemberListReply) {};
|
||||
|
||||
// 添加配送员
|
||||
rpc MemberAdd(MemberItem) returns (StatusReply) {};
|
||||
|
||||
// 获取配送员数据
|
||||
rpc MemberGet(IdentRequest)returns (MemberItem) {};
|
||||
|
||||
// 修改配送员
|
||||
rpc MemberSet(MemberItem) returns (StatusReply) {};
|
||||
|
||||
// 删除配送员
|
||||
rpc MemberDel(IdentRequest) returns (StatusReply) {};
|
||||
}
|
||||
message MemberItem{
|
||||
string identity = 1; // 唯一标识
|
||||
string name = 2; // 姓名
|
||||
string team_identity = 3; // 团队唯一标识
|
||||
string picture = 4; // 头像
|
||||
string phone = 5; // 联系人电话
|
||||
int64 status = 6; // 状态:1正常;-1禁用
|
||||
int64 turnover = 7; // 总成交量
|
||||
}
|
||||
message MemberListReply{
|
||||
int64 count = 1;
|
||||
repeated MemberItem list = 2;
|
||||
}
|
||||
37
apps/ec/delivery/proto/team.proto
Normal file
37
apps/ec/delivery/proto/team.proto
Normal file
@@ -0,0 +1,37 @@
|
||||
syntax = "proto3";
|
||||
package delivery;
|
||||
option go_package = "./delivery";
|
||||
import "blocks.proto";
|
||||
|
||||
// Delivery(配送)微服务
|
||||
service Team {
|
||||
|
||||
// 配送团队列表
|
||||
rpc TeamList(FetchRequest) returns (TeamListReply) {};
|
||||
|
||||
// 添加配送团队
|
||||
rpc TeamAdd(TeamItem) returns (StatusReply) {};
|
||||
|
||||
// 配送团队详情
|
||||
rpc TeamGet(IdentRequest) returns (TeamItem) {};
|
||||
|
||||
// 修改配送团队信息
|
||||
rpc TeamSet(TeamItem) returns (StatusReply) {};
|
||||
|
||||
// 删除配送团队
|
||||
rpc TeamDel(IdentRequest) returns (StatusReply) {};
|
||||
}
|
||||
|
||||
message TeamListReply{
|
||||
int64 count = 1;
|
||||
repeated TeamItem list = 2;
|
||||
}
|
||||
message TeamItem{
|
||||
string identity = 1; // 唯一标识
|
||||
string title = 2; // 团队名称
|
||||
string owner = 3; // 归属者唯一标识
|
||||
string contacts = 4; // 联系人姓名
|
||||
string phone = 5; // 联系人电话
|
||||
int64 status = 6; // 状态:1正常;-1禁用
|
||||
string logo = 7; // 团队图标地址
|
||||
}
|
||||
Reference in New Issue
Block a user