confirm-receive.js
507 Bytes
var _alert = require('../../plugins/dialog').Alert;
function confirmReceive(orderCode) {
$.ajax({
url: '/me/confirmReceive',
data: {
orderCode: orderCode
}
}).done(function(r) {
if (r.code === 200) {
location.reload();
} else {
new _alert('<h1>' + r.message + '</h1>').show();
}
}).fail(function(e) {
new _alert('<h1>' + e + '</h1>').show();
});
}
module.exports = {
done: confirmReceive
};