RegisterRoutes
public static void RegisterRoutes(RouteCollection routes)
{
routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
routes.MapRoute(
name: "API",
url: "api/{controller}/{id}",
defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
);
routes.MapRoute(
"Default",
"{*catchall}",
new { controller = "Home", action = "Index" }
);
routes.AppendTrailingSlash = true;
}
函数angulajs
this.submitGestHonoFormH = function (std) {
$http.post('/api/sasie/formulaire/', { student: std }, { headers: { 'Content-Type': 'application/json' } })
};
- 调试时,永远不会将formDate学生分配给他。始终为NULL。有人遇到这个问题吗?