model

package
v0.0.0-...-83adff0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 6, 2020 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ArcTagStateNormal tag archive
	ArcTagStateNormal = 0

	// ArcTagLogAdd tag Log
	ArcTagLogAdd = int8(0)
	// ArcTagLogDel tag Log
	ArcTagLogDel = int8(1)
	// ArcTagLogOpen tag Log
	ArcTagLogOpen = int8(0)
	// ArcTagLogClose tag Log
	ArcTagLogClose = int8(1)

	// ArcTagAdd  operation type
	ArcTagAdd = int8(1)
	// ArcTagDel  operation type
	ArcTagDel = int8(2)
	// ArcTagLike  operation type
	ArcTagLike = int8(3)
	// ArcTagHate  operation type
	ArcTagHate = int8(4)
	// ArcTagRpt  operation type
	ArcTagRpt = int8(7)

	// LogAddReport log report
	LogAddReport = int8(8)
	// LogDelReport  archive log report
	LogDelReport = int8(9)

	// ArcTagOpRoleUp arc tag operation role
	ArcTagOpRoleUp = 0
	// ArcTagOpRoleUser  arc tag operation role
	ArcTagOpRoleUser = 1
	// ArcTagOpRoleAdmin  arc tag operation role
	ArcTagOpRoleAdmin = 2

	// ArcTagLockBit  arctaglock
	ArcTagLockBit = 0
	// ArcTagRptPass  arctaglock
	ArcTagRptPass = 1

	// LimitArcDelbit arc bit
	LimitArcDelbit = uint(0)
	// LimitArcAddbit  arc bit
	LimitArcAddbit = uint(1)

	// ActionStateOpen tag action
	ActionStateOpen = int8(0)
	// ActionStateClose  tag action
	ActionStateClose = int8(1)
	// ActionLikeIncr  tag action
	ActionLikeIncr = int8(1)
	// ActionLikedecr tag action
	ActionLikedecr = int8(-1)
	// ActionHateIncr  tag action
	ActionHateIncr = int8(1)
	// ActionHatedecr  tag action
	ActionHatedecr = int8(-1)
)
View Source
const (
	ChanStateOffline   = int32(0) //频道下线
	ChanStateStop      = int32(1) //频道停用
	ChanStateCommon    = int32(2) //频道普通
	ChanStateRecommend = int32(3) //频道推荐

	DiscoveryChannelNum = int32(3) //3个发现频道
	ResMaxNum           = int(50)  // 最多可支持一次50个查询稿件

	DefaultPageNum  = int(1)
	DefaultPageSize = int(20)

	BatchSize = int32(100)

	TagChannelNo  = int32(0) // tag是运营频道
	TagChannelYes = int32(1) // tag是运营频道

	ChannelCategoryStateOK  = int32(0)
	ChannelCategoryStateDel = int32(1)
	ChannelRuleStateOK      = int32(0)
	ChannelRuleStateDel     = int32(1)

	ChannelRuleFlagSingle = int32(1)
	ChannelRuleFlagPlus   = int32(2)
	ChannelRuleFlagMinus  = int32(3)

	AIRecommandChannel = int32(9)
	AIRecommandTag     = int32(54)
	NoneUserID         = int64(0)

	ChannelFromApp = int32(0) // 移动端频道详情页
	ChannelFromH5  = int32(1) // 频道H5页面

	StateChannelCheckOK   = int32(0)
	StateChannelChecking  = int32(1)
	StateChannelCheckNone = int32(2)

	StateResCheckBackNo  = int32(0)
	StateResCheckBackYes = int32(1)

	ChannelActivity      = int32(4)
	StateChannelActivity = int32(1)

	ManagerYes = int32(1)
	ManagerNo  = int32(0)

	ChannelFromINT               = int32(1) //频道来源于:国际版
	ChanStateINTField            = int32(1) //频道国际版本屏蔽
	ChannelCategoryStateINTField = int32(1) //频道分类国际版本屏蔽

	ChannelStateTop       = int32(1) //频道置顶位
	ChannelStateShieldINT = int32(1) // 频道海外屏蔽

	ChannelAttrCheckBack = uint(0) //回查频道位
	ChannelAttrTop       = uint(1) //置顶频道位
	ChannelAttrActivity  = uint(2) //活动频道位
	ChannelAttrINT       = uint(3) //频道海外版位

)

