config.go 872 B

12345678910111213141516171819202122232425262728293031
  1. package vars
  2. import (
  3. qutil "app.yhyue.com/moapp/jybase/common"
  4. )
  5. var Config *config
  6. type config struct {
  7. WebPort string `json:"webPort"` //服务端口
  8. Ahead AheadConfig `json:"ahead"` //超前项目配置
  9. Custom CustomConfig `json:"custom"` //定制化报告配置
  10. TestUid []string `json:"testUid"` //测试用户id
  11. }
  12. type AheadConfig struct {
  13. Prop float64 `json:"prop"` //新增用户百分比
  14. DailyTimes int `json:"dailyTimes"` //每日展示次数
  15. SaveClickTimes int `json:"saveClickTimes"` //保留用户的点击量
  16. UpdateCron string `json:"updateCron"` //更新周活用户
  17. }
  18. type CustomConfig struct {
  19. SearchPool int `json:"searchPool"` //检索并发池
  20. UpdateCron string `json:"updateCron"` //更新周活用户
  21. }
  22. func init() {
  23. //程序配置文件
  24. qutil.ReadConfig(&Config)
  25. }