Pārlūkot izejas kodu

创建订单修改

renjiaojiao 3 gadi atpakaļ
vecāks
revīzija
4162fe7a5a

+ 3 - 0
api/internal/logic/createorderlogic.go

@@ -81,6 +81,9 @@ func (l *CreateOrderLogic) CreateOrder(req types.Request) (*types.Response, erro
 		EntryTime:         req.Entry_time,
 		Commission:        req.Commission,
 		ProceduresMoney:   req.ProceduresMoney,
+		SalesChannel:      req.SalesChannel,
+		OrderChannel:      req.OrderChannel,
+		PaybackCompany:    req.PaybackCompany,
 		/*PaymentType:req.Payment_type,
 		SourceOrderId: req.Source_order_id,*/
 	})

+ 3 - 0
api/internal/types/types.go

@@ -56,6 +56,9 @@ type Request struct {
 	Entry_time          string `form:"entry_time,optional"`
 	Commission          int64  `form:"commission,optional"`
 	ProceduresMoney     int64  `form:"procedures_money,optional"`
+	SalesChannel        string `form:"salesChannel,optional"`
+	OrderChannel        string `form:"orderChannel,optional"`
+	PaybackCompany      string `form:"paybackCompany,optional"`
 }
 
 type Response struct {

+ 3 - 0
api/jyOrder.api

@@ -63,6 +63,9 @@ type request {
 	Entry_time          string `form:"entry_time,optional"`
 	Commission          int64  `form:"commission,optional"`
 	ProceduresMoney     int64  `form:"procedures_money,optional"`
+	SalesChannel        string `form:"salesChannel,optional"`
+	OrderChannel        string `form:"orderChannel,optional"`
+	PaybackCompany      string `form:"paybackCompany,optional"`
 }
 
 type response {

+ 4 - 0
rpc/jyOrder.proto

@@ -1,6 +1,7 @@
 syntax = "proto3";
 
 package jyOrder;
+//option go_package = "jyOrder/";
 
 message Request {
   int64  pay_money = 1;
@@ -57,6 +58,9 @@ message Request {
   string entry_time = 52;
   int64  commission = 53;
   int64  procedures_money = 54;
+  string salesChannel = 55;
+  string orderChannel = 56;
+  string  paybackCompany = 57;
 }
 
 message Response {

+ 37 - 10
rpc/jyOrder/jyOrder.pb.go

@@ -1,14 +1,13 @@
 // Code generated by protoc-gen-go. DO NOT EDIT.
 // versions:
-// 	protoc-gen-go v1.25.0
-// 	protoc        v3.15.1
+// 	protoc-gen-go v1.27.1
+// 	protoc        v3.19.4
 // source: jyOrder.proto
 
 package jyOrder
 
 import (
 	context "context"
-	proto "github.com/golang/protobuf/proto"
 	grpc "google.golang.org/grpc"
 	codes "google.golang.org/grpc/codes"
 	status "google.golang.org/grpc/status"
@@ -25,10 +24,6 @@ const (
 	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
 )
 
-// This is a compile-time assertion that a sufficiently up-to-date version
-// of the legacy proto package is being used.
-const _ = proto.ProtoPackageIsVersion4
-
 type Request struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -88,6 +83,9 @@ type Request struct {
 	EntryTime         string `protobuf:"bytes,52,opt,name=entry_time,json=entryTime,proto3" json:"entry_time,omitempty"`
 	Commission        int64  `protobuf:"varint,53,opt,name=commission,proto3" json:"commission,omitempty"`
 	ProceduresMoney   int64  `protobuf:"varint,54,opt,name=procedures_money,json=proceduresMoney,proto3" json:"procedures_money,omitempty"`
+	SalesChannel      string `protobuf:"bytes,55,opt,name=salesChannel,proto3" json:"salesChannel,omitempty"`
+	OrderChannel      string `protobuf:"bytes,56,opt,name=orderChannel,proto3" json:"orderChannel,omitempty"`
+	PaybackCompany    string `protobuf:"bytes,57,opt,name=paybackCompany,proto3" json:"paybackCompany,omitempty"`
 }
 
 func (x *Request) Reset() {
@@ -500,6 +498,27 @@ func (x *Request) GetProceduresMoney() int64 {
 	return 0
 }
 
+func (x *Request) GetSalesChannel() string {
+	if x != nil {
+		return x.SalesChannel
+	}
+	return ""
+}
+
+func (x *Request) GetOrderChannel() string {
+	if x != nil {
+		return x.OrderChannel
+	}
+	return ""
+}
+
+func (x *Request) GetPaybackCompany() string {
+	if x != nil {
+		return x.PaybackCompany
+	}
+	return ""
+}
+
 type Response struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -638,7 +657,7 @@ var File_jyOrder_proto protoreflect.FileDescriptor
 
 var file_jyOrder_proto_rawDesc = []byte{
 	0x0a, 0x0d, 0x6a, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12,
-	0x07, 0x6a, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x22, 0xcf, 0x0e, 0x0a, 0x07, 0x52, 0x65, 0x71,
+	0x07, 0x6a, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x22, 0xbf, 0x0f, 0x0a, 0x07, 0x52, 0x65, 0x71,
 	0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x79, 0x5f, 0x6d, 0x6f, 0x6e, 0x65,
 	0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x70, 0x61, 0x79, 0x4d, 0x6f, 0x6e, 0x65,
 	0x79, 0x12, 0x1f, 0x0a, 0x0b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x6d, 0x6f, 0x6e, 0x65, 0x79,
@@ -755,7 +774,14 @@ var file_jyOrder_proto_rawDesc = []byte{
 	0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x12,
 	0x29, 0x0a, 0x10, 0x70, 0x72, 0x6f, 0x63, 0x65, 0x64, 0x75, 0x72, 0x65, 0x73, 0x5f, 0x6d, 0x6f,
 	0x6e, 0x65, 0x79, 0x18, 0x36, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x70, 0x72, 0x6f, 0x63, 0x65,
-	0x64, 0x75, 0x72, 0x65, 0x73, 0x4d, 0x6f, 0x6e, 0x65, 0x79, 0x22, 0x4c, 0x0a, 0x08, 0x52, 0x65,
+	0x64, 0x75, 0x72, 0x65, 0x73, 0x4d, 0x6f, 0x6e, 0x65, 0x79, 0x12, 0x22, 0x0a, 0x0c, 0x73, 0x61,
+	0x6c, 0x65, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x18, 0x37, 0x20, 0x01, 0x28, 0x09,
+	0x52, 0x0c, 0x73, 0x61, 0x6c, 0x65, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x22,
+	0x0a, 0x0c, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x43, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x18, 0x38,
+	0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x43, 0x68, 0x61, 0x6e, 0x6e,
+	0x65, 0x6c, 0x12, 0x26, 0x0a, 0x0e, 0x70, 0x61, 0x79, 0x62, 0x61, 0x63, 0x6b, 0x43, 0x6f, 0x6d,
+	0x70, 0x61, 0x6e, 0x79, 0x18, 0x39, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x70, 0x61, 0x79, 0x62,
+	0x61, 0x63, 0x6b, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x22, 0x4c, 0x0a, 0x08, 0x52, 0x65,
 	0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01,
 	0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65,
 	0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73,
@@ -777,7 +803,8 @@ var file_jyOrder_proto_rawDesc = []byte{
 	0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x12, 0x18, 0x2e, 0x6a, 0x79, 0x4f, 0x72, 0x64,
 	0x65, 0x72, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c,
 	0x65, 0x64, 0x1a, 0x11, 0x2e, 0x6a, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x2e, 0x52, 0x65, 0x73,
-	0x70, 0x6f, 0x6e, 0x73, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+	0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x0a, 0x5a, 0x08, 0x6a, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72,
+	0x2f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 
 var (

+ 2 - 2
rpc/jyorderclient/jyorder.go

@@ -1,7 +1,7 @@
 // Code generated by goctl. DO NOT EDIT!
 // Source: jyOrder.proto
 
-//go:generate mockgen -destination ./jyorder_mock.go -package jyorderclient -source $GOFILE
+//go:generate mockgen -destination ./jyorder_mock.go -package jyorder -source $GOFILE
 
 package jyorderclient
 
@@ -14,9 +14,9 @@ import (
 )
 
 type (
-	RequestDetailed = jyOrder.RequestDetailed
 	Request         = jyOrder.Request
 	Response        = jyOrder.Response
+	RequestDetailed = jyOrder.RequestDetailed
 
 	JyOrder interface {
 		// 创建订单