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: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// 业务bid 对应manager项目子业务
	// ArchiveComplain 稿件投诉
	ArchiveComplain = 1
	// ArchiveAppeal 稿件申诉
	ArchiveAppeal = 2
	// ReviewShortComplain 短点评投诉
	ReviewShortComplain = 3
	// ReviewLongComplain 长点评投诉
	ReviewLongComplain = 4
	// CreditAppeal 小黑屋申诉
	CreditAppeal = 5
	// ArchiveAudit 稿件审核
	ArchiveAudit = 6
	// ArchiveVT 任务质检
	ArchiveVT = 7
	// ChannelComplain 频道举报
	ChannelComplain = 9
	// CommentComplain 评论举报
	CommentComplain = 13
	// SubtitleComplain 字幕举报
	SubtitleComplain = 14
)
View Source
const (
	GroupSetResult        = "group.SetResult"
	BatchGroupSetResult   = "group.BatchSetResult"
	ChallSetResult        = "chall.SetResult"
	BatchChallSetResult   = "chall.BatchSetResult"
	GroupSetState         = "group.SetState"
	GroupSetPublicReferee = "group.SetPublicReferee"

	CallbackDisable = 0
	CallbackEnable  = 1
)

consts for callback

View Source
const (
	// EventAdminReply 管理员回复
	EventAdminReply = 1
	// EventAdminNote 管理员回复并记录
	EventAdminNote = 2
	// EventUserReply 用户回复
	EventUserReply = 3
	// EventSystem 系统回复
	EventSystem = 4
)

consts for workflow event

View Source
const (
	ArcComplainDealMC = "1_13_1"
	ArcComplainRevMC  = "1_15_1"
	WkfNotifyMC       = "1_5_3"
)

message mc

View Source
const (
	// NotifyComRules 社区规则
	NotifyComRules = `` /* 197-byte string literal not displayed */
	// NotifyComRulesReport NotifyComRulesReport
	NotifyComRulesReport = "感谢您对bilibili社区秩序的维护,哔哩哔哩 (゜-゜)つロ 干杯~"
	// NotifyComUnrelated NotifyComUnrelated
	NotifyComUnrelated = "" /* 136-byte string literal not displayed */
	// NotifyComProvoke NotifyComProvoke
	NotifyComProvoke = "bilibili倡导平等友善的交流。良好的社区氛围需要大家一起维护!"
	// NofityComProhibited NofityComProhibited
	NofityComProhibited = `` /* 175-byte string literal not displayed */
)
View Source
const (
	// Group and Challenge State field
	Pending       = int8(0)  // 未处理
	Effective     = int8(1)  // 有效
	Invalid       = int8(2)  // 无效
	RoleShift     = int8(3)  // 流转
	Deleted       = int8(9)  // 已删除
	PublicReferee = int8(10) // 移交众裁

	// dispatch_state offset bit
	AuditorStateOffset = 0
	CSStateOffset      = 4

	QueueState         = 15 // 队列中审核状态
	QueueBusinessState = 15 // 队列中客服状态

	QueueStateBefore         = 0 // 默认审核状态
	QueueBusinessStateBefore = 1 // 默认客服状态

	// 反馈状态
	FeedbackReplyNotRead = 6 // 已回复未读
)

consts for state

View Source
const (
	PlatformStateHandling = iota + 1
	PlatformStateDone
	PlatformStateClosed
)

platform state

View Source
const (
	AuditRoundMin = 1
	AuditRoundMax = 10
	FeedbackRound = 11
)

business round

View Source
const (
	// report business = 12
	WLogModuleChallenge     = 1
	WLogModuleTag           = 2
	WLogModuleControl       = 3
	WLogModuleGroup         = 4
	WLogModuleReply         = 5 // modify business_state
	WLogModulePublicReferee = 6
	WLogModuleRoleShift     = 7  // 流转 (同一个执行方)
	WLogModuleDispose       = 8  // content dispose 操作内容对象
	WLogModuleAddMoral      = 20 // 扣节操
	WLogModuleBlock         = 21 // 封禁

	// report business = 11
	FeedBackTypeNotifyUserReceived = 2
	FeedBackTypeNotifyUserDisposed = 3
	FeedBackTypeReply              = 5
)

Log Module Field defination

View Source
const (
	ReplyFidManga = 22
)

Variables

