Json data to the front end of the background, the background reception

jsondata = [{"id": 12,"name": "小明"}, {"id": 13,"name": "小红"}]

By converting the JSON.stringify () to a string, with the background of the character string can be received

var jsondata = JSON.stringify (jsondata); 

background can be converted into a string json objects JSONArray.parseArray
List<ShopProductAddRespVo> list = (List<ShopProductAddRespVo>) JSONArray.parseArray(jsondata, ShopProductAddRespVo.class);

Guess you like

Origin www.cnblogs.com/package-java/p/12204315.html