moved old table view code