View Source
var BlockReason = map[int8]string{
	credit.ReasonOtherType:                   "其他",
	credit.ReasonBrushScreen:                 "刷屏",
	credit.ReasonGrabFloor:                   "抢楼",
	credit.ReasonGamblingFraud:               "发布赌博诈骗信息",
	credit.ReasonProhibited:                  "发布违禁相关信息",
	credit.ReasonGarbageAds:                  "发布垃圾广告信息",
	credit.ReasonPersonalAttacks:             "发布人身攻击言论",
	credit.ReasonViolatePrivacy:              "发布侵犯他人隐私信息",
	credit.ReasonLeadBattle:                  "发布引战言论",
	credit.ReasonSpoiler:                     "发布剧透信息",
	credit.ReasonAddUnrelatedTags:            "恶意添加无关标签",
	credit.ReasonDelOtherTags:                "恶意删除他人标签",
	credit.ReasonPornographic:                "发布色情信息",
	credit.ReasonVulgar:                      "发布低俗信息",
	credit.ReasonBloodyViolence:              "发布暴力血腥信息",
	credit.ReasonAnimusVideoUp:               "涉及恶意投稿行为",
	credit.ReasonIllegalWebsite:              "发布非法网站信息",
	credit.ReasonSpreadErrinfo:               "发布传播不实信息",
	credit.ReasonAbettingEncouragement:       "发布怂恿教唆信息",
	credit.ReasonAnimusBrushScreen:           "恶意刷屏",
	credit.ReasonAccountViolation:            "账号违规",
	credit.ReasonMaliciousPlagiarism:         "恶意抄袭",
	credit.ReasonPosingAsHomemade:            "冒充自制原创",
	credit.ReasonPostTeenBadContent:          "发布青少年不良内容",
	credit.ReasonDestroyCyberSecurity:        "破坏网络安全",
	credit.ReasonPostingMisleadingInfo:       "发布虚假误导信息",
	credit.ReasonCounterfeitOfficialAuth:     "仿冒官方认证账号",
	credit.ReasonPublishInappropriateContent: "发布不适宜内容",
	credit.ReasonViolationOperatingRules:     "违反运营规则",
	credit.ReasonIllegalCreateTopic:          "恶意创建话题",
	credit.ReasonIllegalDrawLottery:          "发布违规抽奖",
	credit.ReasonIllegalFakeMan:              "恶意冒充他人",
}

BlockReason 封禁理由

Functions

func DealArcComplainMsg

func DealArcComplainMsg(aid int64, mids []int64) *param.MessageParam

DealArcComplainMsg generate archive complain deal message param

func PlatformMetas

func PlatformMetas() map[int8]map[int8]map[int64][]int64

PlatformMetas return platform meta data

func ReceivedArcComplainMsg

func ReceivedArcComplainMsg(aid int64, mids []int64) *param.MessageParam

ReceivedArcComplainMsg generate archive complain received message param

Types

type Account

type Account struct {
	Mid        int64         `json:"mid"`
	Name       string        `json:"name"`
	Rank       int32         `json:"rank"`
	Follower   int64         `json:"follower"`
	Official   *Official     `json:"official"`
	SpecialTag []*SpecialTag `json:"special_tag"`
}

Account account info struct http://info.bilibili.co/pages/viewpage.action?pageId=8465956#V3HTTP接口-用户全量信息含计数ProfileStat ignore unused field

type AccountInfosResult

type AccountInfosResult struct {
	Code    int      `json:"code"`
	Data    *Account `json:"data"`
	Message string   `json:"message"`
	TTL     int64    `json:"ttl"`
}

AccountInfosResult response of account info api

type Activities

type Activities struct {
	Logs   []*WLog  `json:"logs"`
	Events []*Event `json:"events"`
}

Activities is the model for all challenge activities

type Actor

type Actor struct {
	AdminID   int64  `json:"admin_id"`
	AdminName string `json:"admin_name"`
}

Actor for callback payload

type Archive

type Archive struct {
	Author       string   `json:"author"`
	State        int32    `json:"state"`
	Mid          int64    `json:"mid"`
	TypeID       int32    `json:"tid"`
	Type         string   `json:"type"`
	Title        string   `json:"title"`
	RejectReason string   `json:"reject_reason"`
	Composer     *Account `json:"-"`

	OPName    string `json:"op_name"`
	OPContent string `json:"op_content"`
	OPRemark  string `json:"op_remark"`
}

