mirror of
https://github.com/moodle/moodle.git
synced 2025-03-14 04:30:15 +01:00
Merge branch 'wip-mdl-53701' of https://github.com/rajeshtaneja/moodle
This commit is contained in:
commit
68c1074625
@ -80,27 +80,29 @@ function form_init_date_js() {
|
||||
$calendar = \core_calendar\type_factory::get_calendar_instance();
|
||||
$module = 'moodle-form-dateselector';
|
||||
$function = 'M.form.dateselector.init_date_selectors';
|
||||
$defaulttimezone = date_default_timezone_get();
|
||||
|
||||
$config = array(array(
|
||||
'firstdayofweek' => $calendar->get_starting_weekday(),
|
||||
'mon' => strftime('%a', strtotime("Monday")),
|
||||
'tue' => strftime('%a', strtotime("Tuesday")),
|
||||
'wed' => strftime('%a', strtotime("Wednesday")),
|
||||
'thu' => strftime('%a', strtotime("Thursday")),
|
||||
'fri' => strftime('%a', strtotime("Friday")),
|
||||
'sat' => strftime('%a', strtotime("Saturday")),
|
||||
'sun' => strftime('%a', strtotime("Sunday")),
|
||||
'january' => strftime('%B', strtotime("January 1")),
|
||||
'february' => strftime('%B', strtotime("February 1")),
|
||||
'march' => strftime('%B', strtotime("March 1")),
|
||||
'april' => strftime('%B', strtotime("April 1")),
|
||||
'may' => strftime('%B', strtotime("May 1")),
|
||||
'june' => strftime('%B', strtotime("June 1")),
|
||||
'july' => strftime('%B', strtotime("July 1")),
|
||||
'august' => strftime('%B', strtotime("August 1")),
|
||||
'september' => strftime('%B', strtotime("September 1")),
|
||||
'october' => strftime('%B', strtotime("October 1")),
|
||||
'november' => strftime('%B', strtotime("November 1")),
|
||||
'december' => strftime('%B', strtotime("December 1"))
|
||||
'mon' => date_format_string(strtotime("Monday"), '%a', $defaulttimezone),
|
||||
'tue' => date_format_string(strtotime("Tuesday"), '%a', $defaulttimezone),
|
||||
'wed' => date_format_string(strtotime("Wednesday"), '%a', $defaulttimezone),
|
||||
'thu' => date_format_string(strtotime("Thursday"), '%a', $defaulttimezone),
|
||||
'fri' => date_format_string(strtotime("Friday"), '%a', $defaulttimezone),
|
||||
'sat' => date_format_string(strtotime("Saturday"), '%a', $defaulttimezone),
|
||||
'sun' => date_format_string(strtotime("Sunday"), '%a', $defaulttimezone),
|
||||
'january' => date_format_string(strtotime("January 1"), '%B', $defaulttimezone),
|
||||
'february' => date_format_string(strtotime("February 1"), '%B', $defaulttimezone),
|
||||
'march' => date_format_string(strtotime("March 1"), '%B', $defaulttimezone),
|
||||
'april' => date_format_string(strtotime("April 1"), '%B', $defaulttimezone),
|
||||
'may' => date_format_string(strtotime("May 1"), '%B', $defaulttimezone),
|
||||
'june' => date_format_string(strtotime("June 1"), '%B', $defaulttimezone),
|
||||
'july' => date_format_string(strtotime("July 1"), '%B', $defaulttimezone),
|
||||
'august' => date_format_string(strtotime("August 1"), '%B', $defaulttimezone),
|
||||
'september' => date_format_string(strtotime("September 1"), '%B', $defaulttimezone),
|
||||
'october' => date_format_string(strtotime("October 1"), '%B', $defaulttimezone),
|
||||
'november' => date_format_string(strtotime("November 1"), '%B', $defaulttimezone),
|
||||
'december' => date_format_string(strtotime("December 1"), '%B', $defaulttimezone)
|
||||
));
|
||||
$PAGE->requires->yui_module($module, $function, $config);
|
||||
$done = true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user