The "latest posts" on a discussion landing page, and the Post results when searching a forum (or the whole app) link to a single post but it would be much nicer to link to the thread with a #target, so you can read all the context.
Pagination could be a tricky, since a post might not be on the first page of the thread, and user preferences can set different items per page (iirc). Find the existing logic for the "link" link on each comment, perhaps that can be re-used. It does account for pagination.
We can also limit the Forum search to Post documents (no Thread docs).
Make sure this works in general, including the 'latest post' links on the Forum tool index page.
Diff:
Created #166: [#4077] change ForumPost links to go to thread url, with target (2cp)
Related
Tickets:
#4077Closed #166. Branch 42cc_4077.
Note: there is some marginal slowdown for the extra mongo queries, we could do some per-request caching in case the same thread is listed multiple times in a search result page, but I don't think that is necessary at this point.