Archive is archive info struct http://info.bilibili.co/pages/viewpage.action?pageId=3686646

type ArchiveAppealGroup

type ArchiveAppealGroup struct {
	ArchiveComplainGroup

	// Appeal Related
	Cid               int64    `json:"cid"`
	AppealReason      string   `json:"appeal_reason"`
	AppealAttachments []string `json:"appeal_attachments"`
}

ArchiveAppealGroup is the model for archvie appeal group view

func (*ArchiveAppealGroup) FixAttachments

func (ag *ArchiveAppealGroup) FixAttachments()

FixAttachments will fix attachments url as user friendly ignore https case FIXME: this should be removed after attachment url is be normed

type ArchiveChannelData

type ArchiveChannelData struct {
	Tids       []int64            `json:"tids"`
	ChannelMap map[int64]*Channel `json:"channels"`
	Archive    *Archive           `json:"-"`
}

ArchiveChannelData .

type ArchiveComplainGroup

type ArchiveComplainGroup struct {
	Group
	Archive       *Archive      `json:"archive"`
	ChallengeTags ChallTagSlice `json:"challenge_tags"`
}

ArchiveComplainGroup is the model for archvie appeal group view

type ArchiveListPage

type ArchiveListPage struct {
	Items interface{} `json:"items"`
	Page  *Page       `json:"page"`
}

ArchiveListPage is the model for archive list result

type ArchiveResult

type ArchiveResult struct {
	*Archive `json:"archive"`
}

ArchiveResult is response of archive info api

type ArchiveType

type ArchiveType struct {
	ID          int64  `json:"id"`
	PID         int64  `json:"pid"`
	Name        string `json:"name"`
	Description string `json:"description"`
}

ArchiveType archive type struct

type ArchiveTypeResult

type ArchiveTypeResult struct {
	Code    int                    `json:"code"`
	Data    map[int32]*ArchiveType `json:"data"`
	Message string                 `json:"message"`
	TTL     int64                  `json:"ttl"`
}

ArchiveTypeResult response of archive type api

type BlockCaseAdd

type BlockCaseAdd struct {
	Aid           int64  `json:"aid"`
	Mid           int64  `json:"mid"`
	Operator      string `json:"operator"`
	OperID        int64  `json:"oper_id"`
	OriginType    int64  `json:"origin_type"`
	OriginContent string `json:"origin_content"`
	OriginTitle   string `json:"origin_title"`
	OriginURL     string `json:"origin_url"`
	ReasonType    int64  `json:"reason_type"`
	Oid           int64  `json:"oid"`
	RpID          int64  `json:"rp_id"`
	TagID         int64  `json:"tag_id"`
	Type          int64  `json:"type"`
	Page          int64  `json:"page"`
	BusinessTime  int64  `json:"business_time"`
}

BlockCaseAdd . http://info.bilibili.co/pages/viewpage.action?pageId=5417571

type BlockInfoResp

type BlockInfoResp struct {
	*CommonResponse
	Data *struct {
		Mid        int64 `json:"mid"`
		Status     int64 `json:"status"`
		StartTime  int64 `json:"start_time"`
		EndTime    int64 `json:"end_time"`
		BlockedSum int64 `json:"blocked_sum"`
	} `json:"data"`
}

BlockInfoResp .

type BlockNumResp

type BlockNumResp struct {
	*CommonResponse
	Data *struct {
		BlockedSum int64 `json:"blockedSum"`
	} `json:"data"`
}

BlockNumResp .

type Business

type Business struct {
	Bid      int32      `json:"-" gorm:"column:id"`
	Gid      int64      `json:"gid" gorm:"column:gid"`
	Cid      int64      `json:"cid" gorm:"column:cid"`
	Oid      int64      `json:"oid" gorm:"column:oid"`
	Business int8       `json:"business" gorm:"column:business"`
	TypeID   int32      `json:"typeid" gorm:"column:typeid"`
	Title    string     `json:"title" gorm:"column:title"`
	Content  string     `json:"content" gorm:"column:content"`
	Mid      int64      `json:"mid" gorm:"column:mid"`
	Extra    string     `json:"extra" gorm:"column:extra"`
	CTime    xtime.Time `json:"-" gorm:"column:ctime"`
	MTime    xtime.Time `json:"-" gorm:"column:mtime"`
}

Business will record any business properties

