package param_v1_0

import (
	"gd_management_gateway/params/param_base"
)

// 创建数据api订单
type ManagementCreateDataApiOrderReq struct {
	param_base.BasicParam
	MerchantId  int64 `json:"merchant_id" description:""`
	QueryTypeId int64 `json:"query_type_id"`
	ComboId     int64 `json:"combo_id" description:""`
}

type ManagementCreateDataApiOrderResp struct {
	param_base.SimpleResp
	OrderNo string `json:"order_no" description:""`
}

// 支付数据api订单
type ManagementPayDataApiOrderReq struct {
	param_base.BasicParam
	OrderNo string `json:"order_no" description:""`
}
type ManagementPayDataApiOrderResp struct {
	param_base.SimpleResp
}

// 取消数据api订单
type ManagementCancelDataApiOrderReq struct {
	param_base.BasicParam
	OrderNo string `json:"order_no" description:""`
}
type ManagementCancelDataApiOrderResp struct {
	param_base.SimpleResp
}

// 修改数据api订单价格
type ManagementChangeDataApiOrderPriceReq struct {
	param_base.BasicParam
	OrderNo string  `json:"order_no" description:""`
	Price   float64 `json:"price" description:""`
}

type ManagementChangeDataApiOrderPriceResp struct {
	param_base.SimpleResp
}

// 获取数据api订单信息
type MangementGetDataApiOrderInfoReq struct {
	param_base.BasicParam
	OrderNo string `json:"order_no" description:""`
}

type MangementGetDataApiOrderInfoResp struct {
	param_base.SimpleResp
	OrderInfo TGdDataApiOrder `json:"info"`
}

// 获取数据api订单列表
type ManagementGetDataApiOrderListReq struct {
	param_base.BasicParam
	MerchantId int64 `json:"merchant_id" description:""`
	PageNumber int   `json:"page_number" description:""`
}

type DataApiOrderItem struct {
	OrderNo      string  `json:"order_no" description:""`
	DataApiName  string  `json:"data_api_name" description""`
	QueryType    string  `json:"query_type" description:""`
	ComboType    string  `json:"combo_type" description:"套餐规格"`
	Price        float64 `json:"price" description:"订单价格"`
	Status       string  `json:"status" description:"订单状态"`
	AddOrderTime string  `json:"add_order_time" description:"下单时间"`
}

type ManagementGetDataApiOrderListResp struct {
	param_base.SimpleResp
	Total            int                `json:"total" description:""`
	PageSize         int                `json:"page_size" description:""`
	PageNumber       int                `json:"page_number" description:""`
	DataApiOrderItem []DataApiOrderItem `json:"data_api_order_item"`
}

// 创建h5订单
type ManagementCreateH5OrderReq struct {
	param_base.BasicParam
	MerchantId  int64  `json:"merchant_id"`
	H5ServiceId int64  `json:"h5_service_id"`
	ComboId     int64  `json:"h5_combo_id"`
	ThemeColor  string `json:"theme_color"`
}

type ManagementCreateH5OrderResp struct {
	param_base.SimpleResp
	OrderNo string `json:"order_no" description:""`
}

// 支付h5订单
type ManagementPayH5OrderReq struct {
	param_base.BasicParam
	OrderNo string `json:"order_no" description:""`
}
type ManagementPayH5OrderResp struct {
	param_base.SimpleResp
}

// 取消h5订单
type ManagementCancelH5OrderReq struct {
	param_base.BasicParam
	OrderNo string `json:"order_no" description:""`
}
type ManagementCancelH5OrderResp struct {
	param_base.SimpleResp
}

// 修改h5订单价格
type ManagementChangeH5OrderPriceReq struct {
	param_base.BasicParam
	OrderNo string  `json:"order_no" description:""`
	Price   float64 `json:"price" description:""`
}

type ManagementChangeH5OrderPriceResp struct {
	param_base.SimpleResp
}

// 获取h5订单信息
type MangementGetH5OrderInfoReq struct {
	param_base.BasicParam
	OrderNo string `json:"order_no" description:""`
}

type MangementGetH5OrderInfoResp struct {
	param_base.SimpleResp
	OrderInfo TGdH5ServiceOrder `json:"info"`
}

// 获取h5订单列表
type ManagementGetH5OrderListReq struct {
	param_base.BasicParam
	MerchantId int64 `json:"merchant_id" description:""`
	PageNumber int   `json:"page_number" description:""`
}

type H5OrderItem struct {
	MerchantH5ServiceId int64  `json:"merchant_h5_service_id"`
	H5ServiceId         int64  `json:"h5_service_id"`
	ComboType           int    `json:"combo_type" description:"套餐类型1 按总次数，2 按天"`
	TotalCount          int    `json:"total_count" description:""`
	RemainCount         int    `json:"remain_count" description:""`
	DayCount            int    `json:"day_count" description:""`
	DayRemainCount      int    `json:"day_remain_count" description:""`
	DayNumberCount      int    `json:"day_number_count" description:"天数上限"`
	DayNumberRemain     int    `json:"day_number_remain" description:"有效天数"`
	Status              string `json:"status" description:""`
	UseTime             string `json:"use_time" description:""`
	H5ServiceName       string `json:"h5_service_name"`
	State               string `json:"state"`
}

type ManagementGetH5OrderListResp struct {
	param_base.SimpleResp
	Total       int           `json:"total" description:""`
	PageSize    int           `json:"page_size" description:""`
	PageNumber  int           `json:"page_number" description:""`
	H5OrderItem []H5OrderItem `json:"h5_order_item"`
}
