Project

General

Profile

Bug #7509

DB changes in table course_rel_user

Added by Julio Montoya over 4 years ago. Updated over 4 years ago.

Status:
Bug resolved
Priority:
Normal
Assignee:
Category:
Database & API changes
Target version:
Start date:
04/02/2015
Due date:
% Done:

90%

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

Description

  • The "course_rel_user.relation_type" field should be removed in favour of the "course_rel_user.status" field in order to simplifying the table and registration.
  • The "course_rel_user.role" should be renamed to "course_rel_user.description" and changed to TEXT.
    It seems this field is use to put just a description example:

https://stable.chamilo.org/main/user/userInfo.php?cidReq=AA1&id_session=0&gidReq=0&origin=&origin=users&editMainUserInfo=29

  • tutor_id should be changed to is_tutor because is used as a boolean value.

Files

Selection_001.png (48.7 KB) Selection_001.png Julio Montoya, 14/04/2015 15:34

Related issues

Related to Chamilo LMS - Bug #7508: Remove course_rel_user.group_idBug resolved04/02/2015

Actions
Related to Chamilo LMS - Feature #7634: Remove tables userinfo_def userinfo_def_contentFeature implemented14/04/2015

Actions

Associated revisions

Revision bcdd4f00 (diff)
Added by Julio Montoya over 4 years ago

Rename course_rel_user.tutor_id with is_tutor

Remove course_rel_user.role field

see #7509

History

#1

Updated by Yannick Warnier over 4 years ago

  • Category set to Database & API changes
  • Status changed from New to Assigned
  • Assignee set to Julio Montoya

This is more complex. Proceed with extreme caution and search the code first.

In particular, I believe the tutor_id has not always been a boolean value, but rather an indication of who was the direct tutor of a specific student in cases there were more than one teacher in the course.

For relation_type, I totally agree. Status is enough.

Role "seems" to be only a text, indeed, but I don't think we need a text.
Actually, if you remove all variable-length fields from this table, it should go a bit faster. As far as I can see, it is only used to put different translations of the term "Trainer" ("Responsable" in French and Spanish). What about setting it to char(20) and be done with it? (and finally have an all-fixed-fields table)
Or even removing this field completely and depending on the status to show some text in the users table in the users tool?

#2

Updated by Julio Montoya over 4 years ago

Yannick Warnier wrote:

This is more complex. Proceed with extreme caution and search the code first.

In particular, I believe the tutor_id has not always been a boolean value, but rather an indication of who was the direct tutor of a specific student in cases there were more than one teacher in the course.

I test it and when setting the "tutor_id". I have access to the "Reporting" page of the course.
So somehow is an extra permission for a user registered in that course, so it should be a "boolean".

User student/student

https://stable.chamilo.org/courses/INJ1011/index.php

#3

Updated by Yannick Warnier over 4 years ago

  • Assignee changed from Yannick Warnier to Julio Montoya

Agreed. Change to int (or bool in doctrine terms).
Yes, this feature is important. It should also give you access to score other students assignments, etc. This is a role that we call "Teacher assistant" in English (we consider it one more role of Chamilo). It's a student with special privileges to help the teacher.

#4

Updated by Yannick Warnier over 4 years ago

In the end... did you change anything on this one?

#5

Updated by Julio Montoya over 4 years ago

  • Assignee changed from Julio Montoya to Yannick Warnier

At the end I removed that screen. I added a new button called "set tutor".

id_tutor was changed to is_tutor.
course_rel_user.role was removed

But I didn't change the relation_type/status fields.

#6

Updated by Yannick Warnier over 4 years ago

  • Status changed from Assigned to Needs more info
  • Assignee changed from Yannick Warnier to Julio Montoya
  • % Done changed from 0 to 90

I saw it. Fine by me. Should we close this task? It seems to work as expected...

#7

Updated by Julio Montoya over 4 years ago

  • Status changed from Needs more info to Bug resolved

Also available in: Atom PDF