type BusinessAttr

type BusinessAttr struct {
	ID           int64      `json:"id" gorm:"column:id"`
	BID          int64      `json:"bid" gorm:"column:bid"`
	BusinessName string     `json:"business_name" gorm:"business_name"`
	Name         string     `json:"name" gorm:"column:name"`
	DealType     int8       `json:"deal_type" gorm:"column:deal_type"`
	ExpireTime   int64      `json:"expire_time" gorm:"column:expire_time"`
	AssignType   int8       `json:"assign_type" gorm:"column:assign_type"`
	AssignMax    int8       `json:"assign_max" gorm:"column:assign_max"`
	GroupType    int8       `json:"group_type" gorm:"column:group_type"`
	Button       uint8      `json:"-" gorm:"button"`
	ButtonKey    string     `json:"-" gorm:"button_key"`
	CTime        xtime.Time `json:"ctime" gorm:"column:ctime"`
	MTime        xtime.Time `json:"mtime" gorm:"column:mtime"`
	Buttons      []*Button  `json:"button" gorm:"-"`
}

BusinessAttr will record business attributes

func (BusinessAttr) TableName

func (BusinessAttr) TableName() string

TableName is used to identify chall table name in gorm

type Button

type Button struct {
	Index int    `json:"index"`
	Name  string `json:"name"`
	State bool   `json:"state"`
	Key   string `json:"key"`
}

Button .

type Callback

type Callback struct {
	CbID        int32      `json:"cbid" gorm:"column:id"`
	URL         string     `json:"url" gorm:"column:url"`
	Business    int8       `json:"business" gorm:"column:business"`
	IsSobot     bool       `json:"is_sobot" gorm:"column:is_sobot"`
	State       int8       `json:"state" gorm:"column:state"`
	ExternalAPI string     `json:"external_api" gorm:"column:external_api"`
	SourceAPI   string     `json:"source_api" gorm:"column:source_api"`
	CTime       xtime.Time `json:"ctime" gorm:"column:ctime"`
	MTime       xtime.Time `json:"mtime" gorm:"column:mtime"`
}

Callback is the workflow callback model

func (Callback) TableName

func (Callback) TableName() string

TableName is used to identify table name for gorm

type CallbackSlice

type CallbackSlice []*Callback

Slice is the slice model for callback

type Chall

type Chall struct {
	Cid               int64      `json:"cid" gorm:"column:id"`
	Gid               int64      `json:"gid" gorm:"column:gid"`
	Oid               int64      `json:"oid" gorm:"column:oid"`
	OidStr            string     `json:"oid_str" gorm:"-"`
	Business          int8       `json:"business" gorm:"column:business"`
	Mid               int64      `json:"mid" gorm:"column:mid"`
	MName             string     `json:"m_name" gorm:"-"`
	Tid               int64      `json:"tid" gorm:"column:tid"`
	State             int8       `json:"state"`
	BusinessState     int8       `json:"business_state"`
	DispatchState     uint32     `json:"-" gorm:"column:dispatch_state"`
	DispatchTime      xtime.Time `json:"dispatch_time" gorm:"column:dispatch_time"`
	Description       string     `json:"description" gorm:"column:description"`
	Metadata          string     `json:"metadata" gorm:"column:metadata"`
	CTime             xtime.Time `json:"ctime" gorm:"column:ctime"`
	MTime             xtime.Time `json:"mtime" gorm:"column:mtime"`
	BusinessObject    *Business  `json:"business_object,omitempty" gorm:"-"`
	AssigneeAdminID   int64      `json:"assignee_adminid" gorm:"column:assignee_adminid"`
	AdminID           int64      `json:"adminid" gorm:"column:adminid"`
	AssigneeAdminName string     `json:"assignee_admin_name" gorm:"-"`
	AdminName         string     `json:"admin_name" gorm:"-"`
	TotalStates       string     `json:"total_states" gorm:"-"`

	// tag related fields
	Tag   string `json:"tag" gorm:"-"`
	Round int8   `json:"round" gorm:"-"`

	// log related
	LastLog string `json:"last_log" gorm:"-"`
	// event related
	LastEvent *Event `json:"last_event" gorm:"-"`

	// Attachments
	Attachments []string `json:"attachments" gorm:"-"`

	// linked group object
	Group *Group `json:"group,omitempty" gorm:"-"`

	Meta     interface{} `json:"meta" gorm:"-"`
	AuditLog interface{} `json:"audit_log" gorm:"-"`
	Producer *Account    `json:"producer" gorm:"-"` //举报人

	// business table
	Title  string `json:"title,omitempty" gorm:"-"`
	TypeID int64  `json:"type_id,omitempty" gorm:"-"`
}

