When i call api using Alamofire like this
Alamofire.request(.POST, "http://localhost:8080/xxx/xxx/xxx/xx").responseJSON() {
(_, _, jsonData, error) in
if error == nil{
var newItem=JSON(jsonData!)
println(newItem)
}
else{
println("Nothing!")
}
}
And I got many json format which include {"header","body"}. Header are like this
"header" : {
"toPage" : "3948",
"totalCount" : "59212",
"lotId" : "50205",
"vendorName" : "TOYOTA",
"rowPerPage" : "15",
"fromPage" : "1",
"currentPage" : "1",
"modelName" : "LEXUS LS"
}
The body string include 15 rows per page including many data like this,i gonna show you one only.
"body" : [
{
"id" : "5AxYKWbiqn451Y",
"priv" : "",
"average" : "395000",
"equip" : "",
"chassis" : "DA63T"
},
Everytime i request,it give me 15 results.All i want is to show this in table view using table cell,label and image view like this
So,any suggestion how to do that in code to create better performance.i mean do i need to store data first in some array and display them in the table view.All i need is four data from the body "vendorName,image0,mileage,modelName".So there are one image view,three labels in the table view as i show at above figure.Any Code Help and Suggestion is appreciated.