fix: filter failed files
This commit is contained in:
parent
d321b95fb0
commit
cd6d444a3f
@ -171,7 +171,7 @@ function toValues(fileList) {
|
|||||||
if (!Array.isArray(fileList) && typeof fileList === 'object') {
|
if (!Array.isArray(fileList) && typeof fileList === 'object') {
|
||||||
fileList = [fileList];
|
fileList = [fileList];
|
||||||
}
|
}
|
||||||
return fileList.map(toValue);
|
return fileList.map(toValue).filter(item => item.id);
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getImgUrls(value) {
|
export function getImgUrls(value) {
|
||||||
@ -213,7 +213,8 @@ export const Upload = connect({
|
|||||||
setImgIndex(index);
|
setImgIndex(index);
|
||||||
setVisible(true);
|
setVisible(true);
|
||||||
} else {
|
} else {
|
||||||
window.location.href = value.url;
|
window.open(value.url)
|
||||||
|
// window.location.href = value.url;
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
// itemRender={(originNode, file, fileList) => {
|
// itemRender={(originNode, file, fileList) => {
|
||||||
|
Loading…
Reference in New Issue
Block a user