client brief pdf - upload : add file to field without uploading it if it already exist

This commit is contained in:
isUnknown 2024-10-14 15:23:06 +02:00
parent e74ff559bf
commit a14f1d210f
9 changed files with 132 additions and 86 deletions

View file

@ -76,26 +76,4 @@ function addImages(event) {
images.value = images.value.concat(newImages);
emit("add-images", newImages);
}
// function onAdvancedUpload(event) {
// if (event.xhr.status === 200) {
// toast.add({
// severity: "success",
// summary: "Upload réussi",
// detail: event.xhr.response.success,
// life: 3000,
// });
// const response = JSON.parse(event.xhr.response);
// console.log(response);
// emit("add-images", response.images);
// } else {
// toast.add({
// severity: "error",
// summary: "Échec de l'upload",
// detail: event.xhr.response.error,
// life: 3000,
// });
// console.error(JSON.parse(event.xhr.response));
// }
// }
</script>