const const value.

View Source
const (
	// ArcListIsDelBit .
	ArcListIsDelBit = uint(0)
	// ArcListIsAddBit .
	ArcListIsAddBit = uint(1)
)
View Source
const (
	// ResTagStateNormal .
	ResTagStateNormal = int32(0)
	// ResTagStateDel .
	ResTagStateDel = int32(1)
	// ResTagStateHide .
	ResTagStateHide = int32(2)
	// ResTagStateRegion .
	ResTagStateRegion = int32(3)

	// ResTagAdd .
	ResTagAdd = int8(0)
	// ResTagDel .
	ResTagDel = int8(1)
)
View Source
const (
	// UpRole .
	UpRole = iota // up主角色
	// UserRole .
	UserRole // 普通用户
	// AdminRole .
	AdminRole // 管理员
)
View Source
const (
	// UserTag tag Type
	UserTag = int8(0) // 普通tag
	// UpTag tag Type
	UpTag = int8(1) // up主tag
	// OfficailClassifyTag tag Type
	OfficailClassifyTag = int8(2) // 官方-分类tag
	// OfficailContentTag tag Type
	OfficailContentTag = int8(3) // 官方-内容tag
	// OfficailActiveTag tag Type
	OfficailActiveTag = int8(4) // 官方-活动tag
)
View Source
const (
	SpamAdd    = int32(1)
	SpamDel    = int32(2)
	SpamLike   = int32(3)
	SpamHate   = int32(4)
	SpamReport = int32(5)

	SpamIncrValue = int32(1)
)

const value about spam action.

View Source
const (
	// SubStateNormal .
	SubStateNormal = 0 // SubState default
	// SubTagLoad arc sub operation type
	SubTagLoad = int8(0)
	// SubTagAdd .
	SubTagAdd = int8(1)
	// SubTagDel .
	SubTagDel = int8(2)

	// SortOrderDESC sort order desc.
	SortOrderDESC = int(-1)
	// SortOrderASC order asc.
	SortOrderASC = int(1)

	// SubTagMaxNum sub tag total number .
	SubTagMaxNum = 400
)
View Source
const (
	// EnvPro is pro.
	EnvPro = "pro"
	// EnvTest is env.
	EnvTest = "test"
	// EnvDev is env.
	EnvDev = "dev"
)
View Source
const (
	// TnameMaxLen tag name length .
	TnameMaxLen = 32
	// MaxTagNum max tag num.
	MaxTagNum = 50

	// MaxTopicSortNum .
	MaxTopicSortNum = 10
	// MaxChannelSortNum .
	MaxChannelSortNum = 400

	// TagStateNormal tag
	TagStateNormal = 0
	// TagStateDel .
	TagStateDel = 1
	// TagStateHide .
	TagStateHide = 2

	// RoleUp user role.
	RoleUp = 0
	// RoleUser user role.
	RoleUser = 1
	// RoleAdmin user role.
	RoleAdmin = 2

	// TagAdd tag operation type
	TagAdd = int8(1)
	// TagDel tag operation type
	TagDel = int8(2)

	// TotalScore .
	TotalScore = int8(100)

	// UserBannedNone .
	UserBannedNone = int32(0)
)
View Source
const (
	// WorkflowBusinessChannel channel business.
	WorkflowBusinessChannel = int32(9)
	WorkflowFIDChannel      = int32(2)
	WorkflowRIDChannel      = int32(1)

	AppealStatEffective = int32(1)
	AppealStateInvalid  = int32(2)
)

const const value.

View Source
const (
	// PicResType .
	PicResType = iota + 1 // 图文资源
)

Variables

View Source
var (
	ErrInvalidLengthProto = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowProto   = fmt.Errorf("proto: integer overflow")
)

Functions

This section is empty.

Types

type AIChannelRecommand

type AIChannelRecommand struct {
	Tid  int64  `json:"tid"`
	Oid  int64  `json:"id"`
	Type string `json:"goto"`
}

AIChannelRecommand AIChannelRecommand.

type ArcTag

