2016-09-25 46 views

回答

0

你應該把它們放到一個對象,並使用Restangular

obj = { 
pid: pid.toString() 
selectedUsers: selectedUsers 
uid: uid.toString() 
} 
Restangular.one(url).post(obj).then(function(res){ 
    // do something 
}) 

Restangular.one(url).post({ 
    pid: pid.toString() 
    selectedUsers: selectedUsers 
    uid: uid.toString() 
}).then(function(res){ 
    // do something 
}) 
0

此代碼不becouse我的反手服務工作不recerve這種格式。 例如,y反手代碼是:

+0

[HttpPost] [Route(「assign/{pid}/{changedBy}」)] public HttpResponseMessage AssignUserToProject(int pid,List uid, int changedBy) – Stefnaister90