feat: add wechat pay
This commit is contained in:
@@ -15,6 +15,7 @@ type Medias struct {
|
||||
ID int64 `sql:"primary_key" json:"id"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
TenantID int64 `json:"tenant_id"`
|
||||
UserID int64 `json:"user_id"`
|
||||
PostID int64 `json:"post_id"`
|
||||
StorageID int64 `json:"storage_id"`
|
||||
|
||||
@@ -8,25 +8,26 @@
|
||||
package model
|
||||
|
||||
import (
|
||||
"backend/database/fields"
|
||||
"time"
|
||||
)
|
||||
|
||||
type Orders struct {
|
||||
ID int64 `sql:"primary_key" json:"id"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
DeletedAt *time.Time `json:"deleted_at"`
|
||||
TenantID int64 `json:"tenant_id"`
|
||||
UserID int64 `json:"user_id"`
|
||||
Type int16 `json:"type"`
|
||||
Status int16 `json:"status"`
|
||||
OrderSerial string `json:"order_serial"`
|
||||
RemoteOrderSerial string `json:"remote_order_serial"`
|
||||
RefundSerial string `json:"refund_serial"`
|
||||
RemoteRefundSerial string `json:"remote_refund_serial"`
|
||||
Amount int64 `json:"amount"`
|
||||
Currency string `json:"currency"`
|
||||
Title string `json:"title"`
|
||||
Description *string `json:"description"`
|
||||
Meta *string `json:"meta"`
|
||||
ID int64 `sql:"primary_key" json:"id"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
DeletedAt *time.Time `json:"deleted_at"`
|
||||
TenantID int64 `json:"tenant_id"`
|
||||
UserID int64 `json:"user_id"`
|
||||
Type fields.OrderType `json:"type"`
|
||||
Status fields.OrderStatus `json:"status"`
|
||||
OrderSerial string `json:"order_serial"`
|
||||
RemoteOrderSerial string `json:"remote_order_serial"`
|
||||
RefundSerial string `json:"refund_serial"`
|
||||
RemoteRefundSerial string `json:"remote_refund_serial"`
|
||||
Amount int64 `json:"amount"`
|
||||
Currency string `json:"currency"`
|
||||
Title string `json:"title"`
|
||||
Description *string `json:"description"`
|
||||
Meta fields.Json[fields.OrderMeta] `json:"meta"`
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ type Posts struct {
|
||||
DeletedAt *time.Time `json:"deleted_at"`
|
||||
TenantID int64 `json:"tenant_id"`
|
||||
UserID int64 `json:"user_id"`
|
||||
HashID string `json:"hash_id"`
|
||||
Hash string `json:"hash"`
|
||||
Title string `json:"title"`
|
||||
Description string `json:"description"`
|
||||
Poster string `json:"poster"`
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
//
|
||||
// Code generated by go-jet DO NOT EDIT.
|
||||
//
|
||||
// WARNING: Changes to this file may cause incorrect behavior
|
||||
// and will be lost if the code is regenerated
|
||||
//
|
||||
|
||||
package model
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
||||
type UserBoughtPosts struct {
|
||||
ID int64 `sql:"primary_key" json:"id"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
TenantID int64 `json:"tenant_id"`
|
||||
UserID int64 `json:"user_id"`
|
||||
PostID int64 `json:"post_id"`
|
||||
Price int64 `json:"price"`
|
||||
Discount int16 `json:"discount"`
|
||||
Meta *string `json:"meta"`
|
||||
}
|
||||
Reference in New Issue
Block a user