type ArcTag struct {
	ID        int64     `json:"-"`
	Aid       int64     `json:"aid"`
	Mid       int64     `json:"mid"`
	Tid       int64     `json:"tag_id"`
	Likes     int64     `json:"likes"`
	Hates     int64     `json:"hates"`
	Attribute int8      `json:"attribute"`
	Role      int8      `json:"-"`
	State     int8      `json:"state"`
	CTime     time.Time `json:"ctime"`
	MTime     time.Time `json:"-"`
}

ArcTag archive_tag

func (*ArcTag) IsLock

func (at *ArcTag) IsLock() bool

IsLock .

type ArcTagAction

type ArcTagAction struct {
	ID     int64
	Aid    int64
	Tid    int64
	Mid    int64
	Action int8
	State  int8
}

ArcTagAction archive_tag_action

type ArcTagLog

type ArcTagLog struct {
	Lid    int64  `json:"id"`
	Aid    int64  `json:"aid"`
	Tid    int64  `json:"tag_id"`
	Tname  string `json:"tag_name"`
	Mid    int64  `json:"mid"`
	Face   string `json:"face"`
	UName  string `json:"uname"`
	Role   int8   `json:"role"`
	Action int8   `json:"action"`
	Remark string `json:"-"`
	Lstate int8   `json:"-"`
	// report info
	Rid      sql.NullInt64 `json:"-"`
	State    sql.NullInt64 `json:"-"` // report state
	IsDeal   int8          `json:"is_deal"`
	IsReport int8          `json:"is_report"`
	CTime    time.Time     `json:"ctime"`
	MTime    time.Time     `json:"-"`
}

ArcTagLog archive tag log

type ArgAddSub

type ArgAddSub struct {
	Mid    int64
	Tids   []int64
	Now    time.Time
	RealIP string
}

ArgAddSub .

type ArgAid

type ArgAid struct {
	Aid    int64
	Mid    int64
	RealIP string
}

ArgAid .

type ArgBind

type ArgBind struct {
	Oid    int64
	Mid    int64
	Type   int8
	Names  []string
	RealIP string
}

ArgBind .

type ArgCancelSub

type ArgCancelSub struct {
	Mid    int64
	Tid    int64
	Now    time.Time
	RealIP string
}

ArgCancelSub .

type ArgChanneList

type ArgChanneList struct {
	ID     int64
	Mid    int64
	From   int32
	RealIP string
}

ArgChanneList arg channel list.

type ArgChannelCategories

type ArgChannelCategories struct {
	From   int32
	RealIP string
}

ArgChannelCategories arg channel categories.

type ArgChannelResource

type ArgChannelResource struct {
	Tid        int64  `form:"tid"`
	Mid        int64  `form:"mid"`
	Plat       int32  `form:"plat"`
	LoginEvent int32  `form:"login_event"`
	RequestCNT int32  `form:"request_cnt"`
	DisplayID  int32  `form:"display_id"`
	From       int32  `form:"from"`
	Type       int32  `form:"type"`
	Build      int32  `form:"build"`
	Name       string `form:"tname"`
	Buvid      string `form:"buvid"`
	Channel    int32
	RealIP     string
}

ArgChannelResource ArgChannelResource.

type ArgCustomSort

type ArgCustomSort struct {
	Mid    int64
	Type   int
	Order  int
	Pn     int
	Ps     int
	RealIP string
}

ArgCustomSort .

type ArgDiscoverChanneList

type ArgDiscoverChanneList struct {
	Mid    int64
	From   int32
	RealIP string
}

ArgDiscoverChanneList .

type ArgID

type ArgID struct {
	ID     int64
	Mid    int64
	RealIP string
}

ArgID .

type ArgIDs

type ArgIDs struct {
	IDs    []int64
	Mid    int64
	RealIP string
}

ArgIDs .

type ArgName

type ArgName struct {
	Name   string
	Mid    int64
	RealIP string
}

ArgName .

type ArgNames

type ArgNames struct {
	Names  []string
	Mid    int64
	RealIP string
}

ArgNames .

type ArgRecommandChannel

type ArgRecommandChannel struct {
	Mid    int64
	From   int32
	RealIP string
}

ArgRecommandChannel .

type ArgResChannel

type ArgResChannel struct {
	Oids   []int64
	Type   int32
	Mng    int32
	Mid    int64
	RealIP string
}

ArgResChannel .

type ArgResChannelCheck

type ArgResChannelCheck struct {
	Oids   []int64
	Type   int32
	RealIP string
}

ArgResChannelCheck .

