This commit is contained in:
menghaiwen@fusen.cn 2024-01-30 15:36:41 +08:00
parent edec6d424d
commit db9efd558e

114
service/order.proto Normal file
View File

@ -0,0 +1,114 @@
syntax = "proto3"; //使v3版本
package order;
option go_package = "gitlab.fusenpack.com/backend/order;service";
// google/api/annotations.proto
import "google/api/annotations.proto";
import "service/basic.proto";
import "google/protobuf/struct.proto";
import "google/protobuf/any.proto";
//
service order {
//
rpc OrderSave(OrderSaveReq) returns (OrderSaveRes) {}
//
rpc OrderInfo(OrderInfoReq) returns (OrderInfoRes) {}
//
rpc OrderList(OrderListReq) returns (OrderListRes) {}
//
rpc DetailHandler(DetailHandlerReq) returns (DetailHandlerRes) {}
}
/* 详情处理 */
message DetailHandlerReq{
OrderDetailDb order_db = 1;//
}
message DetailHandlerRes{}
/* 详情处理 */
/* 更新详情 */
message OrderSaveReq{
OrderFilter filter = 1; //
OrderDetailDb save = 2; //
}
message OrderSaveRes{}
/* 更新详情 */
/* 获取详情 */
message OrderInfoReq{
OrderFilter filter = 1;//
}
message OrderInfoRes{
OrderInfo info = 1; //
}
/* 获取详情 */
/* 获取列表 */
message OrderListReq{
OrderFilter filter = 1; //
int64 handle_type = 2; // 0=1=
int64 current_page =101; //
int64 per_page =102; //
string order_by = 103; // id desc,ctime desc
}
message OrderListRes{
repeated OrderInfo list = 1;//
basic.Meta meta = 2; //
}
/* 获取列表 */
/* 过滤条件 */
message OrderFilter {
optional int64 id = 1;// ID
optional int64 user_id = 2; // ID
optional int64 delivery_method = 3; //
optional string order_sn = 4; //
optional string order_source = 5; //
optional int64 status = 6; //
optional int64 is_del = 7; // 0=1=
optional int64 pay_status = 8; //
optional int64 sale_gerent_id = 9; //
optional int64 design_gerent_id = 10; //
optional bytes other_filter = 101; //
repeated int64 ids = 102; // IDS
}
/* 详情数据 */
message OrderInfo {
OrderDetailDb order_detail_db = 1; //
bytes order_detail = 2; //
}
/* 数据库 */
message OrderDetailDb {
optional int64 id = 1; // ID
optional int64 user_id = 2; // ID
optional int64 delivery_method = 3; //
optional string order_sn = 4; //
optional string order_source = 5; //
optional int64 status = 6; //
optional bytes metadata = 7; //
optional string ctime = 8; //
optional string utime = 9; //
optional int64 is_del = 10; // 0 = 1 =
optional int64 pay_status = 11; //
optional bytes status_link = 12; //
optional bytes order_product = 13; //
optional bytes order_address = 14; //
optional bytes order_amount = 15; //
optional bytes pay_status_link = 16; //
optional bytes shopping_cart_snapshot = 17; //
optional bytes shopping_product_snapshot = 18; //
optional int64 sale_gerent_id = 19; //
optional int64 design_gerent_id = 20; //
optional bytes scm = 21; //
}