Documentation
¶
Index ¶
- func BmGetInt64OrDefault(c *bm.Context, key string, defaul int64) (value int64, exist bool)
- func BmGetStringOrDefault(c *bm.Context, key string, defaul string) (value string, exist bool)
- func BmHTTPErrorWithMsg(c *bm.Context, err error, msg string)
- type BaseJobInterface
- type CalcJob
- type CalcService
- type CalcStatisticJob
- type Service
- func (s *Service) Close()
- func (c *Service) GetCreditLog(con context.Context, arg *upcrmmodel.ArgGetLogHistory) (results []*upcrmmodel.SimpleCreditLogWithContent, err error)
- func (c *Service) GetCreditScore(con context.Context, arg *upcrmmodel.GetScoreParam) (results []*upcrmmodel.UpScoreHistory, err error)
- func (s *Service) LogCredit(c context.Context, arg *upcrmmodel.ArgCreditLogAdd) (err error)
- func (s *Service) Test()
- func (s *Service) WriteStatData()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BmGetInt64OrDefault ¶
BmGetInt64OrDefault get int64
func BmGetStringOrDefault ¶
BmGetStringOrDefault get string
Types ¶
type BaseJobInterface ¶
BaseJobInterface job interface
type CalcJob ¶
type CalcJob struct { ID int // 数据日 Date time.Time // 对应的数据 TableNum int Overall *calculator.OverAllStatistic IsDone bool Svc *CalcService }
CalcJob calculate job
func (*CalcJob) Description ¶
Description descrpit job
type CalcService ¶
type CalcService struct { JobChannel chan BaseJobInterface OutputChan chan *upcrmmodel.UpScoreHistory // contains filtered or unexported fields }
CalcService calc service
func NewCalc ¶
func NewCalc(c *conf.Config, outChan chan *upcrmmodel.UpScoreHistory, crmdao *upcrmdao.Dao) *CalcService
NewCalc create calc service
func (*CalcService) AddCalcJob ¶
func (c *CalcService) AddCalcJob(date time.Time)
AddCalcJob add job
func (*CalcService) CalcScoreSectionData ¶
func (c *CalcService) CalcScoreSectionData() (err error)
CalcScoreSectionData calc score section
type CalcStatisticJob ¶
type CalcStatisticJob struct { ID int // 数据日 Date time.Time Svc *CalcService }
CalcStatisticJob statis job
func (*CalcStatisticJob) Description ¶
func (j *CalcStatisticJob) Description() (dest string)
Description desc
type Service ¶
type Service struct { CreditScoreInputChan chan *upcrmmodel.UpScoreHistory CalcSvc *CalcService // contains filtered or unexported fields }
Service is service.
func (*Service) GetCreditLog ¶
func (c *Service) GetCreditLog(con context.Context, arg *upcrmmodel.ArgGetLogHistory) (results []*upcrmmodel.SimpleCreditLogWithContent, err error)
GetCreditLog get log
func (*Service) GetCreditScore ¶
func (c *Service) GetCreditScore(con context.Context, arg *upcrmmodel.GetScoreParam) (results []*upcrmmodel.UpScoreHistory, err error)
GetCreditScore get credit score
func (*Service) LogCredit ¶
func (s *Service) LogCredit(c context.Context, arg *upcrmmodel.ArgCreditLogAdd) (err error)
LogCredit log credit log
Click to show internal directories.
Click to hide internal directories.