Replace document.ready with shortcut "$(function () {"

document.ready is not working in jquery v3, needed in master.
pull/3173/head
Julio Montoya 6 years ago
parent cd0e1d6e61
commit f922a9ebd9
  1. 4
      main/announcements/announcements.php
  2. 2
      main/inc/lib/javascript/annotation/js/annotation.js
  3. 2
      main/template/default/admin/teacher_time_report.tpl
  4. 2
      main/template/default/blog/blog.tpl
  5. 2
      main/template/default/blog/post.tpl
  6. 2
      main/template/default/chat/chat.tpl
  7. 2
      main/template/default/chat/video.tpl
  8. 2
      main/template/default/exercise/submit.js.tpl
  9. 2
      plugin/advanced_subscription/views/open_session.tpl
  10. 2
      plugin/bbb/resources/utils.js
  11. 2
      plugin/buycourses/view/sales_report.tpl
  12. 2
      plugin/buycourses/view/service_panel.tpl
  13. 2
      plugin/buycourses/view/service_sales_report.tpl
  14. 2
      plugin/grading_electronic/view/grading.html.twig
  15. 2
      plugin/tour/views/script.tpl

@ -523,7 +523,7 @@ switch ($action) {
$form->addHtml("
<script>
$(document).on('ready', function () {
$(function () {
$('#announcement_preview').on('click', function() {
var users = [];
$('#users_to option').each(function() {
@ -566,7 +566,7 @@ switch ($action) {
$form->addHtml(
"
<script>
$(document).on('ready', function () {
$(function () {
$('#choose_recipients').click();
});
</script>

@ -324,7 +324,7 @@
};
window.AnnotationQuestion = function (userSettings) {
$(document).on('ready', function () {
$(function () {
var settings = $.extend(
{
questionId: 0,

@ -1,5 +1,5 @@
<script>
$(document).on('ready', function () {
$(function () {
$('#course').on('change', function () {
$('#session').prop('selectedIndex', 0);
$('#teacher').prop('selectedIndex', 0);

@ -101,7 +101,7 @@
</div>
</div>
<script>
$(document).on('ready', function () {
$(function () {
$('.btn-read-more').on('click', function (e) {
e.preventDefault();

@ -156,7 +156,7 @@
</div>
<script>
$(document).on('ready', function () {
$(function () {
$('.btn-reply-to').on('click', function (e) {
e.preventDefault();

@ -65,7 +65,7 @@
<source src="{{ _p.web_main }}chat/sound/notification.mp3" type="audio/mpeg"></source>
</audio>
<script>
$(document).on('ready', function () {
$(function () {
var ChChat = {
_ajaxUrl: '{{ _p.web_ajax }}course_chat.ajax.php?{{ _p.web_cid_query }}',
_historySize: -1,

@ -152,7 +152,7 @@
}
};
$(document).on('ready', function () {
$(function () {
VideoChat.init();
});
})();

@ -222,7 +222,7 @@ jsPlumb.ready(function () {
}
});
$(document).on('ready', function () {
$(function () {
DraggableAnswer.init(
$(".exercise-draggable-answer"),
$(".droppable")

@ -1,7 +1,7 @@
<link href="{{ _p.web_plugin }}advanced_subscription/views/css/style.css" rel="stylesheet" type="text/css">
<script>
$(document).on('ready', function () {
$(function () {
$('#asp-close-window').on('click', function (e) {
e.preventDefault();

@ -1,4 +1,4 @@
$(document).on('ready', function () {
$(function () {
$('.check-meeting-video').on('click', function (e) {
e.preventDefault();

@ -81,7 +81,7 @@
</div>
<script>
$(document).on('ready', function () {
$(function () {
$('[name="filter_type"]').on('change', function () {
var self = $(this);

@ -56,7 +56,7 @@
</table>
</div>
<script>
$(document).on('ready', function () {
$(function () {
$("td a").click(function () {
var id = $(this).attr('tag');
var action = $(this).attr('id');

@ -73,7 +73,7 @@
</div>
<script>
$(document).on('ready', function () {
$(function () {
$("td a").click(function () {
var id = $(this).attr('tag');
var action = $(this).attr('id');

@ -23,7 +23,7 @@
</div>
</div>
<script>
$(document).on('ready', function () {
$(function () {
$('form[name="frm_grading_electronic"]').on('submit', function (e) {
e.preventDefault();

@ -57,7 +57,7 @@
};
})();
$(document).on('ready', function() {
$(function () {
var pages = {{ tour.pages }};
$.each(pages, function(index, page) {

Loading…
Cancel
Save