Project

General

Profile

Feature #7618

Feature #7598: [1.9.10.x] Add feature menu and several choice for Fill the blank question - for 1.9.10.x

Add feature menu and several choice for Fill the blank question

Added by Hubert Borderiou over 4 years ago. Updated about 4 years ago.

Status:
Feature implemented
Priority:
Normal
Assignee:
Category:
Exercises
Target version:
Start date:
07/04/2015
Due date:
% Done:

100%

Estimated time:
Complexity:
Normal
SCRUM pts - complexity:
?


Files

error-guardar-multi-blanco.png (51.9 KB) error-guardar-multi-blanco.png Yannick Warnier, 11/08/2015 19:02
idauto.png (133 KB) idauto.png Yannick Warnier, 12/08/2015 19:33
testidauto.png (23 KB) testidauto.png Yannick Warnier, 13/08/2015 16:09

Related issues

Related to Chamilo LMS - Bug #7610: Problème avec les exposants dans les Quiz phrases trouéesBug resolved03/04/2015

Actions

Associated revisions

Revision 9096794b (diff)
Added by Julio Montoya about 4 years ago

Add new options in fill blanks (partial) see #7618

Revision ba6421cd (diff)
Added by Julio Montoya about 4 years ago

Fix new options in fill in blanks see #7618

Revision f21f9b6f (diff)
Added by Julio Montoya about 4 years ago

Fix fill in blanks see #7618

Revision e503e910 (diff)
Added by Angel Fernando Quiroz Campos about 4 years ago

Fix CQuizAnswer entity in accordance with Version110 migration - refs #7456 #7618

Revision 9c0238b9
Added by Angel Fernando Quiroz Campos about 4 years ago

Merge pull request #796 from AngelFQC/7456

Fix table of exercices list and save answers - refs #7456 #7618

History

#1

Updated by Hubert Borderiou over 4 years ago

  • Parent task set to #7598
#2

Updated by Yannick Warnier about 4 years ago

  • Status changed from New to Assigned
  • Assignee set to Julio Montoya
#3

Updated by Yannick Warnier about 4 years ago

  • Assignee changed from Julio Montoya to Angel Quiroz
  • % Done changed from 0 to 10

Re-asigning to Angel because he made most of the changes there for exercises with CKeditor.

Re-apply commit https://github.com/chamilo/chamilo-lms/commit/badd895cd96fcca6e474eb6246ebd000b0f2f383?w=1 to 1.10.x

#4

Updated by Yannick Warnier about 4 years ago

  • Assignee changed from Angel Quiroz to Julio Montoya

Re-assigning to Julio :-)

#5

Updated by Julio Montoya about 4 years ago

I just added this feature. I have more test with weird strings ...

#6

Updated by Julio Montoya about 4 years ago

  • Status changed from Assigned to Needs testing
  • Assignee deleted (Julio Montoya)

I tried with this strings and is working for me:

TEST 1 [TEST 1]
TEST 2 test> [test>]
TEST 3 test° [test°]
TEST 4 test> [test>]
TEST 5 где? [где?]

#7

Updated by Yannick Warnier about 4 years ago

when I define [prueba|pruebas] (for multiple possibilities) and save, I get a double Chamilo header.
Screenshot attached.

#8

Updated by Julio Montoya about 4 years ago

  • Assignee changed from Julio Montoya to Yannick Warnier

Yannick Warnier wrote:

when I define [prueba|pruebas] (for multiple possibilities) and save, I get a double Chamilo header.
Screenshot attached.

I fixed this double chamilo header, try to do it again in "test mode" it seems a DB error.

#9

Updated by Yannick Warnier about 4 years ago

  • File idauto.png idauto.png added
  • Assignee changed from Yannick Warnier to Julio Montoya
  • % Done changed from 10 to 20

Julio Montoya wrote:

Yannick Warnier wrote:

when I define [prueba|pruebas] (for multiple possibilities) and save, I get a double Chamilo header.
Screenshot attached.

I fixed this double chamilo header, try to do it again in "test mode" it seems a DB error.

Indeed, and this one proves very interesting. It seems like there is a conflict between the install procedure and the upgrade procedure. One (the install) defines and uses "c_quiz_answer.id_auto" as a primary key, while the other (the upgrade) does not remove id_auto but defines a c_quiz_answer.iid field as the primary key.

So if you do a fresh web-based install without any migration, you'll end up with a different c_quiz_answer table than with an upgrade.
install upgrade
- iid
id_auto id_auto
c_id c_id
id id
question_id question_id
.. ..

The code (main/exercices/) uses both iid and id_auto, so it's a bit difficult to understand. Could you check which one we could remove, please? (I would prefer to remove id_auto if it's not completely necessary)

Note that, in 1.9.10, id_auto is auto_increment but it is a primary key with c_id (primary key (c_id, id_auto)), so in any case, it could stay in 1.10 but it should not be the primary key on its own, as it is now.

#10

Updated by Angel Quiroz about 4 years ago

I modified the CQuizAnswer entity in accordance with the Version110 migration

commit https://github.com/chamilo/chamilo-lms/commit/e503e91095d5b5be9c1fa70906eb9df5b66b3a1f

#11

Updated by Yannick Warnier about 4 years ago

With the patch by Angel it works, but I'd like you (Julio) to check on this id_auto. Maybe I added it myself some time ago, or maybe you did, but I'm wondering if it is still necessary.

#12

Updated by Julio Montoya about 4 years ago

  • Assignee changed from Julio Montoya to Yannick Warnier

Yannick Warnier wrote:

With the patch by Angel it works, but I'd like you (Julio) to check on this id_auto. Maybe I added it myself some time ago, or maybe you did, but I'm wondering if it is still necessary.

id_auto is spread as the "primary key" and in questions already answered the id_auto is still used and saved in the track tables.

#13

Updated by Yannick Warnier about 4 years ago

  • File testidauto.png testidauto.png added
  • Status changed from Assigned to Feature implemented
  • Assignee changed from Yannick Warnier to Julio Montoya
  • % Done changed from 20 to 100

I will leave the patch from Angel as it is. The id_auto cannot be the primary key, simply because it was a part of a combined primary key in 1.9. As such, this would generate conflicts when migrating from 1.9 to 1.10, for example in the case where you had two courses with one exercise and one question each, those two questions would share the same id_auto.

Here a screenshot of this case in 1.9 to deminstrate:

As such, id_auto cannot be a primary key, but must remain an auto-incremented field (because it works that way now). It should be removed in the future.
The current situation is fine.

Also available in: Atom PDF