Commit 924eee76 authored by shajiaiming's avatar shajiaiming

币种更新 权限 验证

parent 320f686d
......@@ -212,14 +212,10 @@ func EditCoin(c *gin.Context) {
coin_model := coin_service.Coin{Id: coin.Id}
coin_exist, _ := coin_model.Get()
if coin.PlatformId != coin_exist.PlatformId {
handler.SendResponse(c, errno.ErrAuthCoin, nil)
return
}
if ("administrator" != group) {
if coin.PlatformId != auth.PlatformId {
handler.SendResponse(c, errno.ErrUserTokenIncorrect, nil)
if (coin.PlatformId != auth.PlatformId) || (auth.PlatformId != coin_exist.PlatformId){
handler.SendResponse(c, errno.ErrAuthCoin, nil)
return
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment