Git Repository Public Repository

CPE_learningsite

URLs

Copy to Clipboard

This repository has no backups
This repository's network speed is throttled to 100KB/sec

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
$('document').ready(function () {
    var morning = new Date();
    morning.setHours(6, 0, 0, 0);

    $('.timepicker').timePicker({
        startTime: morning,
        show24Hours: false,
        step: 30
    });

    $('.delete').click(function () {
        //delete pause
        var key = $(this).closest('tr').attr('pauseKey');
        var url = "/rebroadcast/DeletePause";
        $.ajax({
            url: url,
            dataType: "json",
            data: { pauseKey: key },
            type: 'POST',
            success: function (result) {
                if (result == true) {
                    window.location.reload();
                }
                else {
                    alert('Problem Removing Pause.');
                }
            }
        });
    });
    $('#btnSave').click(function () {
        //save times
        var url = "/rebroadcast/UpdatePauses";
        var pauses = new Array();
        $('tbody tr').each(function (index, value) {
            var pause = {};
            pause.MesstingSessionPauseKey = $(this).attr('pauseKey');
            var startDate = new Date($(this).find('.startDate').text());
            var startTime = $.timePicker($(this).find('.startTime')).getTime();
            var endDate = new Date($(this).find('.endDate').text());
            var endTime = $.timePicker($(this).find('.endTime')).getTime();
            pause.StartDate = new Date(startDate.getFullYear(), startDate.getMonth(), startDate.getDate(), startTime.getHours(), startTime.getMinutes(), startTime.getSeconds(), startTime.getMilliseconds());
            pause.EndDate = new Date(endDate.getFullYear(), endDate.getMonth(), endDate.getDate(), endTime.getHours(), endTime.getMinutes(), endTime.getSeconds(), endTime.getMilliseconds());

            pauses.push(pause);
        });
        var data = {};
        data.pauses = pauses;
        $.ajax({
            url: url,
            dataType: "json",
            data: $.toDictionary(data),
            type: 'POST',
            success: function (result) {
                if (result == true) {
                    window.location.reload();
                }
                else {
                    alert('Problem Saving Changes.');
                }
            }
        });
    });
});

Commits for CPE_learningsiteCPE/CPE.App/CPE.App.Web/static/js/rebroadcast/rebroadcastpauses.js

Diff revisions: vs.
Revision Author Commited Message
4cd176 ... v.shishlov Fri 27 Aug, 2021 14:33:17 +0000

initial commit