type ArgResTags

type ArgResTags struct {
	Oids   []int64
	Type   int8
	Mid    int64
	RealIP string
}

ArgResTags .

type ArgSub

type ArgSub struct {
	Mid    int64
	Vmid   int64
	Pn     int
	Ps     int
	Order  int
	RealIP string
}

ArgSub .

type ArgUpdateCustomSort

type ArgUpdateCustomSort struct {
	Tids   string
	Mid    int64
	Type   int
	RealIP string
}

ArgUpdateCustomSort .

type ArgUserAdd

type ArgUserAdd struct {
	Oid    int64
	Mid    int64
	Type   int8
	Name   string
	Role   int8
	RealIP string
}

ArgUserAdd .

type ArgUserDel

type ArgUserDel struct {
	Oid    int64
	Tid    int64
	Type   int8
	Mid    int64
	Role   int8
	RealIP string
}

ArgUserDel .

type Attention

type Attention struct {
	ID    int64     `json:"id"`
	Tid   int64     `json:"tag_id"`
	Mid   int64     `json:"mid"`
	State int8      `json:"state"`
	CTime time.Time `json:"ctime"`
	MTime time.Time `json:"-"`
}

Attention .

type BinocularRule

type BinocularRule struct {
	A int64
	B int64
}

BinocularRule BinocularRule.

type ChanRule

type ChanRule struct {
	Single      []int64          // a
	AllContains []*BinocularRule // a+b
	Contains    []*BinocularRule // a-b
}

ChanRule ChanRule.

type Channel

type Channel struct {
	ID                   int64                       `protobuf:"varint,1,opt,name=ID,proto3" json:"id"`
	Name                 string                      `protobuf:"bytes,2,opt,name=Name,proto3" json:"name"`
	Type                 int64                       `protobuf:"varint,3,opt,name=Type,proto3" json:"type"`
	Cover                string                      `protobuf:"bytes,4,opt,name=Cover,proto3" json:"cover"`
	Content              string                      `protobuf:"bytes,5,opt,name=Content,proto3" json:"content"`
	Bind                 int64                       `protobuf:"varint,6,opt,name=Bind,proto3" json:"bind"`
	Sub                  int64                       `protobuf:"varint,7,opt,name=Sub,proto3" json:"sub"`
	Attention            int32                       `protobuf:"varint,8,opt,name=Attention,proto3" json:"attention"`
	Rank                 int32                       `protobuf:"varint,9,opt,name=Rank,proto3" json:"rank"`
	Attr                 int32                       `protobuf:"varint,10,opt,name=Attr,proto3" json:"attr"`
	State                int32                       `protobuf:"varint,11,opt,name=State,proto3" json:"state"`
	CTime                go_common_library_time.Time `protobuf:"varint,12,opt,name=CTime,proto3,casttype=go-common/library/time.Time" json:"ctime"`
	MTime                go_common_library_time.Time `protobuf:"varint,13,opt,name=MTime,proto3,casttype=go-common/library/time.Time" json:"-"`
	TopRank              int32                       `protobuf:"varint,14,opt,name=TopRank,proto3" json:"-"`
	HeadCover            string                      `protobuf:"bytes,15,opt,name=head_cover,json=headCover,proto3" json:"head_cover"`
	ShortContent         string                      `protobuf:"bytes,16,opt,name=short_content,json=shortContent,proto3" json:"short_content"`
	XXX_NoUnkeyedLiteral struct{}                    `json:"-"`
	XXX_unrecognized     []byte                      `json:"-"`
	XXX_sizecache        int32                       `json:"-"`
}

func (*Channel) Attent

func (t *Channel) Attent() bool

Attent IsAttent is attent.

func (*Channel) AttrVal

func (t *Channel) AttrVal(bit uint) int32

AttrVal get attr flag.

func (*Channel) Descriptor

func (*Channel) Descriptor() ([]byte, []int)

func (*Channel) Marshal

func (m *Channel) Marshal() (dAtA []byte, err error)

func (*Channel) MarshalTo

func (m *Channel) MarshalTo(dAtA []byte) (int, error)

func (*Channel) ProtoMessage

func (*Channel) ProtoMessage()

func (*Channel) Recommend

func (t *Channel) Recommend() bool

Recommend IsRecommend is recommend.

func (*Channel) Reset

