[RFC|Merged] Link global announcements to forums

These requests for comments/change have lead to an implemented feature that has been successfully merged into the 3.1/Ascraeus branch. Everything listed in this forum will be available in phpBB 3.1.
User avatar
nickvergessen
Former Team Member
Posts: 733
Joined: Sun Oct 07, 2007 11:54 am
Location: Stuttgart, Germany
Contact:

[RFC|Merged] Link global announcements to forums

Post by nickvergessen »

Hi guys,

I had two ideas coming up on my mind regarding the GA-Dilemma we had since they exist.
The most common problems are the permissions. So far you have the permissions of the forum, you are currently in.

Now I had two possible ideas, which have Pros and Cons:
  1. Link Global Announcement to the forum they got posted in:
    • Pros:
      • Permissions are always the same, as they are taken from the forum they are linked to and it's independent from the forum you are currently visiting.
      • You can easily change the permissions for the users. (Use normal "Move Topic"-Function)
      • Most users seem to expect that they behave like that already
      • Less code needs to be changed
    • Cons:
      • Not all topics in the forum have the same permissions:
        You view Forum A and see two GA (one linked to Forum A the other one to Forum B).
  2. Create hidden Forum (similar to ANONYMOUS-User):
    • Pros:
      • All GA have always the same permissions.
      • You can individually set the permissions for GAs and it's independent from the forum you are currently visiting.
    • Cons:
      • More code needs to be changed
      • New forum must be created and the forum_id stored to the constants.php => to complicated on update from 3.0?
      • Still not the way the "dumb" user expects it to be
    [/color]
I would prefer the first option. What would you guys think?

Ticket: http://tracker.phpbb.com/browse/PHPBB3-9684
Pull Request: https://github.com/phpbb/phpbb3/pull/69
Last edited by nickvergessen on Thu Mar 25, 2010 11:59 am, edited 1 time in total.
Member of the Development-TeamNo Support via PM

code reader
Registered User
Posts: 653
Joined: Wed Sep 21, 2005 3:01 pm

Re: Global Announcements in 3.1

Post by code reader »

how about just create a special "global announcement permission" which is absolutely completely promiscuous, and use it for all global announcements? this can completely bypass the $auth->acl_getxx mechanism for global announcements?
just a thought.

User avatar
nickvergessen
Former Team Member
Posts: 733
Joined: Sun Oct 07, 2007 11:54 am
Location: Stuttgart, Germany
Contact:

Re: Global Announcements in 3.1

Post by nickvergessen »

that's what way2 would behave like.
But i guess adding another case of global permissions is way to have.
Member of the Development-TeamNo Support via PM

User avatar
naderman
Consultant
Posts: 1727
Joined: Sun Jan 11, 2004 2:11 am
Location: Berlin, Germany
Contact:

Re: Global Announcements in 3.1

Post by naderman »

One thing that a lot of people dislike about Global Announcements is the fact that they are in fact global rather than just "interregional" ;-) Meaning it would be nice if you could select which forums a particular announcement should show up on. This would require the addition of a new n:n forum:topic relationship table. I'm not sure how big a performance hit this would be, or whether one can implement it without much trouble. Those relationships might be cachable if you only have very few, but that would really make it impossible to use the feature for anything but announcements. Now if you went this route you wouldn't want every "global" announcement to have the same permissions, but permissions that fit to the area it was posted in. So I think if we were to implement this we should go the route of having the global announcement being located in one forum and just "linked" into the others.

User avatar
nickvergessen
Former Team Member
Posts: 733
Joined: Sun Oct 07, 2007 11:54 am
Location: Stuttgart, Germany
Contact:

Re: Global Announcements in 3.1

Post by nickvergessen »

naderman wrote:So I think if we were to implement this we should go the route of having the global announcement being located in one forum and just "linked" into the others.
That's my first way and I'm currently looking how much work that is.

With interregional you mean something like you can select in which forums a GA should be displayed? Like leaving a always up-to-date shadow-topic?
Member of the Development-TeamNo Support via PM

User avatar
naderman
Consultant
Posts: 1727
Joined: Sun Jan 11, 2004 2:11 am
Location: Berlin, Germany
Contact:

Re: Global Announcements in 3.1

Post by naderman »

Yup, pretty much. That would actually be another way to implement it. Simply create a topic table entry for each forum it is supposed to show up in and then update them all when changes are made. That's not really nice or normalised, but it should be a lot better for viewing performance. You might get into trouble if anything ever goes out of sync.

User avatar
nickvergessen
Former Team Member
Posts: 733
Joined: Sun Oct 07, 2007 11:54 am
Location: Stuttgart, Germany
Contact:

Re: Global Announcements in 3.1

Post by nickvergessen »

naderman wrote:Yup, pretty much. That would actually be another way to implement it. Simply create a topic table entry for each forum it is supposed to show up in and then update them all when changes are made. That's not really nice or normalised, but it should be a lot better for viewing performance. You might get into trouble if anything ever goes out of sync.
I would have expected more than the bit that was affected from the root/ files:
http://github.com/nickvergessen/phpbb3/ ... ouncements

But I guess includes/ will be a "little" more with the mcp and the read/unread-stuff in it
Member of the Development-TeamNo Support via PM

User avatar
A_Jelly_Doughnut
Registered User
Posts: 1780
Joined: Wed Jun 04, 2003 4:23 pm

Re: Global Announcements in 3.1

Post by A_Jelly_Doughnut »

The Olympus implementation of Global Announcements is awkward at times. However, so is handling of the user ANONYMOUS. :P

One thing that bothers me is that globals do not trigger an unread flag on the board. Say you have a small board where the only topic having been replied to since your last visit is a global announcement: you wouldn't know unless you went in and viewed a forum. Option (a) is the only one that could solve that.

I took a quick look at nickvergessen's github patch. Looks pretty good :D
A_Jelly_Doughnut

User avatar
MattF
Extension Customisations
Extension Customisations
Posts: 675
Joined: Mon Mar 08, 2010 9:18 am

Re: Global Announcements in 3.1

Post by MattF »

A_Jelly_Doughnut wrote:One thing that bothers me is that globals do not trigger an unread flag on the board.
Yeah, anything to address this would be nice.
Has an irascible disposition.

User avatar
nickvergessen
Former Team Member
Posts: 733
Joined: Sun Oct 07, 2007 11:54 am
Location: Stuttgart, Germany
Contact:

Re: Global Announcements in 3.1

Post by nickvergessen »

A_Jelly_Doughnut wrote:One thing that bothers me is that globals do not trigger an unread flag on the board.
This was fixed by rxu, the first visible forum should be marked unread.
Member of the Development-TeamNo Support via PM

Post Reply