Deleting a group doesn't delete its views and artefacts

Bug #913536 reported by Richard Mansfield
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
Medium
Richard Mansfield

Bug Description

See Kristina's comment on https://reviews.mahara.org/#change,972:

"One thing I noticed though: When you have a group file in a personal portfolio page that file will still be available after you delete the group and all its files. Is that correct? There is no way to transfer that file into your own files area (except for downloading and re-uploading) as it in a way does not exist on Mahara anymore."

It seems that in the database, group views, artefacts, and forum posts survive after the group has been deleted. You can no longer access them directly, but as Kristina says, files will still be accessible if they were previously included in other views not owned by the group (but they can't be added to any new blocks).

I think we should probably just delete all group stuff when the group is deleted.

The other option would be to check whether the group is deleted before displaying group artefacts (this is what happens for views and forums). I suppose the advantage of doing it that way is that we could one day allow people to restore deleted groups, if we thought that was worthwhile.

Tags: groups
Changed in mahara:
status: New → Triaged
importance: Undecided → Medium
Changed in mahara:
assignee: nobody → Richard Mansfield (richard-mansfield)
milestone: none → 1.5.0
tags: added: groups
Changed in mahara:
status: Triaged → Fix Committed
Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/976
Committed: http://gitorious.org/mahara/mahara/commit/a7512716e508640d3c63a745da3cc4deb6ff0745
Submitter: Francois Marier (<email address hidden>)
Branch: master

commit a7512716e508640d3c63a745da3cc4deb6ff0745
Author: Richard Mansfield <email address hidden>
Date: Mon Jan 9 13:28:25 2012 +1300

    Delete group files and views when deleting groups (bug #913536)

    Most group data was not being deleted along with the group. This
    patch ensures all group views and artefacts are deleted when a group
    is deleted, and that any views submitted to the group are released.
    Forums are deleted using the delete method of InteractionInstance, but
    this just marks the forum as deleted rather than wiping the data.

    Change-Id: If160ebde3bf7c20d92929986fe70ad9e3853c6be
    Signed-off-by: Richard Mansfield <email address hidden>

Revision history for this message
François Marier (fmarier) wrote :
Melissa Draper (melissa)
Changed in mahara:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.