coral
  •  coral
  • 72% (Friendly)
  • YAF Lover Topic Starter
2014-02-23T19:32:15Z
Is it not better that when we are in a category page, which shows only the forums under that category, latest discussions were also be related to the category shown and not latest discussions of all forums?
Sponsor
Zero2Cool
2014-02-24T13:51:56Z
I think it'd be simple to implement. Add a True/False field in the Settings for "Show latest discussions by category".

For my own personal curiosity, can you explain why this has value?
coral
  •  coral
  • 72% (Friendly)
  • YAF Lover Topic Starter
2014-02-24T14:33:06Z
Originally Posted by: Zero2Cool 

I think it'd be simple to implement. Add a True/False field in the Settings for "Show latest discussions by category".



My problem is how I can dsiplay latest discussions by category? I searched the source code I couldn't find an easy way to do it. The function that get the latest discussions only has boardId as parameter and not categoryid.
public static DataTable topic_latest([NotNull] object boardID, [NotNull] object numOfPostsToRetrieve, [NotNull] object pageUserId, bool useStyledNicks, bool showNoCountPosts, [CanBeNull]bool findLastRead)
        

Quote:

For my own personal curiosity, can you explain why this has value?


users may only be intersted in some category of the forum and not all, therefore visit only those category pages. I thought that it make more sence if only topics under displaying category are shown in latest discussion.
Zero2Cool
2014-02-24T14:52:44Z
You could grab the Category ID from the URL. Then pass that ID through a stored procedure that returns the values based on the Category ID parameter. I don't know if the current stored proc has this so you might need to write your own stored proc.

Bah, nevermind that idea. I was thinking that you were creating your own latest discussion block, but you're wanting to modify the existing one. Perhaps modify the source code to include Category ID parameter. Modify the stored procedure as well?
tha_watcha
2014-03-01T15:37:24Z
Originally Posted by: coral 

Is it not better that when we are in a category page, which shows only the forums under that category, latest discussions were also be related to the category shown and not latest discussions of all forums?



It is not better, i would call that a bug. This is fixed in 2.1.1.


UserPostedImage

About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button

Project Twitter Updates

Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved