fix: use int64 for auth and recharge ids
This commit is contained in:
@@ -13,7 +13,7 @@ type LoginResponse struct {
|
||||
}
|
||||
|
||||
type User struct {
|
||||
ID string `json:"id"`
|
||||
ID int64 `json:"id"`
|
||||
Phone string `json:"phone"`
|
||||
Nickname string `json:"nickname"`
|
||||
Avatar string `json:"avatar"`
|
||||
|
||||
@@ -17,7 +17,7 @@ type LoginResponse struct {
|
||||
}
|
||||
|
||||
type User struct {
|
||||
ID string `json:"id"`
|
||||
ID int64 `json:"id"`
|
||||
Phone string `json:"phone"`
|
||||
Nickname string `json:"nickname"`
|
||||
Avatar string `json:"avatar"`
|
||||
|
||||
@@ -22,7 +22,7 @@ type Content struct{}
|
||||
// @Produce json
|
||||
// @Param keyword query string false "Search keyword"
|
||||
// @Param genre query string false "Genre"
|
||||
// @Param tenantId query string false "Filter by creator"
|
||||
// @Param tenantId query int64 false "Filter by creator"
|
||||
// @Param sort query string false "Sort order" Enums(latest, hot, price_asc)
|
||||
// @Param page query int false "Page number"
|
||||
// @Success 200 {object} requests.Pager{items=[]dto.ContentItem}
|
||||
|
||||
@@ -55,7 +55,7 @@ type RechargeResponse struct {
|
||||
// PayParams 支付参数(透传给前端)。
|
||||
PayParams string `json:"pay_params"`
|
||||
// OrderID 充值订单ID。
|
||||
OrderID string `json:"order_id"`
|
||||
OrderID int64 `json:"order_id"`
|
||||
}
|
||||
|
||||
type Order struct {
|
||||
|
||||
@@ -3,7 +3,6 @@ package services
|
||||
import (
|
||||
"context"
|
||||
"errors"
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
"quyun/v2/app/errorx"
|
||||
@@ -112,6 +111,6 @@ func (s *wallet) Recharge(
|
||||
// Mock Pay Params
|
||||
return &user_dto.RechargeResponse{
|
||||
PayParams: "mock_paid_success",
|
||||
OrderID: strconv.FormatInt(order.ID, 10),
|
||||
OrderID: order.ID,
|
||||
}, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user