33 Commits

Author SHA1 Message Date
tjhunt
84e628a027 quiz settings: MDL-18485 Improve quiz settings form
* Reorder form fields to group things more logically.
** and on the corresponding admin page too.

* Set some options to be 'Advanced' by default:
** Apply penalties.
** Each attempt builds on the last.
** Decimal places for question grades.
** The five 'Extra restrictions on attempts' settings. (password, etc.)
* Admins can still change this to suit their institiution at Administration > Plugins > Activity modules > Quiz.
* These new defaults are applied if the admin had not previously set any fields to be advanced.

* Disable some filds when they are not applicable:
** Grading method, if num attempts = 1
** Penaly scheme, if adaptive mode = no
** Each attempt builds of last, if num attempts = 1
** Review after quiz closed options, if no close date.
** Delay between 1st and 2nd attempts, if num attempts = 1
** Delay between later attempts, if num attempts < 3

* Convert quiz.timelimit to be in seconds, for consistency, and ready for the new duration field type (MDL 18500).
** Including ensuring that backup and restore is backwards compatible.

* MDL-5537 New setting, questiondecimalpoints, so, for example, you can show the quiz grade as an integer, but have fractional question grades.
** There is a 'Same as overall decimal points' option, which is the default.

* Improve some field labels.

* Make corresponding changes in the help files.
2009-03-10 08:39:51 +00:00
tjhunt
807a1a8427 question bank database: MDL-17608 Drop originalquestion field from the question_states table - it was never used for anything. 2009-01-06 05:20:21 +00:00
tjhunt
6b22437658 MDL-16058 - Remove obsolete quiz_question_versions table. 2008-08-15 08:23:09 +00:00
nicolasconnault
9cf4a18b41 MDL-15113 Upgrade to DMLLIB 2.0. Needs further testing and bug-fixing.
MDL-15100 Fixed a bug in gradelib.php
Plus edited tablelib.php for table_sql upgrade to dmllib 2.0
2008-06-09 10:00:35 +00:00
skodak
9db7dab2ca MDL-15095 towards restore lib dml conversion 2008-06-03 22:36:54 +00:00
skodak
44e1b7d7ff MDL-14679 remoed all instances of get_records_list() 2008-06-01 15:42:48 +00:00
tjhunt
1061756d8e Minor whitespace fixup. 2007-11-07 15:41:20 +00:00
thompson697
cf0b1faded Apply modularity to the creation of the log file during restore to a new course.
Remove the responsibility for loging the application of the course start date offset, from activity modules to the backup module.
Merged from stable branch
2006-10-17 10:05:41 +00:00
thompson697
eb87ac71c5 Change creation of restorelog file location to protected backupdata folder.
Reassign style and language links
2006-10-04 14:50:50 +00:00
tjhunt
717cfb0a7b Rename column question_dataset_items->number to itemnumber, to avoid reserved word. 2006-09-19 10:56:00 +00:00
thompson697
163ff97e84 Complete work on Roll Forwards - Restore from previous semester (MDL-5532)
* Add fields to restore form to enable changes to Short Name, Full Name and Start Date
* Start Date offset added to Restore process
* Created Restorelog file in Course files area
* Activity Modules use offset to change dates
* Activity Modules write changes to Restorelog
2006-09-13 13:19:39 +00:00
toyomoyo
4f83ae95ca adding capabilities 2006-08-31 08:51:09 +00:00
gustav_delius
32a189d636 More renamings to separate questions from quiz. Some other small fixes. 2006-03-12 21:17:42 +00:00
gustav_delius
dc1f00de19 Some little fixes and more renaming to cleanly separate question code from quiz code
Renaming tables:
quiz_answers -> question_answers
quiz_categories -> question_categories

Renaming functions:
quiz_get_category_menu -> question_category_menu
quiz_get_category_coursename -> question_category_coursename
quiz_categorylist -> question_categorylist
2006-03-01 07:03:57 +00:00
gustav_delius
4f48fb42af Towards removing reference to quiz module from the question code
Renaming tables:
quiz_questions -> question
quiz_states -> question_states

Renaming functions:
quiz_delete_question -> delete_question
quiz_get_question_options -> get_question_options
quiz_get_states -> get_question_states
quiz_restore_state -> restore_question_state
quiz_save_question_session -> save_question_session
quiz_state_is_graded -> question_state_is_graded
quiz_extract_responses -> question_extract_responses
quiz_regrade_question_in_attempt -> regrade_question_in_attempt
quiz_process_responses -> question_process_responses
quiz_isgradingevent -> question_isgradingevent($event)
quiz_search_for_duplicate_responses -> question_search_for_duplicate_responses
quiz_apply_penalty_and_timelimit -> question_apply_penalty_and_timelimit
quiz_print_question_icon -> print_question_icon
quiz_get_image -> get_question_image
quiz_make_name_prefix -> question_make_name_prefix
quiz_get_id_from_name_prefix -> question_get_id_from_name_prefix
quiz_new_attempt_uniqueid -> question_new_attempt_uniqueid
quiz_get_renderoptions -> question_get_renderoptions
quiz_print_quiz_question -> print_question
quiz_get_question_responses -> get_question_responses
quiz_get_question_actual_response -> get_question_actual_response
quiz_get_question_fraction_grade -> get_question_fraction_grade
quiz_get_default_category -> get_default_question_category


