Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

流量扣除异常 #3

Open
yvhitxcel opened this issue Oct 18, 2020 · 1 comment
Open

流量扣除异常 #3

yvhitxcel opened this issue Oct 18, 2020 · 1 comment

Comments

@yvhitxcel
Copy link

acct_middleware.go
第151行,修改前后生成的语句区别如下,问题表现为所有用户的流量信息都被更改了。
_, err = cxt.Session.Cols("available_flow", "available_time").Update(&user)
UPDATE rad_user SET available_time = ?, available_flow = ? []interface {}{0, 197384046}

_, err = cxt.Session.ID(user.Id).Cols("available_flow", "available_time").Update(&user)
UPDATE rad_user SET available_time = ?, available_flow = ? WHERE id=? []interface {}{0, 197384046, 361}

@cometowell
Copy link
Owner

3Q

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants