|
@@ -7,6 +7,7 @@ import { useModel } from "umi"
|
|
import ImgModal from "./components/imgModal"
|
|
import ImgModal from "./components/imgModal"
|
|
import TreeBox from "./components/tree"
|
|
import TreeBox from "./components/tree"
|
|
import SortModal from "./components/fileModal/sortModal"
|
|
import SortModal from "./components/fileModal/sortModal"
|
|
|
|
+import { EyeOutlined } from "@ant-design/icons"
|
|
|
|
|
|
interface News {
|
|
interface News {
|
|
id: number,
|
|
id: number,
|
|
@@ -77,7 +78,7 @@ function FlieBox(props: Props) {
|
|
isAll && <li onClick={allFile}>全选/反选</li>
|
|
isAll && <li onClick={allFile}>全选/反选</li>
|
|
}
|
|
}
|
|
{mediaType === 'PAGE' ? <>
|
|
{mediaType === 'PAGE' ? <>
|
|
- <li onClick={() => { setPage && setPage(1, rightClickPup.id) }}>查看</li>
|
|
|
|
|
|
+ {/* <li onClick={() => { setPage && setPage(1, rightClickPup.id) }}>查看</li> */}
|
|
<li onClick={() => { setPage && setPage(2, rightClickPup.id) }}>复制</li>
|
|
<li onClick={() => { setPage && setPage(2, rightClickPup.id) }}>复制</li>
|
|
<li onClick={() => { setPage && setPage(3, rightClickPup.id) }}>批量复制</li>
|
|
<li onClick={() => { setPage && setPage(3, rightClickPup.id) }}>批量复制</li>
|
|
</> : <>
|
|
</> : <>
|
|
@@ -273,26 +274,29 @@ function FlieBox(props: Props) {
|
|
switch (topPageElements?.elementType) {
|
|
switch (topPageElements?.elementType) {
|
|
case 'TOP_IMAGE':
|
|
case 'TOP_IMAGE':
|
|
topName = "顶部图片"
|
|
topName = "顶部图片"
|
|
- El = <Image src={topPageElements?.topImageSpec?.imageUrl} onClick={(e) => { e.stopPropagation() }} />
|
|
|
|
|
|
+ El = <Image src={topPageElements?.topImageSpec?.imageUrl} preview={{ visible: false }} onClick={(e) => { e.stopPropagation(); setPage && setPage(1, item.id) }} />
|
|
break
|
|
break
|
|
case 'TOP_SLIDER':
|
|
case 'TOP_SLIDER':
|
|
topName = "顶部轮播图"
|
|
topName = "顶部轮播图"
|
|
El = <>
|
|
El = <>
|
|
<Carousel autoplay style={{ width: 150, textAlign: 'center' }}>
|
|
<Carousel autoplay style={{ width: 150, textAlign: 'center' }}>
|
|
- {topPageElements?.topSliderSpec?.imageUrlList?.map((item: string, index: number) => <div key={index}>
|
|
|
|
- <Image preview={{ visible: false }} src={item} onClick={(e) => { e.stopPropagation(); setImgVisible(true) }} />
|
|
|
|
|
|
+ {topPageElements?.topSliderSpec?.imageUrlList?.map((url: string, index: number) => <div key={index}>
|
|
|
|
+ <Image preview={{ visible: false }} src={url} onClick={(e) => { e.stopPropagation(); /*setImgVisible(true)*/ setPage && setPage(1, item.id) }} />
|
|
</div>)}
|
|
</div>)}
|
|
</Carousel>
|
|
</Carousel>
|
|
- <div style={{ display: 'none' }}>
|
|
|
|
|
|
+ {/* <div style={{ display: 'none' }}>
|
|
<Image.PreviewGroup preview={{ visible: imgVisible, onVisibleChange: vis => setImgVisible(vis) }}>
|
|
<Image.PreviewGroup preview={{ visible: imgVisible, onVisibleChange: vis => setImgVisible(vis) }}>
|
|
{topPageElements?.topSliderSpec?.imageUrlList?.map((item: string, index: number) => <Image src={item} key={index} />)}
|
|
{topPageElements?.topSliderSpec?.imageUrlList?.map((item: string, index: number) => <Image src={item} key={index} />)}
|
|
</Image.PreviewGroup>
|
|
</Image.PreviewGroup>
|
|
- </div>
|
|
|
|
|
|
+ </div> */}
|
|
</>
|
|
</>
|
|
break
|
|
break
|
|
case 'TOP_VIDEO':
|
|
case 'TOP_VIDEO':
|
|
topName = "顶部视频"
|
|
topName = "顶部视频"
|
|
- El = <video src={topPageElements?.topVideoSpec?.videoUrl} style={{ width: 130, height: 100 }} controls />
|
|
|
|
|
|
+ El = <div className={style.pageVideo}>
|
|
|
|
+ <span className={style.pagePreview} onClick={(e) => { e.stopPropagation(); setPage && setPage(1, item.id) }}><EyeOutlined /> 预览</span>
|
|
|
|
+ <video src={topPageElements?.topVideoSpec?.videoUrl} style={{ width: 130, height: 100 }} controls/>
|
|
|
|
+ </div>
|
|
break
|
|
break
|
|
}
|
|
}
|
|
}
|
|
}
|