任何线索为什么以下alamofire发布请求没有将数据传递给后端?任何帮助将非常感激。我也尝试过改变URL编码,但没有运气。
//call WS
let parameters: Parameters=[
"user_id": user.userId!,
"source" : tripSource!,
"source_lat" : tripSourceLat!,
"source_long" : tripSourceLong!,
"dest" : tripDestination!,
"dest_lat": tripDestinationLat!,
"dest_long": tripDestinationLong!
]
//show loading dialog
showActivityIndicator()
Alamofire.request(AppConstant.USER_CREATE_ALERT, method: .post, parameters: parameters, encoding: JSONEncoding.default).responseJSON
{
response in ...