瀏覽代碼

update

master
shenjiachi 6 天之前
父節點
當前提交
3f778267f3
共有 2 個檔案被更改,包括 3 行新增3 行删除
  1. +2
    -2
      consume/egg_record_active_consume.go
  2. +1
    -1
      consume/im_egg_energy_send_red_package_consume.go

+ 2
- 2
consume/egg_record_active_consume.go 查看文件

@@ -83,7 +83,7 @@ func handleEggRecordActiveDataConsume(msgData []byte) error {
// 3.添加团队活跃次数
if userRelate != nil {
parentUid := userRelate.ParentUid
parentEsId := fmt.Sprintf("%d%d-%d", year, week, parentUid)
parentEsId := fmt.Sprintf("%d%d_%d", year, week, parentUid)
// 增加团队活跃次数记录
script := elastic.NewScript("ctx._source.team_activity_nums += params.inc").Param("inc", 1)
_, err = es.EsClient.Update().
@@ -97,7 +97,7 @@ func handleEggRecordActiveDataConsume(msgData []byte) error {
}

// 4.更新签到次数
esId := fmt.Sprintf("%d%d-%d", year, week, msg.Uid)
esId := fmt.Sprintf("%d%d_%d", year, week, msg.Uid)
script := elastic.NewScript(`
ctx._source.sign_in_nums += params.signInInc;
`).Param("signInInc", 1)


+ 1
- 1
consume/im_egg_energy_send_red_package_consume.go 查看文件

@@ -69,7 +69,7 @@ func handleIMEggEnergySendRedPackageConsume(msgData []byte) error {
yearStr := utils2.IntToStr(year)
weekStr := utils2.IntToStr(week)
index := es2.GetAppointIndexFromAlias(yearStr, weekStr)
id := fmt.Sprintf("%d%d-%d", year, week, msg.Uid)
id := fmt.Sprintf("%d%d_%d", year, week, msg.Uid)
// 3.新增发红包次数
script := elastic.NewScript("ctx._source.send_red_package_nums += params.inc").Param("inc", 1)
_, err = es.EsClient.Update().


Loading…
取消
儲存