4 $sql['groups_types'] = 'SELECT type_id, title FROM '.TABLE_PREFIX.'groups_types WHERE course_id=? ORDER BY title';
\r
6 $sql['groups'] = 'SELECT G.type_id, G.title, G.description, G.modules FROM '.TABLE_PREFIX.'groups G INNER JOIN '.TABLE_PREFIX.'groups_types T USING (type_id) WHERE T.course_id=? ORDER BY T.type_id, G.title';
\r
9 function groups_types_convert($row, $course_id, $table_id_map, $version) {
\r
11 $new_row[0] = $row[0];
\r
12 $new_row[1] = $course_id;
\r
13 $new_row[2] = $row[1];
\r
18 function groups_convert($row, $course_id, $table_id_map, $version) {
\r
19 if (version_compare($version, '1.5.3', '<')) {
\r
20 // groups prior to 1.5.3 are not compatible (due to the group types).
\r
21 // backwards compatibility breaks prior to 1.5.3
\r
26 $new_row[1] = $table_id_map['groups_types'][$row[0]];
\r
27 $new_row[2] = $row[1];
\r
28 $new_row[3] = $row[2];
\r
29 $new_row[4] = $row[3];
\r