mirror of
https://github.com/openclassify/openclassify.git
synced 2026-02-09 06:46:08 -06:00
#4231 Heavy Machinery Project
This commit is contained in:
parent
d0be55ade2
commit
dda2db1b10
@ -1,11 +1,14 @@
|
|||||||
function crudAjax(params, url, type = 'GET', callback = () => {}, async = false) {
|
function crudAjax(params, url, type = 'GET', callback = () => {}, async = true, options = {}) {
|
||||||
return $.ajax({
|
return $.ajax({
|
||||||
type: type,
|
...{
|
||||||
data: params,
|
type: type,
|
||||||
async: async,
|
data: params,
|
||||||
url: url,
|
async: async,
|
||||||
success: function (response) {
|
url: url,
|
||||||
callback(response);
|
success: function (response) {
|
||||||
|
callback(response);
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
...options
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,11 +1,14 @@
|
|||||||
function crudAjax(params, url, type = 'GET', callback = () => {}, async = false) {
|
function crudAjax(params, url, type = 'GET', callback = () => {}, async = true, options = {}) {
|
||||||
return $.ajax({
|
return $.ajax({
|
||||||
type: type,
|
...{
|
||||||
data: params,
|
type: type,
|
||||||
async: async,
|
data: params,
|
||||||
url: url,
|
async: async,
|
||||||
success: function (response) {
|
url: url,
|
||||||
callback(response);
|
success: function (response) {
|
||||||
|
callback(response);
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
...options
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user