Chall is the row view for every challenge

func (*Chall) FixAttachments

func (c *Chall) FixAttachments()

FixAttachments will fix attachments url as user friendly ignore https case FIXME: this should be removed after attachment url is be normed

func (*Chall) FormatState

func (c *Chall) FormatState()

FormatState transform state in queue

func (*Chall) FromState

func (c *Chall) FromState()

FromState set State and BusinessState field from DispatchState field

func (*Chall) SetState

func (c *Chall) SetState(state uint32, role uint8)

SetState update state of a role ex. oldState=0x3a4b5c6d, state=15, role=1 then result is 0x3a4b5cfd

func (Chall) TableName

func (Chall) TableName() string

TableName is used to identify chall table name in gorm

type ChallTag

type ChallTag struct {
	ID      int64  `json:"id"`
	Tag     string `json:"tag"`
	Round   int8   `json:"round"`
	Count   int64  `json:"count"`
	Percent int32  `json:"percent"`
}

ChallTag is the model to retrive user submitted tags in group view

type ChallTagSlice

type ChallTagSlice []*ChallTag

ChallTagSlice is the slice to ChallTag

func (ChallTagSlice) Len

func (c ChallTagSlice) Len() int

func (ChallTagSlice) Less

func (c ChallTagSlice) Less(i, j int) bool

func (ChallTagSlice) Swap

func (c ChallTagSlice) Swap(i, j int)

type Channel

type Channel struct {
	//Tid      int64    `json:"tid"`
	TName string `json:"tname"`
	//HitRule  string   `json:"hit_rule"`
	//HitNames []string `json:"hit_names"`
	HitRules []string `json:"hit_rules"`
	Archive  *Archive `json:"archive"`
}

Channel .

type ChannelInfoResult

type ChannelInfoResult struct {
	*CommonResponse
	Data map[int64]*ArchiveChannelData
}

ChannelInfoResult .

type CommonExtraDataResponse

type CommonExtraDataResponse struct {
	*CommonResponse
	Data map[string]interface{} `json:"data"` //map[gid]interface{}
}

CommonExtraDataResponse .

type CommonResponse

type CommonResponse struct {
	Code    int    `json:"code"`
	Message string `json:"message"`
	TTL     int    `json:"ttl"`
}

CommonResponse .

type CreditMeta

type CreditMeta struct {
	*Business
	Producer *Account `json:"producer"`
}

CreditMeta .

type Event

type Event struct {
	Eid         int64      `json:"eid" gorm:"column:id"`
	Cid         int64      `json:"cid" gorm:"column:cid"`
	AdminID     int64      `json:"adminid" gorm:"column:adminid"`
	Content     string     `json:"content" gorm:"column:content"`
	Attachments string     `json:"attachments" gorm:"column:attachments"`
	Event       int8       `json:"event" gorm:"column:event"`
	CTime       xtime.Time `json:"ctime" gorm:"column:ctime"`
	MTime       xtime.Time `json:"mtime" gorm:"column:mtime"`
	Admin       string     `json:"admin" gorm:"-"`
}

Event model is the model for challenge changes

func (*Event) FixAttachments

func (e *Event) FixAttachments()

FixAttachments will fix attachments url as user friendly ignore https case FIXME: this should be removed after attachment url is be normed

func (Event) TableName

func (Event) TableName() string

TableName is used to identify table name in gorm

type EventSlice

type EventSlice []*Event

EventSlice is a Event slice struct

type Group