func (m *Channel) Reset()

func (*Channel) Size

func (m *Channel) Size() (n int)

func (*Channel) String

func (m *Channel) String() string

func (*Channel) Top

func (t *Channel) Top() bool

Top channel is top.

func (*Channel) Unmarshal

func (m *Channel) Unmarshal(dAtA []byte) error

func (*Channel) XXX_DiscardUnknown

func (m *Channel) XXX_DiscardUnknown()

func (*Channel) XXX_Marshal

func (m *Channel) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Channel) XXX_Merge

func (dst *Channel) XXX_Merge(src proto.Message)

func (*Channel) XXX_Size

func (m *Channel) XXX_Size() int

func (*Channel) XXX_Unmarshal

func (m *Channel) XXX_Unmarshal(b []byte) error

type ChannelCategory

type ChannelCategory struct {
	ID        int64     `json:"id"`
	Name      string    `json:"name"`
	State     int32     `json:"state"`
	Order     int32     `json:"-"`
	INTShield int32     `json:"int_shield"` // International Shield. 国际版是否屏蔽
	CTime     time.Time `json:"ctime"`
	MTime     time.Time `json:"-"`
}

ChannelCategory channel category.

type ChannelCategorySort

type ChannelCategorySort []*ChannelCategory

ChannelCategorySort .

func (ChannelCategorySort) Len

func (t ChannelCategorySort) Len() int

Len Len.

func (ChannelCategorySort) Less

func (t ChannelCategorySort) Less(i, j int) bool

Less Less.

func (ChannelCategorySort) Swap

func (t ChannelCategorySort) Swap(i, j int)

Swap Swap.

type ChannelDetail

type ChannelDetail struct {
	Tag     *TagInfo          `json:"tag"`
	Synonym []*ChannelSynonym `json:"synonyms"`
}

ChannelDetail channel detail.

type ChannelInfo

type ChannelInfo struct {
	Tid       int64    `json:"tid"`
	TName     string   `json:"tname"`
	HitRule   string   `json:"hit_rule"`
	HitTNames []string `json:"hit_tnames"`
	HitRules  []string `json:"hit_rules"`
}

ChannelInfo channel basic info.

type ChannelRecomendSort

type ChannelRecomendSort []*Channel

ChannelRecomendSort ChannelRecomendSort.

func (ChannelRecomendSort) Len

func (t ChannelRecomendSort) Len() int

Len Len.

func (ChannelRecomendSort) Less

func (t ChannelRecomendSort) Less(i, j int) bool

Less Less.

func (ChannelRecomendSort) Swap

func (t ChannelRecomendSort) Swap(i, j int)

Swap Swap.

type ChannelResource

type ChannelResource struct {
	Oids      []int64 `json:"resource"`
	Failover  bool    `json:"failover"`
	IsChannel bool    `json:"is_channel"`
	Pages     *Page   `json:"page"`
}

ChannelResource ChannelResource.

type ChannelRule

type ChannelRule struct {
	Tid      int64  `json:"tid"`
	TidA     int64  `json:"a_tid"`
	TidAName string `json:"a_tname"`
	TidB     int64  `json:"b_tid"`
	TidBName string `json:"b_tname"`
	Flag     int32  `json:"flag"`
}

ChannelRule channel rule.

func (*ChannelRule) HitRule

func (rule *ChannelRule) HitRule(tids []int64) bool

HitRule rule hit. TODO 更好的计算方式.

type ChannelRuleClassifier

type ChannelRuleClassifier struct {
	Single []*ChannelRule `json:"single"`
	Plus   []*ChannelRule `json:"plus"`
	Minus  []*ChannelRule `json:"minus"`
}

ChannelRuleClassifier channel rule classifier.

func (*ChannelRuleClassifier) RuleCALC

func (rc *ChannelRuleClassifier) RuleCALC(tids []int64, mng int32) (res []*ChannelRule)

RuleCALC rule calc. TODO 更好的计算方式.

type ChannelSort

type ChannelSort []*Channel

ChannelSort ChannelSort.

func (ChannelSort) Len

func (t ChannelSort) Len() int

Len Len.

func (ChannelSort) Less

func (t ChannelSort) Less(i, j int) bool

Less Less.

func (ChannelSort) Swap

func (t ChannelSort) Swap(i, j int)

