JsonException01:

2019-07-13  本文已影响0人  浪荡少年

一、

JsonException: Max allowed object depth reached while trying to export from type System.Single

Json不能识别float数据类型,请转化成double!!!!!

二、

JsonException: Can't assign value '0' (type System.Int32) to type System.Int64

需在JsonMapper这个类中的RegisterBaseImporters方法中添加

RegisterImporter<int, long>((int value) =>

{

    return (long)value;

});

放到方法最后面就好了

上一篇 下一篇

猜你喜欢

热点阅读