type Group struct {
	ID           int64  `json:"id" gorm:"column:id"`
	Oid          int64  `json:"oid" gorm:"column:oid"`
	OidStr       string `json:"oid_str" gorm:"-"`
	Business     int8   `json:"business" gorm:"column:business"`
	Fid          int64  `json:"fid" gorm:"column:fid"`
	Rid          int8   `json:"rid" gorm:"column:rid"`
	Eid          int64  `json:"eid" gorm:"eid"`
	EidStr       string `json:"eid_str" gorm:"-"`
	State        int8   `json:"state" gorm:"column:state"`
	Tid          int64  `json:"tid" gorm:"column:tid"`
	FirstUserTid int64  `json:"first_user_tid" gorm:"-"`
	Note         string `json:"note" gorm:"column:note"`
	Score        int64  `json:"score" gorm:"column:score"`

	// Stat fields
	// this is a workround solution for calcuating appeals
	Count    int32 `json:"count" gorm:"column:count"`
	Handling int32 `json:"handling" gorm:"column:handling"`

	CTime    xtime.Time `json:"ctime" gorm:"column:ctime"`
	MTime    xtime.Time `json:"mtime" gorm:"column:mtime"`
	LastTime xtime.Time `json:"last_time" gorm:"column:lasttime"`

	LastLog        string    `json:"last_log" gorm:"-"`
	BusinessObject *Business `json:"business_object,omitempty" gorm:"-"`

	// Tags related to Group
	Tag           string        `json:"tag" gorm:"-"`
	Round         int8          `json:"round" gorm:"-"`
	ChallengeTags ChallTagSlice `json:"challenge_tags" gorm:"-"`

	Meta     interface{} `json:"meta" gorm:"-"`
	MetaData interface{} `json:"meta_data" gorm:""`
	TypeID   int64       `json:"type_id" gorm:"-"`

	LastProducer *Account `json:"last_producer" gorm:"-"`
	Defendant    *Account `json:"defendant" gorm:"-"`
}

Group model is the group view for several challanges

func (Group) TableName

func (Group) TableName() string

TableName is used to identify group table name in gorm

type GroupListPage

type GroupListPage struct {
	Items []*Group `json:"items"`
	Page  *Page    `json:"page"`
}

GroupListPage is the model for group list result

type GroupMeta

type GroupMeta struct {
	Archive  *Archive    `json:"archive"`
	Object   *Business   `json:"object"`
	External interface{} `json:"external"`
}

GroupMeta .

type GroupPendingCount

type GroupPendingCount struct {
	Total int `json:"total"`
}

GroupPendingCount .

type LogSlice

type LogSlice []*WLog

LogSlice is a Log slice struct

type Meta

type Meta struct {
	Business int8          `json:"business"`
	Name     string        `json:"name"`
	ItemType string        `json:"item_type"`
	Rounds   []*Round      `json:"rounds"`
	Attr     *BusinessAttr `json:"attr"`
}

Meta is the model to store business metadata

type MetaSlice

type MetaSlice []*Meta

MetaSlice is used to support sort Metas

func (MetaSlice) Len

func (ms MetaSlice) Len() int

func (MetaSlice) Less

func (ms MetaSlice) Less(i, j int) bool

func (MetaSlice) Swap

func (ms MetaSlice) Swap(i, j int)

type MultiArchiveInfoResult

type MultiArchiveInfoResult struct {
	Code    int                      `json:"code"`
	Data    map[int64]*ArchiveResult `json:"data"`
	Message string                   `json:"message"`
	TTL     int64                    `json:"ttl"`
}

MultiArchiveInfoResult is response of multi archive info api

type MultiReviewInfoResult

type MultiReviewInfoResult struct {
	Code    int               `json:"code"`
	Result  map[int64]*Review `json:"result"`
	Message string            `json:"message"`
	TTL     int64             `json:"ttl"`
}

MultiReviewInfoResult response of multi review info api

type Official

type Official struct {
	Role int8 `json:"role"`
}

Official .

type Page

type Page struct {
	Num   int `json:"num"`
	Size  int `json:"size"`
	Total int `json:"total"`
}

Page common page struct for list api

type Payload

type Payload struct {
	Bid       int           `json:"bid"`
	Verb      string        `json:"verb"`
	Actor     Actor         `json:"actor"`
	CTime     xtime.Time    `json:"ctime"`
	Object    interface{}   `json:"object"`    //处理请求参数
	Target    interface{}   `json:"target"`    //被修改的工单或工单详情
	Targets   []interface{} `json:"targets"`   //所有被修改的工单或工单详情
	Influence interface{}   `json:"influence"` //业务自定义 Deprecated
	Extra     interface{}   `json:"extra"`     //业务自定义
}

Payload is the payload model for callback

type Relation

type Relation struct {
	Follower int `json:"follower"`
}

Relation . http://info.bilibili.co/pages/viewpage.action?pageId=8742464

type Review

