GinHello icon indicating copy to clipboard operation
GinHello copied to clipboard

int转string

Open OpenCreate opened this issue 4 years ago • 0 comments

https://github.com/youngxhui/GinHello/blob/e6d9dfd267ba51cd1defe4f7e22dfa8218334976/handler/userHandler.go#L38 这里如果是将整数直接转为字符串显示,应该考虑使用 strconv.FormatInt((int64(u.Id)) string(u.Id) 将生成一个rune 值为 u.Id 值的字符串。

OpenCreate avatar Oct 17 '21 09:10 OpenCreate