//不够6位的前补0
uiUserCode, _ := strconv.Atoi(c.PostForm("ui_user_code"))
item.UserCode = fmt.Sprintf("%06d", uiUserCode)
golang 前补0
最新推荐文章于 2024-04-05 15:49:57 发布
//不够6位的前补0
uiUserCode, _ := strconv.Atoi(c.PostForm("ui_user_code"))
item.UserCode = fmt.Sprintf("%06d", uiUserCode)