first commit
This commit is contained in:
20
js/settings/personal.js
Normal file
20
js/settings/personal.js
Normal file
@@ -0,0 +1,20 @@
|
||||
+(function ($) {
|
||||
|
||||
window.addEventListener("DOMContentLoaded", function () {
|
||||
$('.ncdownloader-personal-settings').on('click', 'input[type="button"]', function (event) {
|
||||
OC.msg.startSaving('#ncdownloader-message');
|
||||
const target = $(this).attr("data-rel");
|
||||
const http = $.ncdownloader.http;
|
||||
let inputData = http.getData(target);
|
||||
http.setData(inputData.data);
|
||||
const path = inputData.url || "/apps/ncdownloader/personal/save";
|
||||
let url = OC.generateUrl(path);
|
||||
http.setUrl(url);
|
||||
http.setHandler(function (data) {
|
||||
OC.msg.finishedSuccess('#ncdownloader-message', "OK");
|
||||
});
|
||||
http.send();
|
||||
});
|
||||
});
|
||||
}
|
||||
)(jQuery)
|
||||
Reference in New Issue
Block a user