adding user to course/curriculum

Backend functionalities: user management, course management, reports, certificates, etc.
Post Reply
ebsi
FormaLms User
Posts: 28
Joined: Mon Jun 25, 2012 3:50 pm
Location: Mayo, Ireland
Contact:

adding user to course/curriculum

Post by ebsi »

Hi ALl,

Can someone tell me exactly how a student is added to a course from the perspective of the DATABASE? What tables are affected if I add a student to :

a) A course
b) a curriculum

Thanks for your help!

Thomas
User avatar
alberto
FormaLms Guru
Posts: 1155
Joined: Fri Mar 02, 2012 9:18 am
Contact:

Re: adding user to course/curriculum

Post by alberto »

On course subscription are used the following tables:

learning_courseuser: matches user and course id
core_group_members: add a row with the permission idst from core_group for each course

To add a user to a course:

1 - find user id (core_user) and course id (learning_course)
2 - in core_group find the rows containing /lms/course/[idcourse]/subscribed/[level 1-7], and find the id of the required user level (from 1 - ghost to 7 - administrator)
3 - in core_group_member add a new record with the user id (idstmember), and the user level id found above
4 - in in learning_courseuser add a new record with the user id (idstmember), course id and the user level

For curricula use also table "learning_coursepath_user".
ebsi
FormaLms User
Posts: 28
Joined: Mon Jun 25, 2012 3:50 pm
Location: Mayo, Ireland
Contact:

Re: adding user to course/curriculum

Post by ebsi »

Thanks Alberto,

To clarify, if I have a curriculum of 4 course units, do I have to add the user to the 4 courses AND the curriculum?

Also you say level 1 is ghost and 7 Super Admin... so

7 Course administrator
6 Teacher
5 Mentor: a subject expert
4 Tutor: a communication processes expert
3 Student
2 Guest (a guest user subscribed to the course with visual access rights only)
1 Ghost (a user whose activity is not tracked by the system)

So its different to the group level numbers where a student would be entered into core group 5, correct?

Thanks for your expert advice Alberto!

Thomas
User avatar
alberto
FormaLms Guru
Posts: 1155
Joined: Fri Mar 02, 2012 9:18 am
Contact:

Re: adding user to course/curriculum

Post by alberto »

To be honest I never did that via db, but I guess you have add the user both to the courses and to the curriculum.

Correct, in course profiling "student" is level 3, but the permission id will be different for each course.

"5" is the idst for the group of normal users in platform profiling, and is the same in every docebo installation.
Post Reply