vuinguyen / FishingDaze

A fishing journal app to document fishing trips, built for my capstone project, for my Udacity iOS Nanodegree program.
1 stars 1 forks source link

Store app state in NSUserDefaults #11

Closed vuinguyen closed 4 years ago

vuinguyen commented 5 years ago

Would this be a good place to store last entered journal entries, such as for fishing places and species caught, so we can auto-populate during an auto-suggest. Have to think about how to use this

vuinguyen commented 4 years ago

Perhaps use UISearchController to do the search?

vuinguyen commented 4 years ago

A few possible tutorials to look at: https://www.hackingwithswift.com/example-code/uikit/how-to-use-uisearchcontroller-to-let-users-enter-search-words

https://www.raywenderlich.com/4363809-uisearchcontroller-tutorial-getting-started

https://developer.apple.com/documentation/uikit/view_controllers/displaying_searchable_content_by_using_a_search_controller

vuinguyen commented 4 years ago

I think the app state I'm going with for the Udacity project submission and review, is to store the temperature unit display, whether it's in Fahrenheit or Celsius

vuinguyen commented 4 years ago

Use the PickYourPitch and VirtualTourist projects for examples of how to store UserDefault values. My idea is to put a switch on the edit window, in the Weather section. The switch will be on the Fahrenheit unit by default.

vuinguyen commented 4 years ago

Got it working:

Simulator Screen Shot - iPhone 8 Plus - 2020-03-03 at 21 54 37

vuinguyen commented 4 years ago

Working commit here: https://github.com/vuinguyen/FishingDaze/commit/573219ffbd3c2721d283d2672098e0130d66d8af

I will call this issue completed and now I will close it!