Shared collections in a group don't display for the admins

Bug #1558246 reported by Melvin Romero on 2016-03-16
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Mahara
Medium
Jean-Philippe Gaudreau
15.04
Medium
Unassigned
15.10
Medium
Unassigned

Bug Description

Hi guys!

I don't know if this is a regression from 1.10, but we found a major bug in our 15.04.5 Mahara. In short, when members in a group submit their collections, the admins of that group cannot see them. I attached a screenshot for you to see. I also tested in a vanilla 15.04.5 installation in order to be sure and I was still able to reproduce the bug.

So, here are the steps to make it happen:

*This test requires you to have an evaluation group with at least one member, at least 1 collection.

1. Go into the group as admin
2. Submit a collection
3. Check if the collection appears under the "Collections shared with this group" title
4. Now, with a member of that same group, follow the same steps.

Result: The collections are never listed under the "Collections shared with this group".

As always, thanks for your help!

Melvin

Melvin Romero (melrom49) wrote :
Melvin Romero (melrom49) wrote :

Hi again,

I just tried it on the master branch and I couldn't reproduce the problem! So I guess it was fixed somewhere between 15.10 and 16.x?

Anyway, would it be possible to backport the fix into 15.04.5?

Robert Lyon (robertl-9) wrote :

Hi Melvin,

When we first added the extra options to the group homepage's 'Group pages' block there was a small issue with what is displayed. Normally this can be fixed by editing the page, editing the block and re-saving the block so the correct settings are set in the database.

Let me know if that works for you - or if the problem persists

Cheers

Robert

Changed in mahara:
status: New → Incomplete

Hi Robert,

You are right about this workaround but still we have the problem every time a new group is created which is not good. I dug the code a bit and found out that the problem is related to the groupviews block from the default group home page view not having the showsharedcollections config in the configdata (I compared with a fresh install from master branch).

I searched in the tracker and found that you fixed a bug (https://bugs.launchpad.net/mahara/+bug/1491639) related indirectly to this problem but it wasn't backported in 15.04 which which I'm wondering why because there's a patch for it in the last comment.

My first plan was to backport this fix in 15.04 but reading the code, I think it will have an unexpected side effect because it will change the config of the groupviews from the default home page and all the others to 2 (showbyanybody) when it should be 1 (showbygroupmembers) -> See the default configs when installing from scratch in install_system_grouphomepage_view function (lib/group.php).

What are your thoughts about this? I think there should be at least a fix upgrade correcting the groupviews from default group because all the Mahara installations pre 15.10 will have the wrong default config after upgrade.

Thanks a lot for you help!

J-P

Changed in mahara:
status: Incomplete → In Progress
assignee: nobody → Jean-Philippe Gaudreau (jp-gaudreau)

Here's a patch for the master branch. I limited the fix to resetting the values for the group page of the default group home page view (template) because I don't see anything else being done without creating another side effect...

To test:
* Create a new 15.04_STABLE instance
* Upgrade to latest version (master)
* Assert in column configdata of db table block_instance that the values for showsharedviews and showsharedcollections is 1.

I tried to backport this fix to 15.10_STABLE but I get the error:
"ERROR: Version number in htdocs/blocktype/groupviews/version.php has gone up too much for a stable branch!"

What would be the right way to do it?

And I'm not sure what to do for 15.04 because I would have to create a fix that includes 1491639 code but I need more details why it wasn't backported before doing more work.

Cheers!

Changed in mahara:
status: In Progress → Incomplete
assignee: Jean-Philippe Gaudreau (jp-gaudreau) → nobody
Changed in mahara:
assignee: nobody → Jean-Philippe Gaudreau (jp-gaudreau)
status: Incomplete → In Progress
Changed in mahara:
milestone: none → 16.04.0
importance: Undecided → Medium

Reviewed: https://reviews.mahara.org/6264
Committed: https://git.mahara.org/mahara/mahara/commit/c441636843a0c0f3f44f3d69fc8dc0e352274f39
Submitter: Robert Lyon (<email address hidden>)
Branch: master

commit c441636843a0c0f3f44f3d69fc8dc0e352274f39
Author: Jean-Philippe Gaudreau <email address hidden>
Date: Wed Mar 23 14:04:16 2016 -0400

Bug 1558246: Reset default group page shared settings

We need to reset 'showsharedviews' and 'showsharedcollections' values
to 'By members of this group' for the default group home page because
they were wrongly modified.

behatnotneeded

Change-Id: I01b9eeb12af5db2c2a639bbaea24cd1f6b44b93e

Robert Lyon (robertl-9) on 2016-03-29
Changed in mahara:
status: In Progress → Fix Committed
Changed in mahara:
status: Fix Committed → Fix Released
summary: - Submitted collections in a group don't display for the admins
+ Shared collections in a group don't display for the admins

Reviewed: https://reviews.mahara.org/6468
Committed: https://git.mahara.org/mahara/mahara/commit/7378f7e09be887c5b57978190bd9337fc2374ae0
Submitter: Robert Lyon (<email address hidden>)
Branch: 15.10_STABLE

commit 7378f7e09be887c5b57978190bd9337fc2374ae0
Author: Jean-Philippe Gaudreau <email address hidden>
Date: Wed Mar 23 14:04:16 2016 -0400

Bug 1558246: Reset default group page shared settings

We need to reset 'showsharedviews' and 'showsharedcollections' values
to 'By members of this group' for the default group home page because
they were wrongly modified.

behatnotneeded

Change-Id: I01b9eeb12af5db2c2a639bbaea24cd1f6b44b93e

Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/6470
Committed: https://git.mahara.org/mahara/mahara/commit/3d3d66f8df4d9afa3f8f0348cad3ad721dce0410
Submitter: Robert Lyon (<email address hidden>)
Branch: 15.04_STABLE

commit 3d3d66f8df4d9afa3f8f0348cad3ad721dce0410
Author: Jean-Philippe Gaudreau <email address hidden>
Date: Wed Mar 23 14:04:16 2016 -0400

Bug 1558246: Reset default group page shared settings

We need to reset 'showsharedviews' and 'showsharedcollections' values
to 'By members of this group' for the default group home page because
they were wrongly modified.

behatnotneeded

Change-Id: I01b9eeb12af5db2c2a639bbaea24cd1f6b44b93e

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers