boonebgorges / buddypress-docs

GNU General Public License v3.0
106 stars 44 forks source link

Update "last modified" date for folders based on their contents. #689

Closed dcavins closed 3 years ago

dcavins commented 3 years ago

Update the containing folders' last_modified date when docs are updated. See #688.

boonebgorges commented 3 years ago

I like these changes - if they test OK on your end, feel free to merge into 2.2.x :ship:

dcavins commented 3 years ago

Thanks, Boone!

dcavins commented 3 years ago

One thing I think I got backwards in this: I assumed that the folder sort order should be by name, because that's how they were ordered before. However, when you first visit the docs library with no "orderby" specified, the docs are sorted by modified date, and the "sort" indicator appears above the "Last Edited" column.

Do you think the default folder sort order should change from what it was and be by last modified? It would break the old behavior, but it would make the UI more consistent. Thanks!

boonebgorges commented 3 years ago

IMO, it feels natural for the default sort order of Docs to be by post_modified, but for folder sorting to be by name. Does this seem right to you? If so, can you figure out a way to put a toggle in the interface for listing folders so that we could take advantage of the 'modified' sort, but only as a secondary option rather than the default?