Hi I am developing an application in which i am facing complex UI.
According to design there is a UITableview inside UITableview cell, which is having dynamic data inside it.
The Json response i am getting is also very complex for me.In the response i am getting a member and his tests results it is an easy part but along with this there can be multiple test results and also there can be an additional members as well(for additional members also there are some tests).
So for now i have created a tableview on which i am showing some data and inside that tableview cell i have taken another tableview (having dynamic headers which i have taken to show the name of members) and in rows i am thinking to show the tests for those members.
But i am not getting any proper way to do the same, also facing some logical issues with the data.
It would be great if someone can give better approach for the same.
Json response is as below,
{
"page_size": 20,
"page": 1,
"count": 209,
"results": [
{
"_score": null,
"plink_id": "plifnW",
"customer_name": "Dummy member",
"packages": [
{
"is_addon": false,
"addon_price": 0,
"parameter": 1,
"name": "Test one",
"id": 54,
"package_city_prices": {
"package_price": 160,
"offer_price": 99
},
"slug_name": "Test-one-slug"
}
],
"verification_remark": "Duplicate Booking",
"additional_members": []
},
{
"_score": null,
"plink_id": "plifnW",
"customer_name": "Dummy member two",
"packages": [
{
"is_addon": false,
"addon_price": 0,
"parameter": 1,
"name": "Test One",
"id": 54,
"package_city_prices": {
"package_price": 160,
"offer_price": 99
},
"slug_name": "Test one slug"
}
],
"verification_remark": "Duplicate Booking",
"additional_members": [
{
"plink_id": null,
"alloted_time": null,
"customer_name": "Dummy member three",
"packages": [
{
"is_addon": false,
"tat_time": null,
"name": "Test one",
"slug_name": "Test_one_slug"
},
{
"is_addon": false,
"tat_time": null,
"name": "Test two",
"slug_name": "Test_Two_slug"
},
{
"is_addon": false,
"tat_time": null,
"name": "Test three",
"slug_name": "Test_Three_slug"
},
{
"is_addon": false,
"tat_time": null,
"name": "Test four",
"slug_name": "Test_four_slug"
}
]
}
]
},
{
"_score": null,
"plink_id": "plifnW",
"customer_name": "Dummy member new",
"packages": [
{
"is_addon": false,
"addon_price": 0,
"parameter": 1,
"name": "Test five",
"id": 54,
"package_city_prices": {
"package_price": 160,
"offer_price": 99
},
"slug_name": "test five slug"
}
],
"verification_remark": "Duplicate Booking",
"additional_members": [
{
"plink_id": null,
"alloted_time": null,
"customer_name": "Dummy additional member",
"packages": [
{
"is_addon": false,
"tat_time": null,
"name": "Test one",
"slug_name": "Test_one_slug"
},
{
"is_addon": false,
"tat_time": null,
"name": "Test two",
"slug_name": "Test_Two_slug"
},
{
"is_addon": false,
"tat_time": null,
"name": "Test three",
"slug_name": "Test_Three_slug"
},
{
"is_addon": false,
"tat_time": null,
"name": "Test four",
"slug_name": "Test_four_slug"
}
]
}
]
}
]
}
For better understanding i am attaching design screenshots as well
I have created tableview inside tableviewcell that autosizes. but i am not getting a proper way to parse the data to the inner tableview(which is inside the tableviewcell).