mbdm

package
v0.15.98 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 17, 2023 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CancelOrder

func CancelOrder(orderID string, reason string) error

func Destroy

func Destroy()

func EstimatePrice

func EstimatePrice(startX float64, startY float64, endX float64, endY float64) (float64, float64, float64, error)

func GetTencentAddr

func GetTencentAddr(lng float64, lat float64) (string, error)

func Init

func Init(baseUrl string, timeoutSec time.Duration)

func PushOrder

func PushOrder(phone string, startAddr string, endAddr string, customerID string,
	customerName string, lat float64, lng float64) error

func PushOrderLocation

func PushOrderLocation(workID string, orderID string, longitude string, latitude string, sendTime string,
	servicePerName string, servicePerPhone string, data string) error

func PushOrderState

func PushOrderState(workID string, serviceCode string, servicePerName string, servicePerPhone string, state string,
	startTime string, endTime string, totalMoney string, totalKilometer string, totalTime string, orderID string, orderUrl string) error

Types

type CancelOrderRequest

type CancelOrderRequest struct {
	OrderID string `json:"orderId"`
	Reason  string `json:"reason"`
}

type EstimatePriceRequest

type EstimatePriceRequest struct {
	StartX float64 `json:"startX"`
	StartY float64 `json:"startY"`
	EndX   float64 `json:"endX"`
	EndY   float64 `json:"endY"`
}

type EstimatePriceResponse

type EstimatePriceResponse struct {
	Price   float64 `json:"price"`
	Mileage float64 `json:"mileage"`
	Minute  float64 `json:"minute"`
	// contains filtered or unexported fields
}

type GetOrdersQuery

type GetOrdersQuery struct {
	ID         string `form:"id"`
	CustomerID string `form:"customerId"`
	PageNo     int    `form:"pageNo"`
	PageSize   int    `form:"pageSize"`
}

type GetOrdersResponse

type GetOrdersResponse struct {
	Infos      []VeteranOrderInfo `json:"infos"`
	TotalCount int64              `json:"totalCount"`
	PageNo     int                `json:"pageNo"`
	// contains filtered or unexported fields
}

type GetPlatformOrderDetailQuery

type GetPlatformOrderDetailQuery struct {
	ID string `form:"id" binding:"required"`
}

type GetPlatformOrderDetailResponse

type GetPlatformOrderDetailResponse struct {
	Info *PlatformOrderInfo `json:"info"`
	// contains filtered or unexported fields
}

type GetTencentAddrResponse

type GetTencentAddrResponse struct {
	Address string `json:"address"`
	// contains filtered or unexported fields
}

type PlatformOrderInfo

type PlatformOrderInfo struct {
	OrderID         string `json:"orderId"`
	DriverName      string `json:"driverName"`
	DriverPhone     string `json:"driverPhone"`
	DriverNum       string `json:"driverNum"`
	DriverYear      string `json:"driverYear"`
	Star            string `json:"star"`
	State           string `json:"state"`
	From            string `json:"from"`
	To              string `json:"to"`
	Distance        string `json:"distance"`
	Duration        string `json:"duration"`
	Price           string `json:"price"`
	PlatformOrderID string `json:"platformOrderId"`
	Lng             string `json:"lng"`
	Lat             string `json:"lat"`
}

func GetPlatformOrderDetail

func GetPlatformOrderDetail(id string) (*PlatformOrderInfo, error)

type PushOrderLocationRequest

type PushOrderLocationRequest struct {
	WorkID          string `json:"workId"`
	OrderID         string `json:"orderId"`
	Longitude       string `json:"longitude"`
	Latitude        string `json:"latitude"`
	SendTime        string `json:"sendTime"`
	ServicePerName  string `json:"servicePerName"`
	ServicePerPhone string `json:"servicePerPhone"`
	Data            string `json:"data"`
}

type PushOrderRequest

type PushOrderRequest struct {
	Phone        string  `json:"phone"`
	StartAddr    string  `json:"startAddr"`
	EndAddr      string  `json:"endAddr"`
	CustomerID   string  `json:"customerId"`
	CustomerName string  `json:"customerName"`
	Lat          float64 `json:"lat"`
	Lng          float64 `json:"lng"`
}

type PushOrderStateRequest

type PushOrderStateRequest struct {
	WorkID          string `json:"workId"`
	ServiceCode     string `json:"serviceCode"`
	ServicePerName  string `json:"servicePerName"`
	ServicePerPhone string `json:"servicePerPhone"`
	State           string `json:"state"`
	StartTime       string `json:"startTime"`
	EndTime         string `json:"endTime"`
	TotalMoney      string `json:"totalMoney"`
	TotalKilometer  string `json:"totalKilometer"`
	TotalTime       string `json:"totalTime"`
	OrderID         string `json:"orderId"`
	OrderUrl        string `json:"orderUrl"`
}

type VeteranOrderInfo

type VeteranOrderInfo struct {
	ID              string  `json:"id"`
	Phone           string  `json:"phone"`
	StartAddr       string  `json:"startAddr"`
	EndAddr         string  `json:"endAddr"`
	Lat             float64 `json:"lat"`
	Lng             float64 `json:"lng"`
	VeteranOrderID  string  `json:"veteranOrderId"`
	State           int     `json:"state"`
	CustomerID      string  `json:"customerId"`
	CustomerName    string  `json:"customerName"`
	ServiceCode     string  `json:"serviceCode"`
	ServicePerName  string  `json:"servicePerName"`
	ServicePerPhone string  `json:"servicePerPhone"`
	DriverTimes     uint    `json:"driverTimes"`
	DriveAge        uint16  `json:"driveAge"`
	DriverStar      uint8   `json:"driverStar"`
	StartTime       string  `json:"startTime"`
	EndTime         string  `json:"endTime"`
	TotalMoney      float64 `json:"totalMoney"`
	TotalKilometer  float64 `json:"totalKilometer"`
	TotalTime       int     `json:"totalTime"`
}

func GetOrders

func GetOrders(id string, customerID string, pageNo int, pageSize int) ([]VeteranOrderInfo, int64, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL