Dataform - Filter 2 - Version problem?

Dataform - Filter 2 - Version problem?

by Pete Chapman -
Number of replies: 5

I would be grateful for some guidance with the attached. I'm using dataform 2.9. 

The first screen shot in the attachent is the interface I see when setting up a filter to use the 'Empty' parameter - when created this filter causes a database error.

The second interface pic has been sent to me by Frankie who is also using 2.9. His similar filter works fine.

There are big differences between the interfaces and I am totally perplexed. Could anyone throw some light on this?

Many thanks

Pete


Average of ratings: -
In reply to Pete Chapman

Re: Dataform - Filter 2 - Version problem?

by Itamar Tzadok -

There is an issue with the is/not empty filter criterion in 2.9. It is fixed in 3.0.4. I have not released an updated version for 2.9. Are you upgrading any time soon? smile

In reply to Itamar Tzadok

Re: Dataform - Filter 2 - Version problem?

by Pete Chapman -

Thanks Itamar, I don't have install admin rights to our Moodle system but I can certainly ask our techs to upgrade our dataform plugin to 3.0.4.

Thanks for your help.

Pete

In reply to Pete Chapman

Re: Dataform - Filter 2 - Version problem?

by Itamar Tzadok -

The Dataform branches are aligned with Moodle's. You cannot install/upgrade Dataform 3 on Moodle 2.9.

Try to reproduce the problem in debugging mode so that we have more details.

If you can't upgrade your Moodle, you can try applying only the particular commits that addressed the is/not empty criterion. See CONTRIB-5835  and   CONTRIB-6123.

smile

In reply to Itamar Tzadok

Re: Dataform - Filter 2 - Version problem?

by Pete Chapman -

Thanks Itamar, My institution has a Moodle upgrade scheduled for the near future - here's hoping it is to Ver 3.

Thank you for your help.

Pete

In reply to Pete Chapman

Re: Dataform - Filter 2 - Version problem?

by Frankie Kam -
Picture of Plugin developers

Hi Pete

Actually I just discovered this:
https://moodle.org/mod/forum/discuss.php?d=316873  (is it the same issue you are facing now with Dataform 2.9?)

As per Itamar's instruction back then, I had earlier created this tracker:

The fix by Itamar is inside the tracker link of CONTRIB-5827 - you can see by looking at the diff links.

The fix that Itamar did was to this particular file named select.php that is found in the subfolder /mod/dataform/field/select/classes

I.e., specifically (on my server it looks like this):
/public_html/moodle/mod/dataform/field/select/classes/select.php

What you can do is to ask your Moodle Admin to try this out:

Step 1. BE VERY CAREFUL to backup the original select.php file!!!
            Backup or rename the original /mod/dataform/field/select/classes/select.php
            to something like this
            /mod/dataform/field/select/classes/select-original.php

Step 2.  ONLY DO Step 2 if you have already backed up the original select.php file!!!
             Copy the attached select.php file into the subfolder /mod/dataform/field/select/classes/
             So you now should have two select.php files (one original and one new) as shown in the image below.



Yellow highlighted select.php is the attached file.

Step 3. Test your Dataform. If it works, then the experiment worked. YEA!!!!  If it doesn't work, then the
            experiment has failed. Aaargh!! If it fails, then immediately delete the new select.php and rename
            the backup file 
select-original.php to select.php.


Let me know if it works or not.

Cheers
Frankie Kam