From 66ed6db51e0dd2cc450946e7c2c1761c3f398ffb Mon Sep 17 00:00:00 2001 From: huangjiajun <582604932@qq.com> Date: Wed, 4 Dec 2024 11:42:18 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E7=A0=B8=E8=9B=8B=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- go.mod | 4 ++++ go.sum | 8 ++++++++ rule/egg_energy/home_page_watch_over_ad.go | 1 + 3 files changed, 13 insertions(+) diff --git a/go.mod b/go.mod index 309a58b..7a3d4b4 100644 --- a/go.mod +++ b/go.mod @@ -29,6 +29,10 @@ require ( github.com/alibabacloud-go/tea-xml v1.1.3 // indirect github.com/aliyun/credentials-go v1.3.10 // indirect github.com/clbanning/mxj/v2 v2.5.5 // indirect + github.com/go-pay/crypto v0.0.1 // indirect + github.com/go-pay/gopay v1.5.106 // indirect + github.com/go-pay/xlog v0.0.3 // indirect + github.com/go-pay/xtime v0.0.2 // indirect github.com/onsi/ginkgo v1.16.5 // indirect github.com/onsi/gomega v1.27.8 // indirect github.com/pkg/errors v0.9.1 // indirect diff --git a/go.sum b/go.sum index d7471a6..c6579df 100644 --- a/go.sum +++ b/go.sum @@ -129,6 +129,14 @@ github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgO github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= +github.com/go-pay/crypto v0.0.1 h1:B6InT8CLfSLc6nGRVx9VMJRBBazFMjr293+jl0lLXUY= +github.com/go-pay/crypto v0.0.1/go.mod h1:41oEIvHMKbNcYlWUlRWtsnC6+ASgh7u29z0gJXe5bes= +github.com/go-pay/gopay v1.5.106 h1:UVAX/jJu3tQXcS39FwYw1bcBEOcW1zdBSQ4EIbhiLrI= +github.com/go-pay/gopay v1.5.106/go.mod h1:I+1qOFZsNt6quaA1B9grXgz+RrFh6rOXQYiX2R+IaoU= +github.com/go-pay/xlog v0.0.3 h1:avyMhCL/JgBHreoGx/am/kHxfs1udDOAeVqbmzP/Yes= +github.com/go-pay/xlog v0.0.3/go.mod h1:mH47xbobrdsSHWsmFtSF5agWbMHFP+tK0ZbVCk5OAEw= +github.com/go-pay/xtime v0.0.2 h1:7YR4/iuELsEHpJ6LUO0SVK80hQxDO9MLCfuVYIiTCRM= +github.com/go-pay/xtime v0.0.2/go.mod h1:W1yRbJaSt4CSBcdAtLBQ8xajiN/Pl5hquGczUcUE9xE= github.com/go-redis/redis v6.15.9+incompatible h1:K0pv1D7EQUjfyoMql+r/jZqCLizCGKFlFgcHWWmHQjg= github.com/go-redis/redis v6.15.9+incompatible/go.mod h1:NAIEuMOZ/fxfXJIrKDQDz8wamY7mA7PouImQ2Jvg6kA= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= diff --git a/rule/egg_energy/home_page_watch_over_ad.go b/rule/egg_energy/home_page_watch_over_ad.go index ddac1a9..b57c075 100644 --- a/rule/egg_energy/home_page_watch_over_ad.go +++ b/rule/egg_energy/home_page_watch_over_ad.go @@ -170,6 +170,7 @@ func settlementPublicGiveActivityCoin(engine *xorm.Engine, uid int64, ch *rabbit if err != nil { return err } + watchRecord = &tempM } else { residueWatchAdNum := watchRecord.ResidueWatchAdNum - 1 nextWatchAdDate := watchRecord.NextWatchAdDate From 114f519b2b97ce8c7f024ba87e43acd91c742398 Mon Sep 17 00:00:00 2001 From: shenjiachi Date: Wed, 4 Dec 2024 13:40:03 +0800 Subject: [PATCH 2/2] add es friend circle like --- md/es.go | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/md/es.go b/md/es.go index c5a3468..59ccf17 100644 --- a/md/es.go +++ b/md/es.go @@ -244,3 +244,42 @@ type EggFriendCircleCommentEs struct { CreatedAt string `json:"created_at"` UpdatedAt string `json:"updated_at"` } + +const EggFriendCircleLikeEsAlias = "egg_friend_circle_like" +const EggFriendCircleLikeEsIndex = "egg_friend_circle_like_" +const EggFriendCircleLikeEsMapping = ` +{ + "settings" : { + "number_of_shards" : 2, + "number_of_replicas" : 1 + }, + "aliases": { + "egg_friend_circle": {} + }, + "mappings":{ + "properties":{ + "uid":{ + "type": "integer" + }, + "circle_id":{ + "type": "integer" + }, + "created_at":{ + "type": "date", + "format": "yyyy-MM-dd HH:mm:ss||yyyy-MM-dd||epoch_millis" + }, + "updated_at":{ + "type": "date", + "format": "yyyy-MM-dd HH:mm:ss||yyyy-MM-dd||epoch_millis" + } + } + } +}` + +type EggFriendCircleLikeEs struct { + Uid int64 `json:"uid" label:"uid"` + ImUid int64 `json:"im_uid" label:"im_uid"` + CircleId string `json:"circle_id" label:"朋友圈id"` + CreatedAt string `json:"created_at"` + UpdatedAt string `json:"updated_at"` +}