ImageBrowser json failing to get right view id on upload

Bug #1553812 reported by Robert Lyon
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
Low
Robert Lyon

Bug Description

When we add a text block to a page and click the image icon to add an image it passes the view id to the ImageBrowser object from the 'id' parameter. But when we go to upload an image in the 'Insert or select an image ' config popup it passes the view id with 'view' parameter.

In core mahara this causes no issue, but is wrong. In a custom site where the View construct does some extra checking it breaks things as on upload the view id is being passed in as 0, rather the correct id.

We need to get the initial popup to pass in the view id as 'view' rather than 'id' so that the json file can handle the information correctly

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/6112

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

Reviewed: https://reviews.mahara.org/6112
Committed: https://git.mahara.org/mahara/mahara/commit/936e760cf0835e14ae6f6964a2af8fb12077234a
Submitter: Son Nguyen (<email address hidden>)
Branch: master

commit 936e760cf0835e14ae6f6964a2af8fb12077234a
Author: Robert Lyon <email address hidden>
Date: Mon Mar 7 10:58:18 2016 +1300

Bug 1553812: Passing in view id as 'view' both times

For when we open the imagebrowser in text block and when we upload a
file within that text block's image config form

behatnotneeded

Change-Id: Ic8e0efeb969a63a9764726c6fb42e3b5008b46fd
Signed-off-by: Robert Lyon <email address hidden>

Revision history for this message
Kristina Hoeppner (kris-hoeppner) wrote :

Thanks to Pace University for funding this bug fix.

Robert Lyon (robertl-9)
Changed in mahara:
status: In Progress → Fix Committed
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.