Cover image file not copied for institution collection

Bug #1892105 reported by Kristina Hoeppner
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
High
Cecilia Vela Gurovic
20.04
Fix Released
High
Unassigned
20.10
Fix Released
High
Cecilia Vela Gurovic

Bug Description

When you have a collection on the institution level and add a cover image, the file is not associated when you copy it into your personal account. The file still comes along, but is not placed into the 'Cover images' folder.

It nearly works fine for pages (see note below).

This also needs to be tested for copying of collections on all other levels (personal, site, group).

To replicate for institution collection:

1. As site or institution admin, create a collection with 1 page.
2. Upload a cover image to the collection.
3. Share the page and make it copyable.
4. Log in as another account holder.
5. Copy the collection.
6. View the collection on 'Pages and collections'.
Expected result: The collection's cover image is displayed.
Actual result: There is not cover image displayed.

**Please note: When the above steps are 'repeated' for a page, the page cover image does display on the 'Pages and collections' page, however, the file is NOT present in the 'Files' > 'Cover images' folder. It is instead placed in a sub-folder of the 'viewfiles' folder, this sub-sub-folder also contains any other files that were present for the copied page.

Changed in mahara:
assignee: nobody → Rangi Daymond (rangid)
Rangi Daymond (rangid)
description: updated
Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "master" branch: https://reviews.mahara.org/11181

Changed in mahara:
assignee: Rangi Daymond (rangid) → Cecilia Vela Gurovic (ceciliavg)
status: Confirmed → In Progress
Revision history for this message
Rangi Daymond (rangid) wrote :

Catalyst QA Re-tested - please see attached spreadsheet for details.

Summary: When a collection is copied, the image is copied along and placed into
the 'Home' folder, but not added as cover image for the collection.

Cover images for pages behave correctly.

----------------------------------------

The following note was added by the developer on the patch:

"If a collection and its copy have the same owner,
then use the same artefact id (same image file)
as the cover image.

If the owners are different then use the copied
file artefact id for the cover image.

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

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

commit bc5e6564b56b79b40b7173699ea233fc50ba14c6
Author: Cecilia Vela Gurovic <email address hidden>
Date: Tue Aug 25 18:19:43 2020 +1200

Bug 1892105: use correct cover image when copying collection

If a collection and its copy have the same owner,
then use the same artefact id (same image file)
as the cover image.

If the owners are different then use the copied
file artefact id for the cover image

behatnotneeded

Change-Id: Iab1e3168925ce567934b34b73627832035b809a8

Robert Lyon (robertl-9)
Changed in mahara:
status: In Progress → Fix Committed
Revision history for this message
Rangi Daymond (rangid) wrote :

Catalyst QA Tested - PASSED

Gerrit: https://reviews.mahara.org/#/c/11181/ patch 3
Browser/s: Chrome
Theme: Raw

Testing details in the attached spreadsheet.

Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "20.04_STABLE" branch: https://reviews.mahara.org/11345

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/11345
Committed: https://git.mahara.org/mahara/mahara/commit/60b42ace6d381bf949bad8ce1a8e7aa7dd21c5b9
Submitter: Robert Lyon (<email address hidden>)
Branch: 20.04_STABLE

commit 60b42ace6d381bf949bad8ce1a8e7aa7dd21c5b9
Author: Cecilia Vela Gurovic <email address hidden>
Date: Tue Aug 25 18:19:43 2020 +1200

Bug 1892105: use correct cover image when copying collection

If a collection and its copy have the same owner,
then use the same artefact id (same image file)
as the cover image.

If the owners are different then use the copied
file artefact id for the cover image

behatnotneeded

Change-Id: Iab1e3168925ce567934b34b73627832035b809a8
(cherry picked from commit bc5e6564b56b79b40b7173699ea233fc50ba14c6)

Robert Lyon (robertl-9)
Changed in mahara:
milestone: 20.10.0 → none
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.