我有我的故事板是這樣的:嵌套導航控制器和TabBar控制器
TabBarViewController
|-NavigationViewController
|-TableViewController
這有助於我必須在TableViewController同時導航欄和標籤欄。
現在我想添加一個SecondViewController來顯示在表中選擇的項目的細節。所以我這樣做:
TabBarViewController
|-NavigationViewController
|-TableViewController
|-SecondViewController
但SecondViewController不顯示導航欄。所以,我想這一點:
TabBarViewController
|-NavigationViewController
|-TableViewController
|-NavigationViewController
|-SecondViewController
但仍處於SecondViewContrller沒有導航欄。 我錯過了什麼?
您只需要一個NavigationViewController。你在使用segues嗎?如果是這樣,是否有一個連接TableViewController到SecondTableViewController的segue? – Jordan
是的,當我不使用第二個導航控制器時,我有一個從「TableViewController」到「SecondViewController」的「顯示」segue。 – Kashif