0

Can you please tell me how can I create those in swift? I have json that looks like this:

{
    1 = [
      title = "A",
      title = "B",
      title = "C"
    ],
    2 = [
      title = "A",
      title = "B"
    ],
    3 = [
      title = "D",
      title = "E",
      title = "F",
      title = "G"
    ]
}

I need to make a tableView with it that shows only cells with numbers. After I click on the cell it expands and shows different cells with letters after it. Also I have UILabel at the top of the tableView that changes it title with letter when I click on the letter cell.

JSON can change so I need to create dynamic model.

Thank you! Sorry if this question was already asked, but I can't find specific guide for this type of situation. Thank you again.

Dmitrij Rogov
  • 183
  • 1
  • 2
  • 9
  • refer this link, [Expandable cell](http://stackoverflow.com/questions/26217480/expand-cell-when-tapped-in-swift) hope this will help you. – KAR Sep 20 '16 at 06:34
  • You can refer [Git example](https://github.com/jeantimex/ios-swift-collapsible-table-section) – miOS Sep 20 '16 at 06:41
  • ok i want to do same thing and done with solution Of @jef there easy and working http://stackoverflow.com/questions/27729150/expanding-and-collapsing-tableview-sections-ios – Prashant Tukadiya Sep 20 '16 at 07:06

0 Answers0