type Review struct {
	ReviewID  int64      `json:"review_id"`
	Type      int8       `json:"type"`
	Mid       int64      `json:"mid"`
	MediaName string     `json:"media_name"`
	Title     string     `json:"title"`
	Content   string     `json:"content"`
	Status    int8       `json:"status"`
	IsDelete  int8       `json:"is_delete"`
	CTime     xtime.Time `json:"ctime"`
	MTime     xtime.Time `json:"mtime"`
	TypeName  string     `json:"type_name"`
	Author    string     `json:"author"`
	Composer  *Account   `json:"-"`
}

Review review struct http://info.bilibili.co/pages/viewpage.action?pageId=5417343

type Round

type Round struct {
	ID   int8   `json:"id"`
	Name string `json:"name"`
}

Round is the model to describe how many business rounds are

type RoundSlice

type RoundSlice []*Round

RoundSlice is used to support sort Rounds

func (RoundSlice) Len

func (rs RoundSlice) Len() int

func (RoundSlice) Less

func (rs RoundSlice) Less(i, j int) bool

func (RoundSlice) Swap

func (rs RoundSlice) Swap(i, j int)

type SourceQueryResponse

type SourceQueryResponse struct {
	*CommonResponse
	Data map[string]interface{} `json:"data"`
}

SourceQueryResponse

type SpecialTag

type SpecialTag struct {
	MID       int64  `json:"mid"`
	GroupTag  string `json:"group_tag"`
	BGColor   string `json:"bg_color"`
	FontColor string `json:"font_color"`
	GroupID   int    `json:"group_id"`
}

SpecialTag .

type TagListResult

type TagListResult struct {
	*CommonResponse
	Data struct {
		Tags []*TagMeta `json:"data"`
		Page `json:"page"`
	} `json:"data"`
}

TagListResult .

type TagMeta

type TagMeta struct {
	ID          int64  `json:"id"`
	Bid         int8   `json:"bid"`
	Tid         int64  `json:"tid"`
	TagID       int64  `json:"tag_id"` //map to old workflow tag id
	TName       string `json:"tname"`
	RID         int8   `json:"rid"`
	RName       string `json:"rname"`
	Name        string `json:"name"`
	Weight      int64  `json:"weight"`
	State       int8   `json:"state"`
	UID         int64  `json:"uid"`
	UName       string `json:"uname"`
	Description string `json:"description"`
	CTime       int    `json:"ctime"`
	MTime       int    `json:"mtime"`
}

TagMeta tag from manager/list

type TinyChall

type TinyChall struct {
	Cid   int64      `json:"cid" gorm:"column:id"`
	Gid   int64      `json:"gid" gorm:"column:gid"`
	Mid   int64      `json:"mid" gorm:"column:mid"`
	CTime xtime.Time `json:"ctime" gorm:"column:ctime"`
	State int8       `json:"state" gorm:"-"`
	Title string     `json:"title" gorm:"-"`
}

TinyChall is the tiny row view for every challenge

type UperSpecial

type UperSpecial struct {
	Code    int    `json:"code"`
	Message string `json:"message"`
	TTL     int64  `json:"ttl"`
	Data    struct {
		Page  Page          `json:"page"`
		Items []*SpecialTag `json:"items"`
	} `json:"data"`
}

UperSpecial . http://info.bilibili.co/pages/viewpage.action?pageId=8479274

type WLog

type WLog struct {
	Lid         int32       `json:"lid"`
	AdminID     int64       `json:"adminid"`
	Admin       string      `json:"admin"`
	Oid         int64       `json:"oid"`
	Business    int8        `json:"business"`
	Target      int64       `json:"target"`
	Module      int8        `json:"module"`
	Remark      string      `json:"remark"`
	Note        string      `json:"note"`
	CTime       xtime.Time  `json:"ctime"`
	MTime       xtime.Time  `json:"mtime"`
	Meta        interface{} `json:"meta"`
	ReportCTime string      `json:"report_ctime"`
	Mid         int64       `json:"mid"`
	TypeID      int64       `json:"type_id"`
	TimeConsume int64       `json:"time_consume"`
	OpType      string      `json:"op_type"`
	PreRid      string      `json:"pre_rid"`
	Param       interface{} `json:"param"`
	Mids        []int64     `json:"mids"` //对被举报人的批量操作
}

Log model is the universal model Will record any management actions

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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