我有一个这样的 JSON。
[
{
"created_at": "2012-05-07T19:17:16Z",
"id": 80,
"order_date": "2012-05-07 22:17:14",
"order_done": false,
"order_total": "14.7",
"order_uuid": "e10655868d12d9855b83e02efb026eef056f1d92",
"updated_at": "2012-05-07T19:17:17Z",
"order_details": [
{
"created_at": "2012-05-07T19:17:17Z",
"food_count": 2,
"food_name": "Baileys Shaken with Ice",
"food_place": "El Gringo Music Saloon",
"food_price": "8.4",
"id": 146,
"order_id": 80,
"updated_at": "2012-05-07T19:17:17Z"
},
{
"created_at": "2012-05-07T19:17:17Z",
"food_count": 1,
"food_name": "Baileys Irish Martini",
"food_place": "O'Malley's",
"food_price": "6.3",
"id": 147,
"order_id": 80,
"updated_at": "2012-05-07T19:17:17Z"
}
]
}
]
现在我想将它们从 iOS 发送到 Ruby Web 服务。
是否可以使用一个请求 POST 将它们发送到 Web 服务?
现在我使用 2 个请求 POST 或 1 个请求 POST 和 1 个请求 UPDATE => ITS BAD!!!!