Documentation
¶
Index ¶
- Constants
- Variables
- func Hash(uid int64, ip uint32) string
- type Apply
- type ApplyListResult
- type ApplySortID
- type ApplySortPlaytime
- type ApplyUserNotify
- type ApplyUserStat
- type Archives
- type CidInfo
- type Content
- type ContentSpecial
- type DM
- type IndexFilter
- type Pa
- type Page
- type Pager
- type Report
- type ReportAction
- type RptLog
- type RptMsg
- type RptSearch
- type RptSearchs
- type SearchReportAidResult
- type SearchReportResult
- type Subject
- type TransferHistory
- type TransferJob
- type UptSearchReport
- type User
- type UserFilterList
- type Video
Constants ¶
const ( AttrNo = int32(0) // 属性位为0 AttrYes = int32(1) // 属性位为1 AttrProtect = uint(0) // 保护弹幕 StateNormal = int32(0) // 普通状态 StateDelete = int32(1) // 删除状态 StateHide = int32(2) // 隐藏状态 StateBlock = int32(3) // 屏蔽状态 StateFilter = int32(4) // 过滤状态 StateMonitorBefore = int32(5) // 先审后发 StateMonitorAfter = int32(6) // 先发后审 StateSystemFilter = int32(7) // 敏感词过滤 StateReportDelete = int32(8) // 举报删除 StateAdminDelete = int32(9) // 弹幕管理删除 StateUserDelete = int32(10) // 用户删除 StateScriptDelete = int32(11) // 举报脚本删除 PoolNormal = int32(0) // 普通弹幕池 PoolSubtitle = int32(1) // 字幕弹幕池 PoolSpecial = int32(2) // 特殊弹幕池 NotFound = -1 )
All const variable used in dm2
const ( // up主操作 StatUpperInit = int8(0) // up主未处理 StatUpperIgnore = int8(1) // up主已忽略 StatUpperDelete = int8(2) // up主已删除 // 管理员操作 StatFirstInit = int8(0) // 待一审 StatFirstDelete = int8(1) // 一审删除 StatSecondInit = int8(2) // 待二审 StatSecondIgnore = int8(3) // 二审忽略 StatSecondDelete = int8(4) // 二审删除 StatFirstIgnore = int8(5) // 一审忽略 StatSecondAutoDelete = int8(6) // 二审脚本删除 // 处理结果通知 NoticeUnsend = int8(0) // 未通知用户 NoticeSend = int8(1) // 已通知用户 // 举报原因 ReportReasonProhibited = int8(1) // 违禁 ReportReasonPorn = int8(2) // 色情 ReportReasonFraud = int8(3) // 赌博诈骗 ReportReasonAttack = int8(4) // 人身攻击 ReportReasonPrivate = int8(5) // 隐私 ReportReasonAd = int8(6) // 广告 ReportReasonWar = int8(7) // 引战 ReportReasonSpoiler = int8(8) // 剧透 ReportReasonMeaningless = int8(9) // 刷屏 ReportReasonOther = int8(11) // 其他 ReportReasonTeenagers = int8(12) // 青少年不良信息 )
const var
const ( SubTypeVideo = int32(1) // 主题类型 SubStateOpen = int32(0) // 主题打开 SubStateClosed = int32(1) // 主题关闭 AttrSubGuest = uint(0) // 允许游客弹幕 AttrSubSpolier = uint(1) // 允许剧透弹幕 AttrSubMission = uint(2) // 允许活动弹幕 AttrSubAdvance = uint(3) // 允许高级弹幕 // StateProtect protected dm StateProtect = 2 )
All const variable used in dm subject
const ( TransferJobStatInit = int8(0) TransferJobStatFinished = int8(1) TransferJobStatFailed = int8(2) )
all variable used in dm transfer
const (
// ProtectApplyLimit protect apply limit
ProtectApplyLimit = 20
)
Variables ¶
var ( ReportReason = map[int8]string{ 1: "内容涉及违禁相关", 2: "内容涉及非法网站信息", 3: "内容涉及赌博诈骗信息", 4: "内容涉及人身攻击", 5: "内容涉及侵犯他人隐私", 6: "内容涉及垃圾广告", 7: "内容涉及引战", 8: "内容涉及视频剧透", 9: "恶意刷屏", 10: "视频不相关", 11: "其他", 12: "青少年不良信息", } RptMsgTitle = "举报处理结果通知" RptMsgTemplate = `` /* 199-byte string literal not displayed */ )
var const text
Functions ¶
Types ¶
type Apply ¶
type Apply struct { ID int64 `json:"id"` AID int64 `json:"aid"` CID int64 `json:"cid"` Title string `json:"title"` ApplyUID int64 `json:"-"` Pic string `json:"pic"` Uname string `json:"uname"` Msg string `json:"msg"` Playtime float32 `json:"playtime"` Ctime string `json:"ctime"` }
Apply apply protect dm
type ApplyListResult ¶
ApplyListResult get
type ApplySortPlaytime ¶
type ApplySortPlaytime []*Apply
ApplySortPlaytime what
func (ApplySortPlaytime) Len ¶
func (c ApplySortPlaytime) Len() int
func (ApplySortPlaytime) Less ¶
func (c ApplySortPlaytime) Less(i, j int) bool
func (ApplySortPlaytime) Swap ¶
func (c ApplySortPlaytime) Swap(i, j int)
type ApplyUserNotify ¶
ApplyUserNotify user notify
type ApplyUserStat ¶
ApplyUserStat user stat
type Archives ¶
type Archives struct { Result []*struct { Aid int64 `json:"aid"` Title string `json:"title"` } `json:"result"` }
Archives report archive list
type CidInfo ¶
type CidInfo struct { Aid int64 `json:"aid"` Title string `json:"title"` Desc string `json:"desc"` Filename string `json:"filename"` Index int `json:"index"` Status int16 `json:"status"` StatusDesc string `json:"status_desc"` FailCode int8 `json:"fail_code"` FailDesc string `json:"fail_desc"` CTime xtime.Time `json:"ctime"` }
CidInfo is archive_video model.
type Content ¶
type Content struct { ID int64 `json:"id"` FontSize int32 `json:"fontsize"` Color int64 `json:"color"` Mode int32 `json:"mode"` IP int64 `json:"ip"` Plat int32 `json:"plat"` Msg string `json:"msg"` Ctime time.Time `json:"ctime"` Mtime time.Time `json:"mtime"` }
Content dm_content
type ContentSpecial ¶
type ContentSpecial struct { ID int64 `json:"id"` Msg string `json:"msg"` Ctime time.Time `json:"ctime"` Mtime time.Time `json:"mtime"` }
ContentSpecial dm_content_special
type DM ¶
type DM struct { ID int64 `json:"id"` Type int32 `json:"type"` Oid int64 `json:"oid"` Mid int64 `json:"mid"` Progress int32 `json:"progress"` Pool int32 `json:"pool"` Attr int32 `json:"attr"` State int32 `json:"state"` Ctime time.Time `json:"ctime"` Mtime time.Time `json:"mtime"` Content *Content `json:"content,omitempty"` ContentSpe *ContentSpecial `json:"content_special,omitempty"` }
DM dm_index and dm_content
type IndexFilter ¶
type IndexFilter struct { ID int64 `json:"id"` CID int64 `json:"cid"` MID int64 `json:"mid"` Filter string `json:"filter"` Activate int8 `json:"activate"` Regex int8 `json:"type"` Ctime int64 `json:"ctime"` }
IndexFilter for dm_index_filter
type Pa ¶
type Pa struct { ID int64 CID int64 UID int64 ApplyUID int64 AID int64 Playtime float32 DMID int64 Msg string Status int Ctime time.Time Mtime time.Time }
Pa 保护弹幕
type Pager ¶
type Pager struct { Total int `json:"total"` Current int `json:"current"` Size int `json:"size"` TotalCount int `json:"total_count"` }
Pager comment
type Report ¶
type Report struct { ID int64 `json:"id"` // 主键id Cid int64 `json:"cid"` // 视频id Did int64 `json:"dmid"` // 弹幕id UID int64 `json:"uid"` // 举报用户的id Reason int8 `json:"reason"` // 举报原因类型 Content string `json:"content"` // 举报内容:reason为其它时有值 Count int64 `json:"count"` // 被举报次数 State int8 `json:"state"` // 举报状态 UpOP int8 `json:"up_op"` // up主操作 Score int32 `json:"score"` // 举报分 RpTime time.Time `json:"rp_time"` // 举报时间 Ctime time.Time `json:"ctime"` // 插入时间 Mtime time.Time `json:"mtime"` // 更新时间 }
Report dm report info
type ReportAction ¶
type ReportAction struct { Cid int64 `json:"cid"` // 视频id Did int64 `json:"dmid"` // 弹幕id HideTime int64 `json:"hide_time"` // 弹幕隐藏截止时间 }
ReportAction send dm info and hidetime
type RptLog ¶
type RptLog struct { ID int64 `json:"id"` Did int64 `json:"dmid"` AdminID int64 `json:"admin_id"` Reason int8 `json:"reason"` Result int8 `json:"result"` Remark string `json:"remark"` Elapsed int64 `json:"elapsed"` Ctime time.Time `json:"ctime"` Mtime time.Time `json:"mtime"` }
RptLog dm admin log
type RptSearch ¶
type RptSearch struct { ID int64 `json:"id"` Cid int64 `json:"cid"` // 视频的id Did int64 `json:"dmid"` // 弹幕id Aid int64 `json:"arc_aid"` // 稿件的id Tid int64 `json:"arc_typeid"` // 稿件的分区id Owner int64 `json:"dm_owner_uid"` // 弹幕发送者的uid Msg string `json:"dm_msg"` // 弹幕内容 Count int64 `json:"count"` // 被举报次数 Content string `json:"content"` // 举报内容:只有类别其他才有值 UpOP int8 `json:"up_op"` // up主操作状态 State int8 `json:"state"` // 举报状态 UID int64 `json:"uid"` // 举报用户id RpTime string `json:"rp_time"` // 举报时间 Reason int64 `json:"reason"` // 举报原因类型 Ctime string `json:"ctime"` // 插入时间 Mtime string `json:"mtime"` // 更新时间 Title string `json:"arc_title"` // 稿件标题 Deleted int64 `json:"dm_deleted"` // 弹幕状态 UPUid int64 `json:"arc_mid"` // up主id Cover string `json:"arc_cover"` // 稿件的封面图 }
RptSearch report info from search
type RptSearchs ¶
type RptSearchs struct { Page int64 `json:"page"` PageSize int64 `json:"pagesize"` PageCount int64 `json:"pagecount"` Total int64 `json:"total"` Result []*RptSearch `json:"result"` }
RptSearchs report list
type SearchReportAidResult ¶
type SearchReportAidResult struct { Page *Page `json:"page"` Result map[string][]struct { Key string `json:"key"` } `json:"result"` }
SearchReportAidResult dm repost archive list from search
type SearchReportResult ¶
SearchReportResult dm repost list from search
type Subject ¶
type Subject struct { ID int64 `json:"id"` Type int32 `json:"type"` Oid int64 `json:"oid"` Pid int64 `json:"pid"` Mid int64 `json:"mid"` State int32 `json:"state"` Attr int32 `json:"attr"` ACount int64 `json:"acount"` Count int64 `json:"count"` MCount int64 `json:"mcount"` MoveCnt int64 `json:"move_count"` Maxlimit int64 `json:"maxlimit"` Childpool int32 `json:"childpool"` Ctime time.Time `json:"ctime"` Mtime time.Time `json:"mtime"` }
Subject dm_subject
type TransferHistory ¶
type TransferHistory struct { ID int64 `json:"id"` PartID int32 `json:"part_id"` CID int64 `json:"cid"` Title string `json:"title"` CTime xtime.Time `json:"ctime"` State int8 `json:"state"` }
TransferHistory transfer list item
type TransferJob ¶
type TransferJob struct { ID int64 FromCID int64 ToCID int64 MID int64 Offset float64 State int8 Ctime time.Time Mtime time.Time }
TransferJob dm transfer
type UptSearchReport ¶
type UptSearchReport struct { DMid int64 `json:"dmid"` Upop int8 `json:"up_op"` Ctime string `json:"ctime"` Mtime string `json:"mtime"` }
UptSearchReport update search report
type User ¶
type User struct { ID int64 `json:"id"` Did int64 `json:"dmid"` UID int64 `json:"uid"` Reason int8 `json:"reason"` State int8 `json:"state"` Content string `json:"content"` Ctime time.Time `json:"ctime"` Mtime time.Time `json:"mtime"` }
User report user info
type UserFilterList ¶
type UserFilterList struct { Top int8 `json:"accept_top"` Bottom int8 `json:"accept_bottom"` Reverse int8 `json:"accept_reverse"` Filter []*IndexFilter `json:"filter_list"` }
UserFilterList for member filter list to show global filter or video filter