原文: Hi there, I just discovered Go and decided to port a little program to Go. The program reads JSON-Data from an URL and process the Data. The Go port works well till now. I dont have any influence on the JSON data and so sometimes there are contro…
一.背景 在MVC3项目里,如果Action的参数中有Enum枚举作为对象属性的话,使用POST方法提交过来的JSON数据中的枚举值却无法正确被识别对应的枚举值. 二.Demo演示 为了说明问题,我使用MVC3项目创建Controller,并且创建如下代码演示: //交通方式枚举 public enum TrafficEnum { Bus = , Boat = , Bike = , } public class Person { public int ID { get; set; } publi…