Renaming constants:
QUIZ_EVENT.... -> QUESTION_EVENT....
QUIZ_MAX_NUMBER_ANSWERS -> QUESTION_NUMANS
2006-02-28 09:26:00 +00:00
mjollnir_
f90666aa5c Abstracted a bit of the restore procedure to allow for silent restoring.
Added new function, import_backup_file_silently
Changed everything that prints stuff to check for a constant first.
Backup_flush checks a different constant, this is so that output can still
get flushed to the browser when necessary but not print <li>s everywhere.
Please test this!
2006-01-15 21:09:13 +00:00
mjollnir_
1ecea97679 Granular backup & restore:
This patch allows the much requested selection of individual instances of modules within a course to backup and restore.
It needs A LOT of testing and probably some prettyifying too.
2006-01-13 03:45:31 +00:00
stronk7
140b7eb5db Log actions must be strored to DB without &amp;
print_log() takes care of it! Bug 3853.
(http://moodle.org/bugs/bug.php?op=show&bugid=3853)

Merged from MOODLE_15_STABLE
2005-11-23 09:46:25 +00:00
gustav_delius
a08e9552fa More steps towards the separation of questions from the quiz module. 2005-07-03 09:53:02 +00:00
gustav_delius
d115d8c736 I have introduced the new field $attempt->uniqueid, see http://mantis.york.ac.uk/moodle/mod/forum/discuss.php?d=852#3380 2005-07-02 18:14:51 +00:00
stronk7
e5acc2e61b Being a bit more exact, I've replaced the 1, 2, .... n
ordered asumption when restoring multianswer responses and
now it checks for the real positionky (like the upgrade)
2005-05-20 22:56:20 +00:00
stronk7
e44f2f92b0 Now length is correctly set and stored to DB (bug 3290)
(http://moodle.org/bugs/bug.php?op=show&bugid=3290)

plus some added bits to handle the hidden field properly
2005-05-18 23:53:36 +00:00
stronk7
87dddc1445 Replaced some (not all) tabs to spaces.
I've leave unmodified formats and nusoap library
2005-05-16 22:51:16 +00:00
stronk7
8465c58a8d STEP 2 seems to be working relatively nice!!
quizzes, instances, versions, attempts, states and grades for pre15
are now restored. Not fully tested, so I'm sure it will need some
adjustments but, basically, it's done.
 CVS: ----------------------------------------------------------------------
2005-05-16 00:05:50 +00:00
stronk7
ce12d03e71 Now STEP1 is 100% completed.
Remap of multianswers isn't necessary because, under Moodle 1.5, it seems
to be always a  1..n collection of pairs and responses pairs are always
ordered from {#1} to {#n}.

If this isn't true we should look for an alternatice method of restore
attempts... :-(

For more info, bug 3252 has more info
(http://moodle.org/bugs/bug.php?op=show&bugid=3252)
2005-05-15 21:40:59 +00:00
stronk7
4544d0727f Latest change of function name solved ! 2005-05-14 23:44:37 +00:00
stronk7
86f00bcf98 Now the restore of quiz_categories use the new
restore_get_best_category() function.
2005-05-14 23:43:04 +00:00
stronk7
359d007b0b Some debug is out and the missing decode of answers->question
has been included.
2005-05-14 16:38:52 +00:00
stronk7
7aaffc3a55 Not finished but multianswer questions are now properly converted
to their new schema. Good milestone to save changes to CVS.
2005-05-14 16:07:37 +00:00
stronk7
a63ae8e9b2 Work in progress!!
I doesn't work at all but near every question type has been checked and
changed if needed. Tomorrow I'll start with the quiz->attempts... part

Anyway I've some IMPORTANT doubts about how this questions are currently
implemented:

- NUMERICAL: Can the answer field have more than one answer?
- MULTIANSWER: What are the differences. Why, in the upgrade process,
     all of them are deleted and recreated? Why some fields have been
     deleted? Why the questiontext for this type is set to '' in the
     upgrade processs
- CALCULATED: Why the quiz_question_datasets table is now simply "s" in
     the restore process? A typo, I hope.

I've written this here to avoid forgetting it and, if someone in the
quiz's team can answer me...

Now, just zzzZZZzzzZZZ. Ciao :-)
2005-05-11 23:13:03 +00:00
stronk7
cb3270aeb5 We must have editing rights in existing course, owner of the
published cat, not it the one being restored. ;-)
2005-05-11 16:47:50 +00:00
stronk7
d2ed94bcba Simply rename everyfunction.
Some of them will be deleted later...but from now...
2005-05-09 19:46:08 +00:00
stronk7
0ce57ae1e2 Splitted restorelib.php to work together
in both 1.5 and pre 1.5 restore code.
Gustav's team is goingo to handle 1.5 whereas
I'm going to handle old backups.

I'll try to change every function name to be able
to merge both libs again at the end of the process.
2005-05-09 11:07:37 +00:00