.net list<int>、int[]参数类型 前端调用传参方法
$.ajax({ type: "POST", url: "/controller/action", data: { "Filesid": 数组 }, traditional: true,//用传统方式序列化数据 dataType: "json", cache: true, success: function (data) { },
后端:list<int> Filesid 类型参数
$.ajax({ type: "POST", url: "/huizhendetail/DelSHExpertFiles", data: { //Filesid: {0:20} JSON.stringify(a) Filesid: { 0:12,1:23 } }, traditional: true,//用传统方式序列化数据 dataType: "json", cache: true, success: function (data) { if (data.StatusCode == 'ok') { } else { layer.msg(data.Message); } },
后端: int[] Filesid 类型参数