Forum permissions rewrite, forum member suspension, moderator auto-notifications #3

Merged
merged 16 commits into from Jun 15, 2011

Conversation

Projects
None yet
2 participants
Owner

mateusz commented Jun 15, 2011

I think this makes the permissions more intuitive, and you won't need to call $Top or try to fetch the ForumHolder to get the permissions any more. Also, added a proper check on PostMessageForm and doPostMessageForm - previously it was possible to do a direct POST request and circumvent the security settings.

Also, ADMIN can edit members and suspend them from using forums until given date.

And then another feature: moderator notifications can be enabled via the Forum::$notify_moderators - this automatically sends all activity to the moderators of the given forum using the new template.

Plus a bunch of fixes, one of them for example that when you move a thread, its posts would still appear on the old forum when doing search - there is a strange bit of denormalised model down there that links Posts and Forums directly, without passing through Thread.

What do you think?

nlou and others added some commits May 31, 2011

BUGFIX: if a thread (discussion) is turned into Readonly, we disallow…
… replies. For admin/moderators, we still load a discussion data to its AdminFormFeatures so they know what the current discussion's flags.
BUGFIX: When moving a thread across to a new forum, change its posts …
…to that forum. Redirect to the new thread link after the thread has been changed to a new forum, using the new forum's url (a simple flushCache doesn't work here)
BUGFIX: when getting stick topics, a global sticky set is merging to …
…a local sticky set, which can produce duplicated topics in the set, so we need to call removeDuplicates after that.
APICHANGE: add arg to getStickyTopics to either include global sticky…
… topics or not. In a forum view, only show local sticky topics at the top.
APICHANGE: clean up the moderator notifications, add template, add te…
…sts, add a switch to allow switching the feature on and off.
Owner

wilr commented Jun 15, 2011

  • The denormalized structure was needed for performance (avoiding joins). I use ssorg forum to test that as it contains a fairly large dataset. We could offset that by caching more extensively in the front end.
  • Not sure this was meant to be commited - https://github.com/mateusz/silverstripe-forum/blob/master/code/ForumHolder.php#L505. If you want to disable it then we'll need to make static for it. We use it on ssorg for reporting.
Owner

mateusz commented Jun 15, 2011

Re 1. It is still there, untouched. Normann just fixed it so when you move a
thread, also all posts are moved.

Re 2. sorry not sure what you mean? :) The highlighted line doesn't seem to
be new or anything, it was in the original module. Maybe I didn't merge
something.

On Wed, Jun 15, 2011 at 7:01 PM, willrossi <
reply@reply.github.com>wrote:

  • The denormalized structure was needed for performance (avoiding joins). I
    use ssorg forum to test that as it contains a fairly large dataset. We could
    offset that by caching more extensively in the front end.
  • Not sure this was meant to be commited -
    https://github.com/mateusz/silverstripe-forum/blob/master/code/ForumHolder.php#L505.
    If you want to disable it then we'll need to make static for it. We use it
    on ssorg for reporting.

Reply to this email directly or view it on GitHub:

#3 (comment)

Mateusz Uzdowski | Developer
SilverStripe
http://silverstripe.com/

Phone: +64 4 978 7330 xtn 68
Skype: MateuszUzdowski

wilr added a commit that referenced this pull request Jun 15, 2011

Merge pull request #3 from mateusz/master
APICHANGE: Forum permissions rewrite. FEATURE: forum member suspension, moderator auto-notifications

@wilr wilr merged commit 9d64542 into silverstripe:master Jun 15, 2011

Owner

mateusz commented Jun 15, 2011

Thanks :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment