static.js.admin.users.folders.edit.js Maven / Gradle / Ivy
$(document).ready(function() {
$('.savefolder').submit(function(event) {
postRequest($(this), "/api/folders/save", "", "", function(data) {
updateFoldersTable("");
});
return false;
});
$('.updatepermissions').submit(function(event) {
alert("HI");
postRequest($(this), "/api/users/invite", "", "", function(data) {
updateFoldersTable("");
});
return false;
});
var email = $("#email").val();
var folder = $("#folder").val();
$.getJSON("/api/folders/get?email=" + email + "&folder=" + folder, function(data) {
$.map(data.permissions, function (item, index) {
$("#" + item).prop('checked',true);
});
});
});