summaryrefslogtreecommitdiff
path: root/assets/js/src/ProjectPermission.js
blob: fec666b1b391029668323fe9996e1d253f437361 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Kanboard.ProjectPermission = function(app) {
    this.app = app;
};

Kanboard.ProjectPermission.prototype.listen = function() {
    $('.project-change-role').on('change', function () {
        $.ajax({
            cache: false,
            url: $(this).data('url'),
            contentType: "application/json",
            type: "POST",
            processData: false,
            data: JSON.stringify({
                "id": $(this).data('id'),
                "role": $(this).val()
            })
        });
    });
};