Project

General

Profile

« Previous | Next » 

Revision b0cd758c

Added by Serghei Mihai over 11 years ago

agenda: new schedules opening fix

View differences:

calebasse/static/js/calebasse.agenda.js
15 15

  
16 16
function get_initial_fields(button, base) {
17 17
    var participants = new Array();
18
    var active_agenda = $.cookie('active-agenda').split('-');
19
    var ressource = '';
20
    if (active_agenda[0] == 'ressource') {
21
        ressource = active_agenda[1];
22
    } else {
23
        ressource = $.cookie('last-ressource');
18
    var ressource = null;
19
    if ($.cookie('active-agenda')) {
20
        var active_agenda = $.cookie('active-agenda').split('-');
21
        if (active_agenda[0] == 'ressource') {
22
            ressource = active_agenda[1];
23
        } else {
24
            ressource = $.cookie('last-ressource');
25
        }
24 26
    }
25 27

  
26 28
    if ($.cookie('agenda-tabs')) {
......
33 35
            var data = v.split('-'); return data[1]
34 36
        });
35 37
    }
36
    console.log($(button).data('duration'));
37 38
    return $.param({participants: $.makeArray(participants),
38 39
                    ressource: ressource,
39 40
                    time: $(button).data('hour'),

Also available in: Unified diff