diff --git a/server/light_backtask/service/vip.go b/server/light_backtask/service/vip.go index 0e50cfcf..7e541a4a 100644 --- a/server/light_backtask/service/vip.go +++ b/server/light_backtask/service/vip.go @@ -1,7 +1,35 @@ package service +import ( + "f5" + "sync" + "main/constant" +) + type vip struct { + lock sync.Mutex } func (this *vip) init() () { } + +func (this *vip) Add(accountAddress string, val string, valField string, idxField string) bool { + this.lock.Lock() + defer this.lock.Unlock() + + err, ds := f5.GetGoStyleDb().NewOrmSelect( + constant.BCNFT_DB, + "t_vip_user", + [][]string { + {"address", accountAddress}, + }) + if err != nil { + return false + } + if ds.Next() { + + } else { + + } + return false +} diff --git a/third_party/f5 b/third_party/f5 index f3c6bd34..fe1b7e21 160000 --- a/third_party/f5 +++ b/third_party/f5 @@ -1 +1 @@ -Subproject commit f3c6bd34599966b9d3724d3eb7f0703cdf0383bd +Subproject commit fe1b7e21eb37d5494ccf32347ff368a1f011ac02