When I tried to apply it with CoreStore, I couldn't give multiple arguments to list monitor's sectionBy(...). which matches with groupBy in coredata as far as I can understand.
Is there a way to apply coredata solution mentioned in the link with CoreStore?
Or do I need something else to represent items in nested sections like the sketch above?
Originally created by @eraydiler on GitHub (Feb 14, 2019).
Hello,
I need to display some data in nested sections like;
Section
-SubSection
--Item
--Item
Section
-SubSection
--Item
-SubSection
--Item
--Item
--Item
...
Also need to track any changes and reflect them in the UI with listmonitor.
I found this question with a coredata related solution;
https://stackoverflow.com/questions/37203272/nested-sections-in-uitableview-and-core-data
When I tried to apply it with CoreStore, I couldn't give multiple arguments to list monitor's sectionBy(...). which matches with groupBy in coredata as far as I can understand.
Is there a way to apply coredata solution mentioned in the link with CoreStore?
Or do I need something else to represent items in nested sections like the sketch above?
You'll need to process the indexPaths for the second-level sections yourself. NSFetchedResultsController, which ListMonitor runs on top of, was designed for UITableViews and UICollectionViews, which support only one level of sectioning.
The stackoverflow thread you linked gave an answer that throws out NSFetchedResultsController altogether and simply queries the store for an array of Dictionarys. What it doesn't say is it would still return just the first-level sections and not the inner section. You will still need to process the second-level sections by hand.
@JohnEstropia commented on GitHub (Feb 14, 2019):
You'll need to process the indexPaths for the second-level sections yourself. `NSFetchedResultsController`, which `ListMonitor` runs on top of, was designed for `UITableView`s and `UICollectionView`s, which support only one level of sectioning.
The stackoverflow thread you linked gave an answer that throws out `NSFetchedResultsController` altogether and simply queries the store for an array of `Dictionary`s. What it doesn't say is it would still return just the first-level sections and not the inner section. You will still need to process the second-level sections by hand.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Originally created by @eraydiler on GitHub (Feb 14, 2019).
Hello,
I need to display some data in nested sections like;
Section
-SubSection
--Item
--Item
Section
-SubSection
--Item
-SubSection
--Item
--Item
--Item
...
Also need to track any changes and reflect them in the UI with listmonitor.
I found this question with a coredata related solution;
https://stackoverflow.com/questions/37203272/nested-sections-in-uitableview-and-core-data
When I tried to apply it with CoreStore, I couldn't give multiple arguments to list monitor's sectionBy(...). which matches with groupBy in coredata as far as I can understand.
Is there a way to apply coredata solution mentioned in the link with CoreStore?
Or do I need something else to represent items in nested sections like the sketch above?
@JohnEstropia commented on GitHub (Feb 14, 2019):
You'll need to process the indexPaths for the second-level sections yourself.
NSFetchedResultsController, whichListMonitorruns on top of, was designed forUITableViews andUICollectionViews, which support only one level of sectioning.The stackoverflow thread you linked gave an answer that throws out
NSFetchedResultsControlleraltogether and simply queries the store for an array ofDictionarys. What it doesn't say is it would still return just the first-level sections and not the inner section. You will still need to process the second-level sections by hand.@eraydiler commented on GitHub (Feb 14, 2019):
Got it, thanks for the answer.