I get below
json
response from webservice and depending on it, I have to add items to the UITableViewCell, like Map View, description UILabel view etc.
... ...
"items": {
"carousel": true,
"description": true,
"map": false,
"options": true
}
... ...
So, if the item says
true
I have to add and if it is
false
I would not add.
I tried to add these
UIViews (NIB files)
to
UITableView
's
contentView
.
But, the
UITableView
height does not grow even though I used UITableViewAutomaticDimension.
I tried some geometry arithmetic but it does not work and I do not want to do that as it is not really that dynamic.
Can someone please tell how can I get
UITableViewAutomaticDimension
work for this?
Sample UIView designs (sceenshots) below.
map item UIView would look like below.
carousel
items looks like below.And
description
item looks like below.And
options
item looks like below.