ordercenterserver.go 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. // Code generated by goctl. DO NOT EDIT!
  2. // Source: orderCenter.proto
  3. package server
  4. import (
  5. "context"
  6. "bp.jydev.jianyu360.cn/BaseService/orderCenter/rpc/internal/logic"
  7. "bp.jydev.jianyu360.cn/BaseService/orderCenter/rpc/internal/svc"
  8. "bp.jydev.jianyu360.cn/BaseService/orderCenter/rpc/pb"
  9. )
  10. type OrderCenterServer struct {
  11. svcCtx *svc.ServiceContext
  12. }
  13. func NewOrderCenterServer(svcCtx *svc.ServiceContext) *OrderCenterServer {
  14. return &OrderCenterServer{
  15. svcCtx: svcCtx,
  16. }
  17. }
  18. // 分布式ID生成器
  19. func (s *OrderCenterServer) GetOrderCode(ctx context.Context, in *pb.GetOrderCodeReq) (*pb.GetOrderCodeResp, error) {
  20. l := logic.NewGetOrderCodeLogic(ctx, s.svcCtx)
  21. return l.GetOrderCode(in)
  22. }
  23. // 订单增加
  24. func (s *OrderCenterServer) OrderAdd(ctx context.Context, in *pb.OrderAddUpdateReq) (*pb.OrderAddUpdateResp, error) {
  25. l := logic.NewOrderAddLogic(ctx, s.svcCtx)
  26. return l.OrderAdd(in)
  27. }
  28. // 订单修改
  29. func (s *OrderCenterServer) OrderUpdate(ctx context.Context, in *pb.OrderAddUpdateReq) (*pb.OrderAddUpdateResp, error) {
  30. l := logic.NewOrderUpdateLogic(ctx, s.svcCtx)
  31. return l.OrderUpdate(in)
  32. }
  33. // 订单修改状态
  34. func (s *OrderCenterServer) OrderStatusUpdate(ctx context.Context, in *pb.OrderStatusUpdateReq) (*pb.OrderAddUpdateResp, error) {
  35. l := logic.NewOrderStatusUpdateLogic(ctx, s.svcCtx)
  36. return l.OrderStatusUpdate(in)
  37. }
  38. // 订单删除
  39. func (s *OrderCenterServer) OrderDel(ctx context.Context, in *pb.OrderDelReq) (*pb.OrderAddUpdateResp, error) {
  40. l := logic.NewOrderDelLogic(ctx, s.svcCtx)
  41. return l.OrderDel(in)
  42. }
  43. // 订单列表
  44. func (s *OrderCenterServer) OrderList(ctx context.Context, in *pb.OrderListReq) (*pb.OrderListResp, error) {
  45. l := logic.NewOrderListLogic(ctx, s.svcCtx)
  46. return l.OrderList(in)
  47. }
  48. // 订单查看
  49. func (s *OrderCenterServer) OrderInfo(ctx context.Context, in *pb.OrderInfoReq) (*pb.OrderInfoResp, error) {
  50. l := logic.NewOrderInfoLogic(ctx, s.svcCtx)
  51. return l.OrderInfo(in)
  52. }
  53. // 订单审核
  54. func (s *OrderCenterServer) OrderExamine(ctx context.Context, in *pb.OrderExamineReq) (*pb.OrderAddUpdateResp, error) {
  55. l := logic.NewOrderExamineLogic(ctx, s.svcCtx)
  56. return l.OrderExamine(in)
  57. }
  58. // 订单支付
  59. func (s *OrderCenterServer) PayAdd(ctx context.Context, in *pb.PayAddReq) (*pb.OrderAddUpdateResp, error) {
  60. l := logic.NewPayAddLogic(ctx, s.svcCtx)
  61. return l.PayAdd(in)
  62. }
  63. // 订单支付信息
  64. func (s *OrderCenterServer) PayInfo(ctx context.Context, in *pb.OrderInfoReq) (*pb.PayInfoResp, error) {
  65. l := logic.NewPayInfoLogic(ctx, s.svcCtx)
  66. return l.PayInfo(in)
  67. }
  68. // 订单退款
  69. func (s *OrderCenterServer) RefundAdd(ctx context.Context, in *pb.RefundAddReq) (*pb.OrderAddUpdateResp, error) {
  70. l := logic.NewRefundAddLogic(ctx, s.svcCtx)
  71. return l.RefundAdd(in)
  72. }
  73. // 订单退款信息
  74. func (s *OrderCenterServer) RefundInfo(ctx context.Context, in *pb.OrderInfoReq) (*pb.RefundInfoResp, error) {
  75. l := logic.NewRefundInfoLogic(ctx, s.svcCtx)
  76. return l.RefundInfo(in)
  77. }
  78. // 订单开票
  79. func (s *OrderCenterServer) InvoiceAdd(ctx context.Context, in *pb.InvoiceAddReq) (*pb.OrderAddUpdateResp, error) {
  80. l := logic.NewInvoiceAddLogic(ctx, s.svcCtx)
  81. return l.InvoiceAdd(in)
  82. }
  83. // 订单发票信息
  84. func (s *OrderCenterServer) InvoiceInfo(ctx context.Context, in *pb.InvoiceInfoReq) (*pb.InvoiceInfoResp, error) {
  85. l := logic.NewInvoiceInfoLogic(ctx, s.svcCtx)
  86. return l.InvoiceInfo(in)
  87. }
  88. // 订单发票冲红
  89. func (s *OrderCenterServer) RedAdd(ctx context.Context, in *pb.InvoiceAddReq) (*pb.OrderAddUpdateResp, error) {
  90. l := logic.NewRedAddLogic(ctx, s.svcCtx)
  91. return l.RedAdd(in)
  92. }
  93. // 订单红票信息
  94. func (s *OrderCenterServer) RedInfo(ctx context.Context, in *pb.InvoiceInfoReq) (*pb.InvoiceInfoResp, error) {
  95. l := logic.NewRedInfoLogic(ctx, s.svcCtx)
  96. return l.RedInfo(in)
  97. }