【发布时间】:2016-09-28 12:36:19
【问题描述】:
我正在尝试使用 Angular 1.x 在按钮单击时发送数据。
这是来自客户端的调试,对象似乎设置正确:
这是来自服务器端的调试,值丢失了:
还有我的 POCO:
[Serializable]
public class Item
{
public int Id { get; set; }
public string Key { get; set; }
public int Value { get; set; }
public string Description { get; set; }
}
更新:
这可行,但相当丑陋......
我可以摆脱转换并使用Item类型作为参数,而不是JObject吗?
【问题讨论】:
标签: javascript c# angularjs ajax asp.net-web-api