service

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

Documentation

Index

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 is service.

func New

func New() (s *Service)

New is workflow-admin service implementation.

func (*Service) ActivityList

func (s *Service) ActivityList(c context.Context, business int8, cid int64) (acts *model.Activities, err error)

ActivityList will list activities by given conditions

func (*Service) AddEvent

func (s *Service) AddEvent(c context.Context, ep *param.EventParam) (eid int64, err error)

AddEvent will add a event

func (*Service) AddOrUpCallback

func (s *Service) AddOrUpCallback(c context.Context, cbp *param.AddCallbackParam) (cbID int32, err error)

AddOrUpCallback will add or update a callback

func (*Service) AddOrUpdateBusAttr

func (s *Service) AddOrUpdateBusAttr(ctx context.Context, abap *param.AddBusAttrParam) (err error)

AddOrUpdateBusAttr add or update business attr info

func (*Service) AllAuditLog

func (s *Service) AllAuditLog(c context.Context, target int64, modules []int) (logs []*model.WLog, err error)

AllAuditLog search all audit log of target & modules

func (*Service) BatchAddEvent

func (s *Service) BatchAddEvent(c context.Context, bep *param.BatchEventParam) (eids []int64, err error)

BatchAddEvent will add events to batch chall

func (*Service) BatchSetChallResult

func (s *Service) BatchSetChallResult(c context.Context, bcrp *param.BatchChallResParam) (err error)

BatchSetChallResult will set a set of challenges result

func (*Service) BatchSetGroupResult

func (s *Service) BatchSetGroupResult(c context.Context, bgrp *param.BatchGroupResParam) (err error)

BatchSetGroupResult will set a set of groups result

func (*Service) BatchUpChallBusState

func (s *Service) BatchUpChallBusState(c context.Context, cids []int64, assigneeAdminid int64, assigneeAdminName string, busState int8) (err error)

BatchUpChallBusState will update business_state field of a set of challenges

func (*Service) BatchUpChallExtraV2

func (s *Service) BatchUpChallExtraV2(c context.Context, bcep *param.BatchChallExtraParam) (err error)

BatchUpChallExtraV2 update business object extra field by business oid

func (*Service) BusinessDesc

func (s *Service) BusinessDesc(business int8) string

BusinessDesc business description

func (*Service) BusinessList

func (s *Service) BusinessList(c context.Context, cids []int64) (cidToBus map[int64]*model.Business, err error)

BusinessList will retrive business object by cids Deprecated

func (*Service) ChallDetail

func (s *Service) ChallDetail(c context.Context, cid int64) (chall *model.Chall, err error)

ChallDetail will retrive challenge by cid

func (*Service) ChallList

func (s *Service) ChallList(c context.Context, cond *search.ChallSearchCommonCond) (challPage *search.ChallListPageCommon, err error)

ChallList will list challenges by several conditions Deprecated

func (*Service) ChallListCommon

func (s *Service) ChallListCommon(c context.Context, cond *search.ChallSearchCommonCond) (challPage *search.ChallListPageCommon, err error)

ChallListCommon will list challenges by several conditions

func (*Service) ChallListV3

func (s *Service) ChallListV3(c context.Context, cond *search.ChallSearchCommonCond) (challPage *search.ChallListPageCommon, err error)

ChallListV3 .

func (*Service) ChallsWrap

func (s *Service) ChallsWrap(c context.Context, cond *search.ChallSearchCommonCond) (challPageCommon *search.ChallListPageCommon, err error)

ChallsWrap warp challenges list result

func (*Service) Close

func (s *Service) Close()

Close consumer close.

func (*Service) FlowDesc

func (s *Service) FlowDesc(fid int8) string

FlowDesc .

func (*Service) GroupListV3

func (s *Service) GroupListV3(c context.Context, cond *search.GroupSearchCommonCond) (grpPage *model.GroupListPage, err error)

GroupListV3 .

func (*Service) GroupPendingCount

func (s *Service) GroupPendingCount(c context.Context, cond *search.GroupSearchCommonCond) (gpc *model.GroupPendingCount, err error)

GroupPendingCount 当前 bid/rid 待办工单数

func (*Service) LastLog

func (s *Service) LastLog(c context.Context, targets []int64, modules []int) (logs map[int64]string, err error)

LastLog .

func (*Service) LastLogStat

func (s *Service) LastLogStat(c context.Context, targets []int64, modules []int, fields []string) (logs map[int64]*search.ReportLog, err error)

LastLogStat .

func (*Service) ListBusAttr

func (s *Service) ListBusAttr(ctx context.Context) (busAttr []*model.BusinessAttr, err error)

ListBusAttr list business attr info

func (*Service) ListBusAttrV3

func (s *Service) ListBusAttrV3(ctx context.Context) (busAttr []*model.BusinessAttr, err error)

ListBusAttrV3 .

func (*Service) ListCallback

func (s *Service) ListCallback(c context.Context) (cbList model.CallbackSlice, err error)

ListCallback will list all enabled callbacks

func (*Service) ListEvent

func (s *Service) ListEvent(c context.Context, cid int64) (eventList model.EventSlice, err error)

ListEvent will add a set of events by challenge id

func (*Service) ListMeta

func (s *Service) ListMeta(c context.Context, itemType string) (metaList []*model.Meta, err error)

ListMeta will list business meta inforamtion from DAO

func (*Service) ManagerTag

func (s *Service) ManagerTag(ctx context.Context) (map[int8]map[int64]*model.TagMeta, error)

ManagerTag .

func (*Service) Ping

func (s *Service) Ping(c context.Context) (err error)

Ping check server ok.

func (*Service) PlatformChallCount