Swap Swap.

type ChannelSquare

type ChannelSquare struct {
	Channels []*Channel        `json:"tags"`
	Oids     map[int64][]int64 `json:"oids"`
}

ChannelSquare channel square.

type ChannelSynonym

type ChannelSynonym struct {
	Id                   int64                       `protobuf:"varint,1,opt,name=id,proto3" json:"id"`
	Name                 string                      `protobuf:"bytes,2,opt,name=Name,proto3" json:"name"`
	Alias                string                      `protobuf:"bytes,3,opt,name=alias,proto3" json:"alias"`
	Rank                 string                      `protobuf:"bytes,4,opt,name=rank,proto3" json:"-"`
	CTime                go_common_library_time.Time `protobuf:"varint,5,opt,name=CTime,proto3,casttype=go-common/library/time.Time" json:"ctime"`
	MTime                go_common_library_time.Time `protobuf:"varint,6,opt,name=MTime,proto3,casttype=go-common/library/time.Time" json:"-"`
	XXX_NoUnkeyedLiteral struct{}                    `json:"-"`
	XXX_unrecognized     []byte                      `json:"-"`
	XXX_sizecache        int32                       `json:"-"`
}

func (*ChannelSynonym) Descriptor

func (*ChannelSynonym) Descriptor() ([]byte, []int)

func (*ChannelSynonym) Marshal

func (m *ChannelSynonym) Marshal() (dAtA []byte, err error)

func (*ChannelSynonym) MarshalTo

func (m *ChannelSynonym) MarshalTo(dAtA []byte) (int, error)

func (*ChannelSynonym) ProtoMessage

func (*ChannelSynonym) ProtoMessage()

func (*ChannelSynonym) Reset

func (m *ChannelSynonym) Reset()

func (*ChannelSynonym) Size

func (m *ChannelSynonym) Size() (n int)

func (*ChannelSynonym) String

func (m *ChannelSynonym) String() string

func (*ChannelSynonym) Unmarshal

func (m *ChannelSynonym) Unmarshal(dAtA []byte) error

func (*ChannelSynonym) XXX_DiscardUnknown

func (m *ChannelSynonym) XXX_DiscardUnknown()

func (*ChannelSynonym) XXX_Marshal

func (m *ChannelSynonym) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ChannelSynonym) XXX_Merge

func (dst *ChannelSynonym) XXX_Merge(src proto.Message)

func (*ChannelSynonym) XXX_Size

func (m *ChannelSynonym) XXX_Size() int

func (*ChannelSynonym) XXX_Unmarshal

func (m *ChannelSynonym) XXX_Unmarshal(b []byte) error

type ChannelSynonymSort

type ChannelSynonymSort []*ChannelSynonym

ChannelSynonymSort channel synonym sort by rank.

func (ChannelSynonymSort) Len

func (t ChannelSynonymSort) Len() int

Len Len.

func (ChannelSynonymSort) Less

func (t ChannelSynonymSort) Less(i, j int) bool

Less Less.

func (ChannelSynonymSort) Swap

func (t ChannelSynonymSort) Swap(i, j int)

Swap Swap.

type CustomSortChannel

type CustomSortChannel struct {
	Custom   []*TagInfo `json:"custom"`
	Standard []*TagInfo `json:"standard"`
	Total    int        `json:"total"`
}

CustomSortChannel CustomSortChannel.

type Detail

type Detail struct {
	Info    *Tag          `json:"info"`
	Similar []*SimilarTag `json:"similar"`
	News    struct {
		Count    int        `json:"count"`
		Archives []*api.Arc `json:"archives"`
	} `json:"news"`
}

Detail .

type Filter

type Filter struct {
	Level int    `json:"level"`
	Msg   string `json:"msg"`
}

Filter .

type HotTag

type HotTag struct {
	Rid       int64  `json:"-"`
	Tid       int64  `json:"tag_id"`
	Tname     string `json:"tag_name"`
	HighLight int64  `json:"highlight"`
	IsAtten   int8   `json:"is_atten"`
}

HotTag .

type HotTags

type HotTags struct {
	Rid  int64     `json:"rid"`
	Tags []*HotTag `json:"tags"`
}

HotTags .

type LimitArc

