I store the dates in the main attribute data object, I then show the date in the table cells. I want to group all cells by month and only display the corresponding dates in the correct sections.
I am using sectionNameKeyPath from NSFetchedResultsController, but I only need to use the month in the date group. How can i achieve this? Will I need to create a new attribute and store only a month as a string, or can I use NSPredicate?
Please let me know if they did this or gave me examples.
thank
, , , , . , , , . NSDateComponents . . , NSFetchedResultsController, , sectionNameKeyPath. , , getMonth, , , sectionNameKeyPath. , . , .
NSDateComponents
sectionNameKeyPath
. , , ( ) Table View .
Apple , , . , , .
: http://developer.apple.com/library/ios/#samplecode/DateSectionTitles/Introduction/Intro.html#//apple_ref/doc/uid/DTS40009939
Source: https://habr.com/ru/post/1739547/More articles:Event registration from another topic - multithreadingIronPython overrides __setattr__ and __getattr__ - c #using Spring JdbcTemplate for multiple database operations - javaKeep-alive for long-term HTTP session (non-persistent HTTP) - httpWhy does the checkbox attribute "checked" return the actual value opposite to it on a click event? - javascriptWhat proprietary C ++ profiling tool do you offer? - c ++Matplotlib digits grouping (decimal separator) - pythonCoding segment length jpg - jpegIs inheritance in a C # question an override of internal methods? - inheritancePython mysql validate duplicate before insertion - pythonAll Articles