Explorar el Código

update egg canal type

master
shenjiachi hace 1 semana
padre
commit
80726ae26c
Se han modificado 6 ficheros con 17 adiciones y 17 borrados
  1. +1
    -1
      consume/egg_canal_invite_user_nums_consume.go
  2. +2
    -2
      consume/egg_canal_person_add_activity_value_consume.go
  3. +2
    -2
      consume/egg_canal_violate_nums_consume.go
  4. +5
    -5
      consume/md/md_egg_canal_person_add_activity_value_consume.go
  5. +4
    -4
      consume/md/md_egg_canal_user_relate_consume.go
  6. +3
    -3
      consume/md/md_egg_canal_violate_nums_consume.go

+ 1
- 1
consume/egg_canal_invite_user_nums_consume.go Ver fichero

@@ -71,7 +71,7 @@ func handleEggCanalInviteUserNumsConsume(msg []byte) error {
if canalMsg.Type == md2.CanalMsgInsertSqlType {
for _, item := range canalMsg.Data {
parentUid := item.ParentUid
id := fmt.Sprintf("%d%d-%d", year, week, parentUid)
id := fmt.Sprintf("%d%d-%s", year, week, parentUid)
fmt.Println("ESid:" + id + "=====================>")

// 新增拉新人数


+ 2
- 2
consume/egg_canal_person_add_activity_value_consume.go Ver fichero

@@ -80,9 +80,9 @@ func handleEggCanalPersonAddActivityValueConsume(msg []byte) error {
if canalMsg.Type == md2.CanalMsgInsertSqlType {
for _, item := range canalMsg.Data {
uid := item.Uid
id := fmt.Sprintf("%d%d-%d", year, week, uid)
id := fmt.Sprintf("%d%d-%s", year, week, uid)

if item.CoinId != personEggPointsCoinId && item.Direction != 1 {
if item.CoinId != utils2.IntToStr(personEggPointsCoinId) && item.Direction != "1" {
continue
}



+ 2
- 2
consume/egg_canal_violate_nums_consume.go Ver fichero

@@ -85,7 +85,7 @@ func handleEggCanalViolateNumsConsume(msg []byte) error {
continue
}
uid := item.Uid
id := fmt.Sprintf("%d%d-%d", year, week, uid)
id := fmt.Sprintf("%d%d-%s", year, week, uid)

// 2.2. 增加违规次数记录
script := elastic.NewScript("ctx._source.violate_nums += params.inc").Param("inc", 1)
@@ -115,7 +115,7 @@ func handleEggCanalViolateNumsConsume(msg []byte) error {
continue
}
uid := item.Uid
id := fmt.Sprintf("%d%d-%d", year, week, uid)
id := fmt.Sprintf("%d%d-%s", year, week, uid)

// 3.2 减少违规次数记录
script := elastic.NewScript("ctx._source.violate_nums -= params.dec").Param("dec", 1)


+ 5
- 5
consume/md/md_egg_canal_person_add_activity_value_consume.go Ver fichero

@@ -1,16 +1,16 @@
package md

type CanalUserVirtualCoinFlow struct {
Id int64 `json:"id"`
Uid int64 `json:"uid"`
CoinId int `json:"coin_id"`
Direction int `json:"direction"`
Id string `json:"id"`
Uid string `json:"uid"`
CoinId string `json:"coin_id"`
Direction string `json:"direction"`
Title string `json:"title"`
Amount string `json:"amount"`
BeforeAmount string `json:"before_amount"`
AfterAmount string `json:"after_amount"`
SysFee string `json:"sys_fee"`
TransferType int `json:"transfer_type"`
TransferType string `json:"transfer_type"`
}

type CanalUserVirtualCoinFlowMessage[T any] struct {


+ 4
- 4
consume/md/md_egg_canal_user_relate_consume.go Ver fichero

@@ -1,10 +1,10 @@
package md

type CanalUserRelate struct {
Id int64 `json:"id"`
ParentUid int64 `json:"parent_uid"`
Uid int64 `json:"uid"`
Level int `json:"level"`
Id string `json:"id"`
ParentUid string `json:"parent_uid"`
Uid string `json:"uid"`
Level string `json:"level"`
InviteTime string `json:"invite_time"`
}



+ 3
- 3
consume/md/md_egg_canal_violate_nums_consume.go Ver fichero

@@ -1,9 +1,9 @@
package md

type CanalTagRecords struct {
Id int `json:"id" `
TagId int `json:"tag_id" `
Uid int64 `json:"uid" `
Id string `json:"id" `
TagId string `json:"tag_id" `
Uid string `json:"uid" `
Memo string `json:"memo" `
CreateAt string `json:"create_at" `
UpdateAt string `json:"update_at" `


Cargando…
Cancelar
Guardar