Forums | Mahara Community

Support /
Moodle 2.6 <> Mahara 1.9 assignment submission errors with multiple submission types


Scott Gage's profile picture
Posts: 64

10 July 2014, 16:43

Hi all,

I've just recently started using the Catalayst Mahara submission plugin in our Moodle 2.6 installation and found the following:

1. Assignments with only Mahara submission work fine

2. Assignments with multiple submission types work fine if you submit a Mahara page or collection

3. Assignments with multiple submission types give me a blank error if you submit something without submitting a Mahara item.

The steps I take are as follows. The following Moodle assignment allows Mahara, Online Text and File Submissions:

If you only submit a file, however, you get the following mystery error:

Looking in locallib and the lang file I can find no notice that should be called. If you exit back to the assignment everything looks hunky-dory except that it's only in draft mode:

 

Going in to edit your submission just leads to the same empty error.

Any thoughts from the devs?

Thanks for your time,

Scott

Scott Gage's profile picture
Posts: 64

16 July 2014, 16:58

For those wondering this is due to how the Mahara plugin handles (or doesn't handle) users who have no views or collections.

When the save() function is called it barrels on without any checks to see if the drop-down list has any values in it so I wrapped all the code in the save function with the following:

if (isset($data)) {

if (isset($data->viewid[0])) {

So that was causing my empty error message, as the save() function was returning nothing.

The problem is, for my University at least, Mahara usage is not mandatory and assignments will usually have more than one submission mode so a student wanting to not submit a Mahara item or not having any at all are perfectly valid.

In the actual moodle\mod\assign\locallib.php they try and save submissions before checking for all empty, so I'm reordering this to check for empty submission first.

Aaron Wells's profile picture
Posts: 896

23 July 2014, 22:31

Hi Scott,

Thanks! I've filed an issue report to remind myself to fix this: https://github.com/catalyst/assignsubmission_mahara/issues/8

Cheers,

Aaron

Scott Gage's profile picture
Posts: 64

05 August 2014, 16:39

Hi Aaron,

That's great, thanks for that! If it helps at all I've made some tweaks to it myself, might be worth a look: https://mahara.org/artefact/file/download.php?file=384545

Cheers,

Scott

4 results