Migrated from Redmine #575 | Author: Dhanushka Krishnajith
Status: Resolved | Priority: High, I’m very impatient | Created: 2020-09-23
I am adding products with multiple bookings. Below is the request.
Account: vicinitytest
{
"jsonrpc": "2.0",
"method": "book",
"params": [
"16",
10,
"2020-09-30",
"10:00:00",
{
"name": "xx",
"email": "xx",
"phone": "xx"
},
{
"ageRange": "26-49",
"subscribe": true,
"products":[{"id":"2","qty":1}]
},
2
],
"id": 7
}
However, this adds product for each booking resulting in 2 products added. See the response from “getBookingCart” below. Is it possible to add product to just for the first booking while booking multiple? What is the recommended way of booking multiple and attach products to only to one?
{
"result": {
"amount": 68,
"currency": "AUD",
"cart": [
{
"booking_id": "190",
"item_id": "16",
"event_id": "16",
"name": "Multi booking 1 09.30.2020 10:00 AM",
"event_name": "Multi booking 1",
"price": "10.0000",
"currency": "AUD",
"qty": 1,
"type": "booking"
},
{
"booking_id": "2",
"item_id": "2",
"price": "24.0000",
"currency": "AUD",
"qty": "1",
"name": "Santa key ring",
"type": "product"
},
{
"booking_id": "191",
"item_id": "16",
"event_id": "16",
"name": "Multi booking 1 09.30.2020 10:00 AM",
"event_name": "Multi booking 1",
"price": "10.0000",
"currency": "AUD",
"qty": 1,
"type": "booking"
},
{
"booking_id": "2",
"item_id": "2",
"price": "24.0000",
"currency": "AUD",
"qty": "1",
"name": "Santa key ring",
"type": "product"
}
],
"cart_id": "22",
"cart_hash": "8056efe0b7f9e965d400daa0057b8aaa",
"status": "not_paid"
},
"id": "5",
"jsonrpc": "2.0"
}