Parcourir la source

update

master
dengbiao il y a 3 jours
Parent
révision
fd005650a3
2 fichiers modifiés avec 21 ajouts et 2 suppressions
  1. +19
    -0
      enum/sys_cfg.go
  2. +2
    -2
      utils/es/base.go

+ 19
- 0
enum/sys_cfg.go Voir le fichier

@@ -73,3 +73,22 @@ func (gt AliyunOss) String() string {
return "未知"
}
}

// AlipayConfig 支付宝支付枚举类型
type AlipayConfig string

const (
AlipayAppId = "alipay_app_id"
AlipayPrivateKey = "alipay_private_key"
)

func (gt AlipayConfig) String() string {
switch gt {
case AlipayAppId:
return ""
case AlipayPrivateKey:
return "oss存储桶名称"
default:
return "未知"
}
}

+ 2
- 2
utils/es/base.go Voir le fichier

@@ -21,10 +21,10 @@ func GetLatestEffectiveIndexFromAlias(now time.Time) string {
year, week := now.ISOWeek()
if now.Weekday() > time.Wednesday || (now.Weekday() > time.Wednesday && now.Hour() > 14) {
// 当前已经过了周三下午两点 返回当周蛋蛋分
esIndexName = md.EggEnergyUserEggScoreEsAlias + "_" + egg_system_rules.IntToStr(year) + egg_system_rules.IntToStr(week)
esIndexName = egg_system_rules.IntToStr(year) + egg_system_rules.IntToStr(week)
} else {
// 没过周三下午两点 返回上周蛋蛋分
esIndexName = md.EggEnergyUserEggScoreEsAlias + "_" + egg_system_rules.IntToStr(year) + egg_system_rules.IntToStr(week-1)
esIndexName = egg_system_rules.IntToStr(year) + egg_system_rules.IntToStr(week-1)
}
return esIndexName
}

Chargement…
Annuler
Enregistrer