12345678910111213141516171819202122 |
- package public
- import (
- "context"
- "github.com/gogf/gf/v2/frame/g"
- "github.com/gogf/gf/v2/util/gconv"
- "time"
- )
- func GetPayUser() map[string]bool {
- var (
- pay = make(map[string]bool)
- ctx = context.Background()
- )
- res, err := g.DB("subjectdb").Query(ctx, `SELECT id,userid FROM dwd_f_data_equity_info WHERE endtime>?`, time.Now().Format(time.DateTime))
- if err == nil && !res.IsEmpty() {
- for _, m := range res.List() {
- pay[gconv.String(m["userid"])] = true
- }
- }
- return pay
- }
|