type LimitArc struct {
	ID     int64     `json:"id"`
	Aid    int64     `json:"aid"`
	UpName string    `json:"author"`
	IsAdd  int8      `json:"is_add"`
	IsDel  int8      `json:"is_del"`
	CTime  time.Time `json:"-"`
	MTime  time.Time `json:"-"`
}

LimitArc .

type Page

type Page struct {
	Page     int32 `json:"page"`
	PageSize int32 `json:"pagesize"`
	Total    int64 `json:"count"`
}

Page page.

type Report

type Report struct {
	ID         int64     `json:"id"`
	Aid        int64     `json:"aid"`
	Tid        int64     `json:"tag_id"`
	OpMid      int64     `json:"opmid"`
	Action     int8      `json:"type"`
	ParentID   int64     `json:"-"`
	PartID     int16     `json:"part_id"`
	Reason     int8      `json:"reason"`
	IsDelMoral int8      `json:"is_del_moral"`
	State      int8      `json:"state"`
	CTime      time.Time `json:"_"`
	MTime      time.Time `json:"-"`
	RptMid     int64     `json:"rptmid"`
	IsFirst    int64     `json:"is_first"`
}

Report .

type ReqChannelDetail

type ReqChannelDetail struct {
	Mid    int64  `form:"mid"`
	Tid    int64  `form:"tid"`
	TName  string `form:"tname"`
	From   int32  `form:"from" validate:"required,gte=0"`
	RealIP string
}

ReqChannelDetail req channel detail.

type ReqChannelResourceInfos

type ReqChannelResourceInfos struct {
	Oids []int64 `form:"oids,split" validate:"required,min=1,max=50,dive,gt=0"`
	Tids []int64 `form:"eids,split" validate:"required,min=1,max=50,dive,gt=0"`
	IDs  []int64 `form:"ids,split" validate:"required,min=1,max=50,dive,gt=0"`
	Bid  int32   `form:"bid" validate:"required,gt=0"`
}

ReqChannelResourceInfos request channel resource infos.

type ReqChannelSquare

type ReqChannelSquare struct {
	Mid        int64  `form:"mid"`
	TagNumber  int32  `form:"tag_number" validate:"required,gt=0"`
	OidNumber  int32  `form:"oid_number"`
	Type       int32  `form:"type" validate:"required,gt=0"`
	Buvid      string `form:"buvid"`
	Build      int32  `form:"build"`
	LoginEvent int32  `form:"login_event"`
	DisplayID  int32  `form:"display_id"`
	Plat       int32  `form:"plat" validate:"required,gte=0,lte=8"`
	From       int32  `form:"from" validate:"required,gte=0"`
	RealIP     string
}

ReqChannelSquare request channel square.

type ReqTagTop

type ReqTagTop struct {
	Tid    int64
	TName  string
	Mid    int64
	RealIP string
}

ReqTagTop request tag top arg.

type ResChannelCheckBack

type ResChannelCheckBack struct {
	Tids      []int64                `json:"tids"`
	Channels  map[int64]*ChannelInfo `json:"channels"`
	CheckBack int32                  `json:"check_back"`
}

ResChannelCheckBack ResChannelCheckBack.

type ResTag

type ResTag struct {
	ID    int64     `json:"id"`
	Oid   int64     `json:"oid"`
	Tid   int64     `json:"tag_id"`
	Type  int8      `json:"type"`
	Mid   int64     `json:"mid"`
	Likes int64     `json:"likes"`
	Hates int64     `json:"hates"`
	Attr  int8      `json:"attribute"`
	Role  int8      `json:"-"`
	State int8      `json:"state"`
	CTime time.Time `json:"ctime"`
	MTime time.Time `json:"-"`
}

ResTag .

type ResTagLog

type ResTagLog struct {
	ID     int64     `json:"id"`
	Oid    int64     `json:"oid"`
	Tid    int64     `json:"tag_id"`
	Type   int8      `json:"type"`
	Tname  string    `json:"tag_name"`
	Mid    int64     `json:"mid"`
	Role   int8      `json:"role"`
	Reason string    `json:"reason"`
	Action int8      `json:"action"`
	State  int8      `json:"state"`
	CTime  time.Time `json:"ctime"`
	MTime  time.Time `json:"-"`
}

ResTagLog .

type ResourceChannel

type ResourceChannel struct {
	Channel []*Channel `json:"channel"`
	Tags    []*Channel `json:"tag"`
}