func (s *Service) PlatformChallCount(c context.Context, assigneeAdminID int64, permissionMap map[int8]int64) (challCount *search.ChallCount, err error)

PlatformChallCount will return count of challenges which are backlog of an admin

func (*Service) PlatformChallListCreated

func (s *Service) PlatformChallListCreated(c context.Context, cond *search.ChallSearchCommonCond) (challPage *search.ChallListPageCommon, err error)

PlatformChallListCreated list created challenges of admin

func (*Service) PlatformChallListHandlingDone

func (s *Service) PlatformChallListHandlingDone(c *bm.Context, pchlp *param.ChallHandlingDoneListParam, permissionMap map[int8]int64, assigneeAdminID int64, feature int8) (challPage interface{}, err error)

PlatformChallListHandlingDone list handling challenges of admin

func (*Service) PlatformChallListPending

func (s *Service) PlatformChallListPending(c context.Context, assigneeAdminID int64, permissionMap map[int8]int64, pclp *param.ChallListParam) (challPage *search.ChallListPageCommon, err error)

PlatformChallListPending will return challenges which are backlog of an admin

func (*Service) PlatformCheckIn

func (s *Service) PlatformCheckIn(c context.Context, assigneeAdminID int64) (err error)

PlatformCheckIn admin online

func (*Service) PlatformOnlineList

func (s *Service) PlatformOnlineList(c context.Context) (err error)

PlatformOnlineList .

func (*Service) PlatformRelease

func (s *Service) PlatformRelease(c context.Context, permissionMap map[int8]int64, assigneeAdminID int64) (err error)

PlatformRelease admin offline

func (*Service) RidDesc

func (s *Service) RidDesc(bid, rid int8) string

RidDesc .

func (*Service) RoleDesc

func (s *Service) RoleDesc(role int8) string

RoleDesc role description

func (*Service) RstChallResult

func (s *Service) RstChallResult(c context.Context, crp *param.ChallRstParam) (err error)

RstChallResult will reset challenge and its linked group state as Pending

func (*Service) SendCallbackRetry

func (s *Service) SendCallbackRetry(c context.Context, cb *model.Callback, payload *model.Payload) (err error)

SendCallbackRetry will try to send callback with specified attempts

func (*Service) SetChallBusState

func (s *Service) SetChallBusState(c context.Context, bcbsp *param.BatchChallBusStateParam) (err error)

SetChallBusState will update business_state field of a set of challenges

func (*Service) SetChallResult

func (s *Service) SetChallResult(c context.Context, crp *param.ChallResParam) (err error)

SetChallResult will set a challenge result

func (*Service) SetExtAPI

func (s *Service) SetExtAPI(ctx context.Context, ea *param.BusAttrExtAPI) (err error)

SetExtAPI .

func (*Service) SetGroupResult

func (s *Service) SetGroupResult(c context.Context, grp *param.GroupResParam) (err error)

SetGroupResult will set a group result

func (*Service) SetGroupState

func (s *Service) SetGroupState(c context.Context, gssp *param.GroupStateSetParam) (err error)

SetGroupState 修改未处理的工单状态

func (*Service) SetPublicReferee

func (s *Service) SetPublicReferee(c context.Context, gspr *param.GroupStatePublicReferee) (err error)

SetPublicReferee 移交众裁

func (*Service) SetShortCut

func (s *Service) SetShortCut(ctx context.Context, sc *param.BusAttrButtonShortCut) (err error)

SetShortCut .

func (*Service) SetSwitch

func (s *Service) SetSwitch(ctx context.Context, bs *param.BusAttrButtonSwitch) (err error)

SetSwitch .

func (*Service) SourceList

func (s *Service) SourceList(ctx context.Context, src *param.Source) (data map[string]interface{}, err error)

SourceList .

func (*Service) StateDescV3

func (s *Service) StateDescV3(business, fid, state int8) string

StateDescV3 .

func (*Service) StateDescr

func (s *Service) StateDescr(business, role, state int8) string

StateDescr state description

func (*Service) UpBusChallsBusState

func (s *Service) UpBusChallsBusState(c context.Context, business, busState int8, preBusStates []int8, oid int64, assigneeAdminid int64, extra map[string]interface{}) (cids []int64, err error)

UpBusChallsBusState will update business_state field of a set of challenges with same business and oid

func (*Service) UpChall

func (s *Service) UpChall(c context.Context, cup *param.ChallUpParam) (err error)

UpChall will update challenge tid

func (*Service) UpChallBusState

func (s *Service) UpChallBusState(c context.Context, cid int64, assigneeAdminid int64, assigneeAdminName string, busState int8) (err error)

UpChallBusState will update business_state field of a challenge

func (*Service) UpChallExtraV2

func (s *Service) UpChallExtraV2(c context.Context, cep *param.ChallExtraParam) (err error)

UpChallExtraV2 will update extra data of a challenge by cid

func (*Service) UpChallExtraV3

func (s *Service) UpChallExtraV3(c context.Context, cep3 *param.ChallExtraParamV3) (err error)

UpChallExtraV3 .

func (*Service) UpGroup

func (s *Service) UpGroup(c context.Context, gp *param.GroupParam) (err error)

UpGroup will update a group

func (*Service) UpGroupExtra

func (s *Service) UpGroupExtra(c context.Context, uep *param.UpExtraParam) (err error)

UpGroupExtra update business extra of gid, only cover business extra field

func (*Service) UpGroupRole

func (s *Service) UpGroupRole(c context.Context, grsp *param.GroupRoleSetParam) (err error)

UpGroupRole will 流转工单

Jump to

Keyboard shortcuts

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