文件上传失败检测
continuous-integration/drone/push Build is passing Details

uat_us
wangxiaoshuang 2024-06-26 17:14:25 +08:00
parent 64a0e68448
commit bb6bf409b7
1 changed files with 11 additions and 6 deletions

View File

@ -55,10 +55,15 @@ export const anonymization = function (file, config) {
} }
} }
// console.log(dataset) // console.log(dataset)
try {
let newDicomFile = dataset.write() let newDicomFile = dataset.write()
const bufferArray = new Uint8Array(newDicomFile) const bufferArray = new Uint8Array(newDicomFile)
const blob = new Blob([bufferArray], { type: 'application/octet-stream' }) const blob = new Blob([bufferArray], { type: 'application/octet-stream' })
resolve({ blob, pixelDataElement }) resolve({ blob, pixelDataElement })
} catch (err) {
console.log(err)
resolve(false);
}
}; };
reader.readAsArrayBuffer(file); reader.readAsArrayBuffer(file);
} catch (e) { } catch (e) {