Documentation ¶
Index ¶
- type Service
- func (s *Service) AddAppeal(c context.Context, btid, bid, mid int64, reason string) (err error)
- func (s *Service) AddBatchBlockedInfo(c context.Context, argJBs *model.ArgJudgeBatchBlocked) (err error)
- func (s *Service) AddBlockedCases(c context.Context, bc []*model.ArgJudgeCase) (err error)
- func (s *Service) AddBlockedInfo(c context.Context, argJB *model.ArgJudgeBlocked) (err error)
- func (s *Service) AddQs(c context.Context, qs *model.LabourQs) (err error)
- func (s *Service) AnnouncementInfo(c context.Context, aid int64) (res *model.BlockedAnnouncement, err error)
- func (s *Service) AnnouncementList(c context.Context, tp int8, pn, ps int64) (resp *model.AnnounceList, err error)
- func (s *Service) AppealState(c context.Context, mid, bid int64) (state bool, err error)
- func (s *Service) Apply(c context.Context, mid int64) (err error)
- func (s *Service) BLKHistorys(c context.Context, ah *model.ArgHistory) (rhs *model.ResBLKHistorys, err error)
- func (s *Service) BatchBLKCases(c context.Context, ids []int64) (cases map[int64]*model.BlockedCase, err error)
- func (s *Service) BatchBLKInfos(c context.Context, ids []int64) (items map[int64]*model.BlockedInfo, err error)
- func (s *Service) BatchPublishs(c context.Context, ids []int64) (res map[int64]*model.BlockedAnnouncement, err error)
- func (s *Service) BlockedInfo(c context.Context, id int64) (info *model.BlockedInfo, err error)
- func (s *Service) BlockedInfoAppeal(c context.Context, id, mid int64) (info *model.BlockedInfo, err error)
- func (s *Service) BlockedList(c context.Context, oType, bType int8, pn, ps int) (res []*model.BlockedInfo, err error)
- func (s *Service) BlockedNumUser(c context.Context, mid int64) (blockedSum *model.ResBlockedNumUser, err error)
- func (s *Service) BlockedUserCard(c context.Context, mid int64) (card *model.BlockedUserCard, err error)
- func (s *Service) BlockedUserList(c context.Context, mid int64) (r []*model.BlockedInfo, err error)
- func (s *Service) CaseInfo(c context.Context, cid int64) (res *model.BlockedCase, err error)
- func (s *Service) CaseInfoCache(c context.Context, cid int64) (bc *model.BlockedCase, err error)
- func (s *Service) CaseList(c context.Context, mid, pn, ps int64) (res []*model.BlockedCase, err error)
- func (s *Service) CaseListCache(c context.Context, mid, pn, ps int64) (bs []*model.BlockedCase, err error)
- func (s *Service) CaseObtain(c context.Context, mid int64, pubCid int64) (cid int64, err error)
- func (s *Service) CaseObtainByID(c context.Context, mid, cid int64) (err error)
- func (s *Service) CaseOpinion(c context.Context, cid, pn, ps int64) (ops []*model.Opinion, count int, err error)
- func (s *Service) Close()
- func (s *Service) CommitQs(c context.Context, mid int64, refer string, ua string, buvid string, ...) (commitRs *model.CommitRs, err error)
- func (s *Service) DelOpinion(c context.Context, cid, opid int64) (err error)
- func (s *Service) DelQs(c context.Context, id int64, isDel int64) (err error)
- func (s *Service) GetQs(c context.Context, mid int64) (qs []*model.LabourQs, err error)
- func (s *Service) IsAnswered(c context.Context, mid int64, mtime int64) (state int8, err error)
- func (s *Service) Jury(c context.Context, mid int64) (ui *model.UserInfo, err error)
- func (s *Service) JuryCase(c context.Context, mid int64, cid int64) (res *model.BlockedCase, err error)
- func (s *Service) JuryInfoCache(c context.Context, mid int64) (bj *model.BlockedJury, err error)
- func (s *Service) JuryInfos(c context.Context, mids []int64) (res map[int64]*model.ResJuryerStatus, err error)
- func (s *Service) KPIList(c context.Context, mid int64) (res []*model.KPI, err error)
- func (s *Service) LoadAnnouncement(c context.Context)
- func (s *Service) Notice(c context.Context) (n *model.Notice, err error)
- func (s *Service) Ping(c context.Context) (err error)
- func (s *Service) ReasonList(c context.Context) (n []*model.Reason, err error)
- func (s *Service) Requirement(c context.Context, mid int64) (jr *model.JuryRequirement, err error)
- func (s *Service) SetQs(c context.Context, id int64, ans int64, status int64) (err error)
- func (s *Service) SpJuryCase(c context.Context, mid int64, cid int64) (res *model.BlockedCase, err error)
- func (s *Service) Vote(c context.Context, mid, cid int64, attr, vote, aType, aReason int8, oc string, ...) (err error)
- func (s *Service) VoteInfo(c context.Context, mid int64, cid int64) (vi *model.VoteInfo, err error)
- func (s *Service) VoteInfoCache(c context.Context, mid, cid int64) (vi *model.VoteInfo, err error)
- func (s *Service) VoteOpinion(c context.Context, cid, pn, ps int64, otype int8) (ops []*model.Opinion, count int, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service struct of service.
func (*Service) AddBatchBlockedInfo ¶
func (s *Service) AddBatchBlockedInfo(c context.Context, argJBs *model.ArgJudgeBatchBlocked) (err error)
AddBatchBlockedInfo add batch blocked info.
func (*Service) AddBlockedCases ¶
AddBlockedCases batch add blocked cases.
func (*Service) AddBlockedInfo ¶
AddBlockedInfo add blocked info.
func (*Service) AnnouncementInfo ¶
func (s *Service) AnnouncementInfo(c context.Context, aid int64) (res *model.BlockedAnnouncement, err error)
AnnouncementInfo get announcement detail.
func (*Service) AnnouncementList ¶
func (s *Service) AnnouncementList(c context.Context, tp int8, pn, ps int64) (resp *model.AnnounceList, err error)
AnnouncementList get announcement list.
func (*Service) AppealState ¶
AppealState appeal status .
func (*Service) BLKHistorys ¶
func (s *Service) BLKHistorys(c context.Context, ah *model.ArgHistory) (rhs *model.ResBLKHistorys, err error)
BLKHistorys get blocked historys list.
func (*Service) BatchBLKCases ¶
func (s *Service) BatchBLKCases(c context.Context, ids []int64) (cases map[int64]*model.BlockedCase, err error)
BatchBLKCases get batch blocked cases by ids.
func (*Service) BatchBLKInfos ¶
func (s *Service) BatchBLKInfos(c context.Context, ids []int64) (items map[int64]*model.BlockedInfo, err error)
BatchBLKInfos mutli get blocked info by ids.
func (*Service) BatchPublishs ¶
func (s *Service) BatchPublishs(c context.Context, ids []int64) (res map[int64]*model.BlockedAnnouncement, err error)
BatchPublishs get publish info list.
func (*Service) BlockedInfo ¶
BlockedInfo blocked info
func (*Service) BlockedInfoAppeal ¶
func (s *Service) BlockedInfoAppeal(c context.Context, id, mid int64) (info *model.BlockedInfo, err error)
BlockedInfoAppeal get blocked info for appeal .
func (*Service) BlockedList ¶
func (s *Service) BlockedList(c context.Context, oType, bType int8, pn, ps int) (res []*model.BlockedInfo, err error)
BlockedList blocked info list, public default.
func (*Service) BlockedNumUser ¶
func (s *Service) BlockedNumUser(c context.Context, mid int64) (blockedSum *model.ResBlockedNumUser, err error)
BlockedNumUser get blocked user number.
func (*Service) BlockedUserCard ¶
func (s *Service) BlockedUserCard(c context.Context, mid int64) (card *model.BlockedUserCard, err error)
BlockedUserCard get user blocked card info.
func (*Service) BlockedUserList ¶
BlockedUserList get user blocked info list
func (*Service) CaseInfoCache ¶
CaseInfoCache .
func (*Service) CaseList ¶
func (s *Service) CaseList(c context.Context, mid, pn, ps int64) (res []*model.BlockedCase, err error)
CaseList user case list. TODO:cache
func (*Service) CaseListCache ¶
func (s *Service) CaseListCache(c context.Context, mid, pn, ps int64) (bs []*model.BlockedCase, err error)
CaseListCache .
func (*Service) CaseObtain ¶
CaseObtain jury user obtain case list.
func (*Service) CaseObtainByID ¶
CaseObtainByID obtain case by case id. NOTE: just for specific case.
func (*Service) CaseOpinion ¶
func (s *Service) CaseOpinion(c context.Context, cid, pn, ps int64) (ops []*model.Opinion, count int, err error)
CaseOpinion get case opinion.
func (*Service) CommitQs ¶
func (s *Service) CommitQs(c context.Context, mid int64, refer string, ua string, buvid string, ans *model.LabourAns) (commitRs *model.CommitRs, err error)
CommitQs commit questions.
func (*Service) DelOpinion ¶
DelOpinion del opinion.
func (*Service) IsAnswered ¶
IsAnswered labour check user is answwered question between the time.
func (*Service) JuryCase ¶
func (s *Service) JuryCase(c context.Context, mid int64, cid int64) (res *model.BlockedCase, err error)
JuryCase jury user case info contain vote.
func (*Service) JuryInfoCache ¶
JuryInfoCache JuryInfo cache .
func (*Service) JuryInfos ¶
func (s *Service) JuryInfos(c context.Context, mids []int64) (res map[int64]*model.ResJuryerStatus, err error)
JuryInfos mutli get jurys info.
func (*Service) LoadAnnouncement ¶
LoadAnnouncement load AnnouncementList.
func (*Service) ReasonList ¶
ReasonList get reason list.
func (*Service) Requirement ¶
Requirement user status in apply jury.
func (*Service) SpJuryCase ¶
func (s *Service) SpJuryCase(c context.Context, mid int64, cid int64) (res *model.BlockedCase, err error)
SpJuryCase get specific jury case info. NOTE : just for specific case for boss.
func (*Service) Vote ¶
func (s *Service) Vote(c context.Context, mid, cid int64, attr, vote, aType, aReason int8, oc string, likes, hates []int64) (err error)
Vote jury user vote case.
func (*Service) VoteInfoCache ¶
VoteInfoCache use vote cid info.