mirror of
https://github.com/PlayEdu/backend
synced 2025-06-19 04:47:00 +08:00
多选删除图片资源
This commit is contained in:
parent
d9f002da0a
commit
c94e91a8d0
@ -100,6 +100,15 @@ export const ResourceImagesPage = () => {
|
|||||||
setRefresh(!refresh);
|
setRefresh(!refresh);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const selectAll = () => {
|
||||||
|
let arr = [];
|
||||||
|
for (let i = 0; i < imageList.length; i++) {
|
||||||
|
arr.push(imageList[i].id);
|
||||||
|
}
|
||||||
|
setSelectKey(arr);
|
||||||
|
setRefresh(!refresh);
|
||||||
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<div className="tree-main-body">
|
<div className="tree-main-body">
|
||||||
@ -123,7 +132,9 @@ export const ResourceImagesPage = () => {
|
|||||||
}}
|
}}
|
||||||
></UploadImageSub>
|
></UploadImageSub>
|
||||||
<div className="d-flex">
|
<div className="d-flex">
|
||||||
<Button className="mr-16">全选</Button>
|
<Button className="mr-16" onClick={() => selectAll()}>
|
||||||
|
全选
|
||||||
|
</Button>
|
||||||
<PerButton
|
<PerButton
|
||||||
disabled={selectKey.length === 0}
|
disabled={selectKey.length === 0}
|
||||||
type="primary"
|
type="primary"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user