Documentation ¶
Index ¶
- Constants
- Variables
- func NormalState(state int8) bool
- type AdInfo
- type Addit
- type Ancestor
- type Archive
- type Attr
- type AuditParam
- type BlogCard
- type Cover
- type Databus
- type Delay
- type Ext
- type ForbidAttr
- type History
- type Location
- type PoiObj
- type Result
- type Staff
- type StaffItem
- type Type
- type Video
- type Vote
- type VoteOld
Constants ¶
View Source
const ( UpFromPGC = 1 UpFromPGCSecret = 5 UpFromCoopera = 6 )
UpFromPGC 生产组, UpFromPGCSecret 机密生产组, UpFromCoopera 企业
View Source
const ( // StateOpen 开发浏览 StateOpen = int8(0) // StateOrange 橙色通过 StateOrange = int8(1) // StateForbidWait 待审 StateForbidWait = int8(-1) // StateForbidRecicle 打回 StateForbidRecicle = int8(-2) // StateForbidPolice 网警锁定 StateForbidPolice = int8(-3) // StateForbidLock 被锁定 StateForbidLock = int8(-4) // StateForbidFackLock 管理员锁定(可浏览) StateForbidFackLock = int8(-5) // StateForbidFixed 修复待审 StateForbidFixed = int8(-6) // StateForbidLater 暂缓审核 StateForbidLater = int8(-7) // StateForbidPatched 补档待审 StateForbidPatched = int8(-8) // StateForbidWaitXcode 等待转码 StateForbidWaitXcode = int8(-9) // StateForbidAdminDelay 延迟审核 StateForbidAdminDelay = int8(-10) // StateForbidFixing 视频源待修 StateForbidFixing = int8(-11) // StateForbidStorageFail 转储失败 StateForbidStorageFail = int8(-12) // StateForbidOnlyComment 允许评论待审 StateForbidOnlyComment = int8(-13) // StateForbidTmpRecicle 临时回收站 StateForbidTmpRecicle = int8(-14) // StateForbidDispatch 分发中 StateForbidDispatch = int8(-15) // StateForbidXcodeFail 转码失败 StateForbidXcodeFail = int8(-16) // StateForbidSubmit 创建已提交 StateForbidSubmit = int8(-30) // StateForbidUserDelay 定时发布 StateForbidUserDelay = int8(-40) // StateForbidUpDelete 用户删除 StateForbidUpDelete = int8(-100) // RoundBegin 一审阶段 RoundBegin = int8(0) // RoundAuditSecond 二审:选定分区的多P稿件 及 PGC/活动的单P多P稿件 RoundAuditSecond = int8(10) // RoundAuditThird 三审:选定分区/PGC/活动 的单P多P稿件 RoundAuditThird = int8(20) // RoundReviewFlow 私单回查:私单ID大于0 RoundReviewFlow = int8(21) //RoundAuditUGCPayFlow 付费待审 RoundAuditUGCPayFlow = int8(24) // RoundReviewFirst 分区回查:粉丝小于配置阈值 如 5000 且 指定分区 RoundReviewFirst = int8(30) // RoundReviewFirstWaitTrigger 点击/粉丝 等待触发中间状态,7天内达到阈值进列表,未达到自动变99 RoundReviewFirstWaitTrigger = int8(31) // RoundReviewSecond 社区回查:粉丝大于配置阈值 如 5000 或 优质高危up RoundReviewSecond = int8(40) // RoundTriggerFans 粉丝回查:粉丝量达到配置阈值 RoundTriggerFans = int8(80) // RoundTriggerClick 点击回查:点击量达到配置阈值 RoundTriggerClick = int8(90) // RoundEnd 结束 RoundEnd = int8(99) // AccessDefault 非会员可见 AccessDefault = int16(0) // AccessMember 会员可见 AccessMember = int16(10000) // CopyrightUnknow 未知版权类型 CopyrightUnknow = int8(0) // CopyrightOriginal 原创 CopyrightOriginal = int8(1) // CopyrightCopy 转载 CopyrightCopy = int8(2) // AttrYes attribute yes AttrYes = int32(1) // AttrNo attribute no AttrNo = int32(0) // AttrBitNoRank 禁止排行 AttrBitNoRank = uint(0) // AttrBitNoDynamic 动态禁止 AttrBitNoDynamic = uint(1) // AttrBitNoWeb 禁止网页输出 AttrBitNoWeb = uint(2) // AttrBitNoMobile 禁止客户端列表 AttrBitNoMobile = uint(3) // AttrBitNoSearch 搜索禁止 AttrBitNoSearch = uint(4) // AttrBitOverseaLock 海外禁止 AttrBitOverseaLock = uint(5) // AttrBitNoRecommend 禁止推荐 AttrBitNoRecommend = uint(6) // AttrBitNoReprint 禁止转载 AttrBitNoReprint = uint(7) // AttrBitHasHD5 是否高清 AttrBitHasHD5 = uint(8) // AttrBitIsPGC 是否PGC稿件 AttrBitIsPGC = uint(9) // AttrBitAllowBp 允许承包 AttrBitAllowBp = uint(10) // AttrBitIsBangumi 是否番剧 AttrBitIsBangumi = uint(11) // AttrBitIsPorder 是否私单 AttrBitIsPorder = uint(12) // AttrBitLimitArea 是否限制地区 AttrBitLimitArea = uint(13) // AttrBitAllowTag 允许其他人添加tag AttrBitAllowTag = uint(14) // AttrBitIsFromArcAPI useless AttrBitIsFromArcAPI = uint(15) // AttrBitJumpURL 跳转 AttrBitJumpURL = uint(16) // AttrBitIsMovie 是否影视 AttrBitIsMovie = uint(17) // AttrBitBadgepay 付费 AttrBitBadgepay = uint(18) //AttrNoPushBplus 禁止Bplus动态 AttrNoPushBplus = uint(20) //AttrParentMode 家长模式 AttrBitParentMode = uint(21) //AttrUGCPay UGC付费 AttrBitUGCPay = uint(22) //AttrBitSTAFF 联合投稿 AttrBitSTAFF = uint(24) STATESTAFFON = int8(1) STATESTAFFOFF = int8(2) )
View Source
const ( ConfForClick = "round_limit_fans" ConfForRoundType = "round_limit_tids" ConfForRoundEnd = "round_delay_time" ConfForAuditType = "wait_audit_arctype" ConfForThreshold = "threshold_arctype" ConfForWeightValue = "weight_conf_values" )
archive_config name list
View Source
const ( DelayTypeForAdmin = int8(1) DelayTypeForUser = int8(2) )
定时发布类型
View Source
const ( ForbidRank = "rank" ForbidDynamic = "dynamic" ForbidRecommend = "recommend" ForbidShow = "show" ForbidRankMain = 0 ForbidRankRecentArc = 1 ForbidRankAllArc = 2 ForbidDynamicMain = 0 ForbidRecommendMain = 0 ForbidShowMain = 0 ForbidShowMobile = 1 ForbidShowWeb = 2 ForbidShowOversea = 3 ForbidShowOnline = 4 )
稿件禁止项目
View Source
const ( FirstRoundID = int64(1) ZeroID = int64(0) )
archive_oper last_id
View Source
const ( // PoolForFirst 一审 PoolForFirst = int8(0) // PoolForSecond 二审 PoolForSecond = int8(1) // SubjectForNormal 普通任务 SubjectForNormal = int8(0) // SubjectForTask 指派任务 SubjectForTask = int8(1) // StateForTaskDefault 初始化状态(未认领) StateForTaskDefault = int8(0) // StateForTaskWork 已认领,未处理 StateForTaskWork = int8(1) // StateForTaskDelay 延迟审核 StateForTaskDelay = int8(3) // StateForTaskUserDeleted 被释放 StateForTaskUserDeleted = int8(6) )
View Source
const ( // Donghua 动画 Donghua = int16(1) // Music 音乐 Music = int16(3) // Game 游戏 Game = int16(4) // Ent 娱乐 Ent = int16(5) // Tv 电视剧 Tv = int16(11) // Bangumi 番剧 Bangumi = int16(13) // Movie 电影 Movie = int16(23) // Tech 科技 Tech = int16(36) // Kichiku 鬼畜 Kichiku = int16(119) // Dance 舞蹈 Dance = int16(129) // Fashion 时尚 Fashion = int16(155) // Life 生活 Life = int16(160) // Ad 广告 Ad = int16(165) // Guochuang 国创 Guochuang = int16(167) // Filmwithtele 影视 Filmwithtele = int16(181) // Documentary 纪录片 Documentary = int16(177) )
View Source
const ( // VideoUploadInfo 视频上传完成 VideoUploadInfo = int8(0) // VideoXcodeSDFail 视频转码失败 VideoXcodeSDFail = int8(1) // VideoXcodeSDFinish 一转完成 VideoXcodeSDFinish = int8(2) // VideoXcodeHDFail 二转失败 VideoXcodeHDFail = int8(3) // VideoXcodeHDFinish 二转完成 VideoXcodeHDFinish = int8(4) // VideoDispatchRunning 正在分发 VideoDispatchRunning = int8(5) // VideoDispatchFinish 分发完成 VideoDispatchFinish = int8(6) // VideoStatusOpen 视频开放浏览 VideoStatusOpen = int16(0) // VideoStatusAccess 视频会员可见 VideoStatusAccess = int16(10000) // VideoStatusWait 视频待审 VideoStatusWait = int16(-1) // VideoStatusRecicle 视频被打回 VideoStatusRecicle = int16(-2) // VideoStatusLock 视频被锁定 VideoStatusLock = int16(-4) // VideoStatusXcodeFail 视频转码失败 VideoStatusXcodeFail = int16(-16) // VideoStatusSubmit 视频创建已提交 VideoStatusSubmit = int16(-30) // VideoStatusDelete 视频被删除 VideoStatusDelete = int16(-100) // XcodeFailZero 转码失败 XcodeFailZero = 0 // SrcTypeForVupload 合作方嵌套 SrcTypeForVupload = "vupload" // SrcTypeForQQ 腾讯视频 SrcTypeForQQ = "qq" // SrcTypeForHunan 湖南 SrcTypeForHunan = "hunan" // SrcTypeForSohu 搜狐 SrcTypeForSohu = "sohu" )
View Source
const (
BIZPOI = int64(1)
)
View Source
const (
BIZVote = int64(2)
)
Variables ¶
View Source
var ( // XcodeFailCodes is bvc message mapping int value. //http://git.bilibili.co/bili_xcode/bili_xcode_docs/blob/master/%E7%B3%BB%E7%BB%9F%E6%95%B0%E6%8D%AE/%E8%BD%AC%E7%A0%81%E9%94%99%E8%AF%AF%E5%8E%9F%E5%9B%A0.md XcodeFailCodes = map[string]int8{ "FileDataUnrecognized": 1, "VideoTrackAbsent": 2, "AudioTrackAbsent": 3, "VideoTrackEmpty": 4, "AudioTrackEmpty": 5, "DurationOverflow": 6, "VideoTooNarrow": 7, "VideoTooFlat": 8, "DataCorrupted": 9, "WatermarkDownloadFail": 10, "DurationUnderflow": 11, "StreamDataCorrupted": 12, "IncorrectDataPackaging": 13, "UntolerableTimestampJump": 14, "UntolerableTimestampStretch": 15, "AACDataCorrupted": 16, } // XcodeFailMsgs is int value mapping comment. XcodeFailMsgs = map[int8]string{ 1: "文件格式错误,请检查是否上传了错误文件并尝试重新上传", 2: "无视频轨,请补充视频轨并重新压制上传", 3: "无音频轨,请补充音频轨并重新压制上传", 4: "视频轨无有效内容,请补充缺失的视频数据重新压制上传", 5: "音频轨无有效内容,请补充缺失的音频数据重新压制上传", 6: "单个视频时长超过10小时,请剪辑后通过分P上传", 7: "视频画面过窄,请纵向裁剪视频后重新上传", 8: "视频画面过扁,请横向裁剪视频后重新上传", 9: "视频数据有误,请重新编码后重新上传", 10: "水印图片损坏", 11: "单个视频时长不足1秒,请检查视频时长并尝试重新上传", 12: "文件编码数据错误", 13: "文件封包数据错误,请重新压制后上传", 14: "视频时间戳有异常,请修正后重新压制上传", 15: "视频时间戳有异常,请检查音视频数据并重新压制上传", 16: "AAC音频数据错误,请重新使用AAC编码后上传", } )
Functions ¶
Types ¶
type AdInfo ¶
type AdInfo struct { Nation string `json:"nation"` Provin string `json:"province"` Distri string `json:"district"` City string `json:"city"` }
AdInfo str
type Addit ¶
type Addit struct { ID int64 Aid int64 Source string RedirectURL string MissionID int64 UpFrom int8 OrderID int Dynamic string }
Addit id,aid,source,redirect_url,dynamic
type Archive ¶
type Archive struct { Aid int64 `json:"aid"` Mid int64 `json:"mid"` TypeID int16 `json:"tid"` Title string `json:"title"` Author string `json:"author"` Cover string `json:"cover"` Tag string `json:"tag"` Duration int64 `json:"duration"` Copyright int8 `json:"copyright"` Desc string `json:"desc"` Round int8 `json:"round"` Forward int64 `json:"forward"` Attribute int32 `json:"attribute"` HumanRank int `json:"humanrank"` Access int16 `json:"access"` State int8 `json:"state"` Reason string `json:"reject_reason"` PTime xtime.Time `json:"ptime"` CTime xtime.Time `json:"ctime"` MTime xtime.Time `json:"mtime"` }
Archive is archive model.
func (*Archive) NotAllowUp ¶
NotAllowUp check archive is or not allow update state.
type BlogCard ¶
type BlogCard struct { Type int64 `json:"type"` //Stype int64 `json:"stype"` Rid int64 `json:"rid"` OwnerID int64 `json:"owner_id"` Show int64 `json:"show"` Comment string `json:"comment"` Ts int64 `json:"ts"` Dynamic string `json:"dynamic"` Ext string `json:"extension"` Staffs []*StaffItem `json:"staffs,omitempty"` }
BlogCard 粉丝动态
type Cover ¶
type Cover struct { Filename string TotalNum int IndexNum int NFSPath string BFSPath string Used int64 CTime xtime.Time MTime xtime.Time }
Cover str
type ForbidAttr ¶
type ForbidAttr struct { Aid int64 `json:"aid"` OnFlowID int64 `json:"-"` RankV int32 `json:"-"` DynamicV int32 `json:"-"` RecommendV int32 `json:"-"` ShowV int32 `json:"-"` // specific Rank struct { Main int32 `json:"main"` RecentArc int32 `json:"recent_arc"` AllArc int32 `json:"all_arc"` } `json:"rank_attr"` Dynamic struct { Main int32 `json:"main"` } `json:"dynamic_attr"` Recommend struct { Main int32 `json:"main"` } `json:"recommend_attr"` Show struct { Main int32 `json:"main"` Mobile int32 `json:"mobile"` Web int32 `json:"web"` Oversea int32 `json:"oversea"` Online int32 `json:"online"` } }
ForbidAttr forbid attribute
type History ¶
type History struct { Aid int64 `json:"aid"` Title string `json:"title"` Cover string `json:"cover"` Desc string `json:"desc"` State int8 `json:"state"` }
History archive history model
type PoiObj ¶
type PoiObj struct { POI string `json:"poi"` Type int32 `json:"type"` Addr string `json:"address"` Title string `json:"title"` ShowTitle string `json:"show_title"` AdInfo *AdInfo `json:"ad_info"` Ancestors []*Ancestor `json:"ancestors"` Distance float64 `json:"distance"` ShowDistrance string `json:"show_distance"` Location *Location `json:"location"` }
PoiObj str
type Result ¶
type Result struct { Aid int64 `json:"aid"` Mid int64 `json:"mid"` TypeID int16 `json:"tid"` Title string `json:"title"` Author string `json:"author"` Cover string `json:"cover"` Tag string `json:"tag"` Duration int64 `json:"duration"` Copyright int8 `json:"copyright"` Desc string `json:"desc"` Round int8 `json:"round"` Forward int64 `json:"forward"` Attribute int32 `json:"attribute"` HumanRank int `json:"humanrank"` Access int16 `json:"access"` State int8 `json:"state"` Reason string `json:"reject_reason"` PTime string `json:"ptime"` CTime string `json:"ctime"` MTime string `json:"mtime"` Dynamic string `json:"dynamic"` }
Result is archive model.
func (*Result) NotAllowUp ¶
NotAllowUp check archive is or not allow update state.
type Staff ¶
type Staff struct { ID int64 `json:"id"` AID int64 `json:"aid"` MID int64 `json:"mid"` StaffMID int64 `json:"staff_mid"` StaffTitle string `json:"staff_title"` StaffTitleID int64 `json:"staff_title_id"` State int8 `json:"state"` }
Staff . 正式staff
type Type ¶
type Type struct { ID int16 `json:"id"` PID int16 `json:"pid"` Name string `json:"name"` Desc string `json:"description"` }
Type info
type Video ¶
type Video struct { ID int64 Filename string Cid int64 Aid int64 Title string Desc string SrcType string Duration int64 Filesize int64 Resolutions string Playurl string FailCode int8 Index int Attribute int32 XcodeState int8 Status int16 WebLink string Dimensions string CTime xtime.Time MTime xtime.Time }
Video is archive_video model.
Click to show internal directories.
Click to hide internal directories.