Create & Init Project...

This commit is contained in:
2019-04-22 18:49:16 +08:00
commit fc4fa37393
25440 changed files with 4054998 additions and 0 deletions

View File

@@ -0,0 +1,33 @@
package(default_visibility = ["//visibility:public"])
load(
"@io_bazel_rules_go//go:def.bzl",
"go_library",
)
go_library(
name = "go_default_library",
srcs = [
"livewallet.go",
"model.go",
"paycenter.go",
"userext.go",
],
importpath = "go-common/app/interface/live/app-room/model",
tags = ["automanaged"],
visibility = ["//visibility:public"],
)
filegroup(
name = "package-srcs",
srcs = glob(["**"]),
tags = ["automanaged"],
visibility = ["//visibility:private"],
)
filegroup(
name = "all-srcs",
srcs = [":package-srcs"],
tags = ["automanaged"],
visibility = ["//visibility:public"],
)

View File

@@ -0,0 +1,10 @@
package model
//LiveWallet 直播钱包数据
type LiveWallet struct {
Gold int64 `json:"gold"`
Silver int64 `json:"silver"`
GoldRechargeCnt int64 `json:"gold_recharge_cnt"`
GoldPayCnt int64 `json:"gold_pay_cnt"`
SilverPayCnt int64 `json:"silver_pay_cnt"`
}

View File

@@ -0,0 +1,22 @@
package model
//History 存档信息
type History struct {
Text string `json:"text"`
NickName string `json:"nickname"`
UID int64 `json:"uid"`
UnameColor string `json:"uname_color"`
TimeLine string `json:"timeline"`
Isadmin int32 `json:"isadmin"`
Vip int `json:"vip"`
SVip int `json:"svip"`
Medal []interface{} `json:"medal"`
Title []interface{} `json:"title"`
UserLevel []interface{} `json:"user_level"`
Rank int32 `json:"rank"`
Teamid int64 `json:"teamid"`
RND string `json:"rnd"`
UserTitle string `json:"user_title"`
GuardLevel int `json:"guard_level"`
Bubble int64 `json:"bubble"`
}

View File

@@ -0,0 +1,10 @@
package model
// Wallet struct.
type Wallet struct {
Mid int64 `json:"mid"`
BcoinBalance float32 `json:"bcoin_balance"`
CouponBalance float32 `json:"coupon_balance"`
DefaultBp float32 `json:"default_bp"`
IosBp float32 `json:"ios_bp"`
}

View File

@@ -0,0 +1,24 @@
package model
//ConfValues 配置
type ConfValues map[int64]string
const (
// Empty 空
Empty = ""
// Set 存在
Set = "1"
// GoldTarget 金瓜子
GoldTarget = 1010
// SilverTarget 银瓜子
SilverTarget = 1011
)
// IsSet 是否存在
func (vs ConfValues) IsSet(key int64) bool {
v, ok := vs[key]
if !ok {
return false
}
return v == Set
}