-
Bug
-
Resolution: Fixed
-
Major
-
1.9.2
-
None
-
Linux Centos
-
MySQL
-
MOODLE_19_STABLE
-
MOODLE_20_STABLE
I am using the CSV upload code to be able to use that via command line to import new users and assignments from csv with 10000+ users every day. I have found that each time I would re-run the script existing users from CSV file would have their Enrollment Start & End date reset to zero from non-zero.
The reason is the role_assign function using the parameters of timestart and timeend defaulting to 0 if not passed from calling code. As I'm synchronizing Enrollment dates, I can't use that feature to set the RA dates.
Hence I have modified the role_assign function to not set if zero is passed by timestart / timeend and non-zero values exist in the database.
if ($timestart != 0)
{ $ra->timestart = round($timestart, -2); }if ($timeend != 0)
{ $ra->timeend = $timeend; }- has been marked as being related by
-
MDL-17949 List of problems related to potential enrolment rewrite in 2.0 - META
-
- Closed
-