ResourceChannel resource channels.

type SimilarTag

type SimilarTag struct {
	Rid    int64  `json:"rid"`
	Rname  string `json:"rname"`
	Tid    int64  `json:"tid"`
	TCover string `json:"cover"`
	Tatten int    `json:"atten"`
	Tname  string `json:"tname"`
}

SimilarTag .

type Sub

type Sub struct {
	Tags  []*Tag `json:"tags"`
	Total int    `json:"total"`
}

Sub .

type SubArcs

type SubArcs struct {
	Tag  *Tag    `json:"tag"`
	Aids []int64 `json:"aids"`
}

SubArcs .

type Synonym

type Synonym struct {
	Parent int64   `json:"parent"`
	Childs []int64 `json:"childs"`
}

Synonym .

type Tag

type Tag struct {
	ID           int64      `json:"tag_id"`
	Name         string     `json:"tag_name"`
	Cover        string     `json:"cover"`
	HeadCover    string     `json:"head_cover"`
	Content      string     `json:"content"`
	ShortContent string     `json:"short_content"`
	Type         int8       `json:"type"`
	State        int8       `json:"state"`
	CTime        xtime.Time `json:"ctime"`
	MTime        xtime.Time `json:"-"`
	// tag count
	Count struct {
		View  int `json:"view"`
		Use   int `json:"use"`
		Atten int `json:"atten"`
	} `json:"count"`
	// subscriber
	IsAtten int8 `json:"is_atten"`
	// archive_tag
	Role      int8  `json:"-"`
	Likes     int64 `json:"likes"`
	Hates     int64 `json:"hates"`
	Attribute int8  `json:"attribute"`
	Liked     int8  `json:"liked"`
	Hated     int8  `json:"hated"`
}

Tag .

type TagInfo

type TagInfo struct {
	ID           int64     `json:"id"`
	Type         int32     `json:"type"`
	Name         string    `json:"name"`
	Cover        string    `json:"cover"`
	HeadCover    string    `json:"head_cover"`
	Content      string    `json:"content"`
	ShortContent string    `json:"short_content"`
	Verify       int32     `json:"-"`
	Attr         int32     `json:"-"`
	Attention    int32     `json:"attention"`
	State        int32     `json:"-"`
	Bind         int64     `json:"bind,omitempty"`
	Sub          int64     `json:"sub,omitempty"`
	Activity     int32     `json:"activity"`
	INTShield    int32     `json:"int_shield"` // International Shield. 国际版是否屏蔽
	CTime        time.Time `json:"ctime"`
	MTime        time.Time `json:"-"`
}

TagInfo TagInfo.

type TagTop

type TagTop struct {
	Tag      *Tag          `json:"tag"`
	Similars []*SimilarTag `json:"similars"`
}

TagTop web-interface tag top struct, include tag info, and similar tags.

type Tags

type Tags []*Tag

Tags .

func (Tags) Len

func (t Tags) Len() int

func (Tags) Less

func (t Tags) Less(i, j int) bool

func (Tags) Swap

func (t Tags) Swap(i, j int)

type UploadTag

type UploadTag struct {
	Rid        int64  `json:"rid"`
	Tid        int64  `json:"tid"`
	Tname      string `json:"tname"`
	Rank       int64  `json:"rank"`
	IsBusiness int8   `json:"-"`
}

UploadTag .

type WorkflowAppeal

type WorkflowAppeal struct {
	Eid      int64 `json:"eid"` // channel id.
	Mid      int64 `json:"mid"`
	Oid      int64 `json:"oid"`
	Business int32 `json:"business"`
}

WorkflowAppeal workflow appeal.

type WorkflowAppealInfo

type WorkflowAppealInfo struct {
	Business int32  `json:"business"`
	FID      int32  `json:"fid"`
	RID      int32  `json:"rid"`
	EID      int64  `json:"eid"`
	Score    int8   `json:"score"`
	ReasonID int8   `json:"tid"`
	Oid      int64  `json:"oid"`
	RptMid   int64  `json:"mid"`
	RegionID int32  `json:"business_typeid"`
	Mid      int64  `json:"business_mid"`
	TName    string `json:"business_title"`
	RealIP   string `json:"ip"`
}

WorkflowAppealInfo WorkflowAppealInfo.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL