Question types not displaying in "Add questions"

Question types not displaying in "Add questions"

by Kitti Lai -
Number of replies: 7

Hi, I believe there are already question types inbuilt with this plugin that can be selected via the dropbox. 

But I could not add question type as the dropbox is "empty" as shown on below screenshot.

Add questons error

When I click on "Add selected question type", which as shown there are none. Following error message are displayed:


Can someone please point me to the right direction? Any suggestions will be greatly appreciated. 

I also did a server checks in Moodle, apart of PHP opcode caching settings and unoconv version not supported - checks was OK. So I don't think that was relevant for this issue.


About my Moodle:

OS: CentOS Linux release 7.3.1611

PHP: PHP 7.1.6 (cli) (built: Jun 10 2017 07:28:42) ( NTS )

Moodle Build: 3.3.1+ (20170720)

Questionnaire plugin version: 3.3.1 (Build - 2017051800) 



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

Looking at the plugin, the question types works fine in quiz. 


Average of ratings: -
In reply to Kitti Lai

Re: Question types not displaying in "Add questions"

by Mike Churchward -
Picture of Core developers Picture of Plugin developers Picture of Testers

Your error message is indicating that it cannot find required question class file, but that seems to be an empty question type. Probably because there was nothing in the drop down. I suspect there might be a problem from the theme. Can you change your theme to a Moodle standard one (Boost or Clean) and see if the problem persists?

mike

In reply to Mike Churchward

Re: Question types not displaying in "Add questions"

by Kitti Lai -

Hi, Mike. 

Thank you for quick response. 

Still shows blank/nothing in the drop down.


Do you think both standard themes are required to run on the latest version?

The current versions are: 

Boost and Clean: 2017051500

Academi: v.1.5.1 (2017051600)


Tested on both Moodle standard themes: Set Boost and Clean as the default theme, clear theme caches + purged all caches.




In reply to Kitti Lai

Re: Question types not displaying in "Add questions"

by Mike Churchward -
Picture of Core developers Picture of Plugin developers Picture of Testers

Hi Kitti -

Do you think both standard themes are required to run on the latest version?

No. But it is tested on both and runs fine. If the same problem persists on the standard themes, then there is something else wrong.

Can you enable full debugging and see if any error messages show up when you load the question form, or any other part of the module?

mike

Average of ratings: Useful (1)
In reply to Mike Churchward

Re: Question types not displaying in "Add questions"

by Kitti Lai -

Hi Mike,

I have been on DEVELOPER mode for debugging but have yet found any other error message, will that be sufficient? or should I have gone for "ALL"?

I might have an idea to recheck the database tables for the question type and other relevant data, or even reinstall the plugin to see if that will help.

Which tables and values will you recommend me to check and to backup to not loose existing data?


I just came across that we might have altered some changes in the databases previously: a manual sweep of all old questionnaire data that was restored via a backup. I cannot recall which tables exactly were cleaned, but that might have caused the issue. 

Update: Comparing to an older version of Moodle that were using the Questionnaire plugin: 3.0.2 (Build - 2016120200), we have a table called "mdl_questionnaire_question_type" and that was missing on this current version of Moodle we are running.

Will it be much to ask for a screenshot or list of all tables related to the latest version of this plugin? (Build - 2017051800)


Many thanks,

Kitti

In reply to Kitti Lai

Re: Question types not displaying in "Add questions"

by Mike Churchward -
Picture of Core developers Picture of Plugin developers Picture of Testers

You definitely need the questionnaire_question_type table. It defines the question types that would appear in the dropdown. It should be there when you install the questionnaire and should not have been removed. It would look the same as the one in 3.0.2.

mike

Average of ratings: Useful (1)
In reply to Mike Churchward

Re: Question types not displaying in "Add questions"

by Kitti Lai -

Thank you very much for the help.

Indeed it was because of the tables, it working fine now on our current theme (adaptable).

- Kitti