Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const spinnerHtml = `
<div>
<div class="text-center">傳送到 HKEPC 伺服器中</div>
</div>
`
swal({
animation: false,
html: spinnerHtml,
allowOutsideClick: false,
showCancelButton: false,
showConfirmButton: false
})
swal.showLoading()
// Post to the server
this.apiService.dynamicRequest({
method: 'POST',
url: actionUrl,
data: {
subject: subject,
message: replyMessage,
typeid: _.get(post, 'category.id', undefined),
handlekey: 'newthread',
topicsubmit: true,
...hiddenFormInputs,
...imageFormData,
...deleteImageFormData
},
headers: { 'Content-Type': 'application/x-www-form-urlencoded' }
onBeforeOpen: () => {
Swal.showLoading()
}
})
onOpen: () => {
swal.showLoading()
}
})
onOpen: () => {
swal.showLoading()
}
})
onOpen: () => {
swal.showLoading()
}
})
showLoading () {
const spinnerHtml = `
<div>
<div class="text-center">驗証用戶資料中</div>
</div>
`
swal({
animation: false,
html: spinnerHtml,
allowOutsideClick: false,
showCancelButton: false,
showConfirmButton: false
})
swal.showLoading()
}
onOpen: () => {
swal.showLoading()
}
})
onOpen: () => {
swal.showLoading()
}
})
onOpen: () => {
swal.showLoading()
}
})
export default function (event) {
swal.showLoading();
loadModules(['esri/request']).then(([Request]) => {
new Request(event.item.layer.url, {
query: {f: 'json'},
responseType: 'json'
}).then((response) => {
swal({
title: event.item.layer.title,
text: response.data.description
});
});
});
}