MVC3异步调用问题
onExpandRow: function (index, row) {
$('#ddv-' + index).datagrid({
url: '@Url.Action("Pos", "Resume")'
[HttpPost]
public JsonResult Pos()
{
int total = 0;
int resumeID=10057;
List<PositionResume> posresumes = new List<PositionResume>();
posresumes = posresumeService.GetPositionResumsList(resumeID, ref total);
Dictionary<string, object> json = new Dictionary<string, object>();
json.Add("total", total);
json.Add("rows", posresumes);
return Json(json, JsonRequestBehavior.AllowGet);
}
以上异步调用能运行到JsonResult Pos(),可为以下什么异步调用却运行不到JsonResult Pos(int resumeID)呢?
onExpandRow: function (index, row) {
$('#ddv-' + index).datagrid({
url: '@Url.Action("Pos", "Resume")/' + row.resumeID,
[HttpPost]
public JsonResult Pos(int resumeID)
{
int total = 0;
List<PositionResume> posresumes = new List<PositionResume>();
posresumes = posresumeService.GetPositionResumsList(resumeID, ref total);
Dictionary<string, object> json = new Dictionary<string, object>();
json.Add("total", total);
json.Add("rows", posresumes);
return Json(json, JsonRequestBehavior.AllowGet);
}
------解决方案--------------------
onExpandRow: function (index, row) {
$('#ddv-' + index).datagrid({
url: '@Url.Action("Pos", "Resume")?resumeID=' + row.resumeID,