Documentation ¶
Index ¶
Constants ¶
View Source
const ( MysqlDns = "%s:%s@tcp(%s:%d)/%s?charset=utf8mb4&parseTime=True&loc=Local" MongoUrl = "mongodb://%s:%d" )
database constant
View Source
const ( UserConfigFile = "./cmd/user/config.yaml" MerchantConfigFile = "./cmd/merchant/config.yaml" CartConfigFile = "./cmd/cart/config.yaml" ChatConfigFile = "./cmd/chat/config.yaml" CommentConfigFile = "./cmd/comment/config.yaml" PayConfigFile = "./cmd/pay/config.yaml" ProductConfigFile = "./cmd/product/config.yaml" OperateConfigFile = "./cmd/operate/config.yaml" OrderConfigFile = "./cmd/order/config.yaml" ApiConfigFile = "./cmd/api/config.yaml" )
config file constant
View Source
const ( NacosLogDir = "tmp/nacos/log" NacosCacheDir = "tmp/nacos/cache" NacosLogLevel = "debug" )
nacos constant
View Source
const ( TCP = "tcp" FreePortAddress = "localhost:0" )
net constant
View Source
const ( NacosSnowflakeNode = iota UserSnowflakeNode MerchantSnowflakeNode CartSnowflakeNode CommentSnowflakeNode ProductSnowflakeNode OrderSnowflakeNode PaySnowflakeNode ChatSnowflakeNode MinioSnowflakeNode )
snowflake node constant
View Source
const ( UserIdentity = "user" MerchantIdentity = "merchant" )
identity constant
View Source
const ( VerificationExpTime = time.Second * 600 CacheExpTime = time.Second * 1800 TokenExpiredAt = 43200 OrderExpTime = time.Second * 900 )
expire time constant
View Source
const ( CollectionUsers = "users" CollectionMerchants = "merchants" CollectionProducts = "products" )
mongodb collections constant
View Source
const ( IPFlagName = "ip" IPFlagValue = "0.0.0.0" IPFlagUsage = "address" PortFlagName = "port" PortFlagUsage = "port" )
ip and port constant
View Source
const ( ObjectAvatarType = "avatar" ObjectBackgroundType = "background" ObjectProductType = "product" )
object type constant
View Source
const ( AccountID = "accountID" AccountIdentity = "accountIdentity" )
app context key constant
View Source
const ( ApiGroup = "API_GROUP" UserGroup = "USER_GROUP" MerchantGroup = "MERCHANT_GROUP" OperateGroup = "OPERATE_GROUP" ProductGroup = "PRODUCT_GROUP" OrderGroup = "ORDER_GROUP" PayGroup = "PAY_GROUP" )
View Source
const ( StatusSuccess int8 = iota + 1 StatusWaitPay StatusCancel )
View Source
const (
AppId = "2021000122675958"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.