81 lines
2.4 KiB
Go
81 lines
2.4 KiB
Go
package model
|
|
|
|
import (
|
|
"errors"
|
|
|
|
"github.com/zeromicro/go-zero/core/stores/sqlx"
|
|
)
|
|
|
|
var ErrNotFound = sqlx.ErrNotFound
|
|
var ErrNoRowsUpdate = errors.New("update db no rows change")
|
|
|
|
var UserAuthTypeAppMobile string = "app_mobile" //平台内部
|
|
var UserAuthTypeAppWechat string = "app_wechat" //微信小程序
|
|
var UserAuthTypeH5Mobile string = "h5_mobile"
|
|
var UserAuthTypeWxMini string = "wx_mini"
|
|
var UserAuthTypeWxh5 string = "wx_h5"
|
|
var UserAuthTypeAgentDirect string = "agent_direct"
|
|
var UserAuthTypeAgentPromote string = "agent_promote"
|
|
var UserAuthTypeUUID string = "uuid"
|
|
|
|
var AgentDeductionTypeCost string = "cost"
|
|
var AgentDeductionTypePricing string = "pricing"
|
|
|
|
var AgentRewardsTypeDescendantPromotion string = "descendant_promotion"
|
|
var AgentRewardsTypeDescendantUpgradeVip string = "descendant_upgrade_vip"
|
|
var AgentRewardsTypeDescendantUpgradeSvip string = "descendant_upgrade_svip"
|
|
var AgentRewardsTypeDescendantStayActive string = "descendant_stay_active"
|
|
var AgentRewardsTypeDescendantNewActive string = "descendant_new_active"
|
|
var AgentRewardsTypeDescendantWithdraw string = "descendant_withdraw"
|
|
|
|
var AgentLeveNameNormal string = "normal"
|
|
var AgentLeveNameVIP string = "VIP"
|
|
var AgentLeveNameSVIP string = "SVIP"
|
|
|
|
const (
|
|
OrderStatusPending = "pending"
|
|
OrderStatusPaid = "paid"
|
|
OrderStatusFailed = "failed"
|
|
OrderStatusRefunding = "refunding"
|
|
OrderStatusRefunded = "refunded"
|
|
OrderStatusClosed = "closed"
|
|
)
|
|
const (
|
|
OrderRefundStatusPending = "pending"
|
|
OrderRefundStatusSuccess = "success"
|
|
OrderRefundStatusFailed = "failed"
|
|
OrderRefundStatusClosed = "closed"
|
|
)
|
|
const (
|
|
QueryStatePending = "pending"
|
|
QueryStateFailed = "failed"
|
|
QueryStateSuccess = "success"
|
|
QueryStateProcessing = "processing"
|
|
QueryStateCleaned = "cleaned"
|
|
)
|
|
|
|
const (
|
|
GrantTypeFace string = "face"
|
|
AuthorizationGrantTypeSms = "sms"
|
|
)
|
|
const (
|
|
AuthorizationStatusPending = "pending"
|
|
AuthorizationStatusSuccess = "success"
|
|
AuthorizationStatusFailed = "failed"
|
|
AuthorizationStatusExpired = "expired"
|
|
AuthorizationStatusRevoked = "revoked"
|
|
AuthorizationStatusRejected = "rejected"
|
|
)
|
|
|
|
const (
|
|
AuthorizationFaceStatusPending = "pending"
|
|
AuthorizationFaceStatusSuccess = "success"
|
|
AuthorizationFaceStatusFailed = "failed"
|
|
)
|
|
|
|
const (
|
|
AgentRealNameStatusPending = "pending"
|
|
AgentRealNameStatusApproved = "approved"
|
|
AgentRealNameStatusRejected = "rejected"
|
|
)
|