智慧食堂
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 line
245 B

  1. package utils
  2. import (
  3. "bytes"
  4. "encoding/json"
  5. )
  6. func JsonMarshal(interface{}) {
  7. }
  8. // 不科学计数法
  9. func JsonDecode(data []byte, v interface{}) error {
  10. d := json.NewDecoder(bytes.NewReader(data))
  11. d.UseNumber()
  12. return d.Decode(v)
  13. }