Commit c1601ee7 authored by zhangwenshuai's avatar zhangwenshuai

update apolloTable upload

parent 8f76c90a
......@@ -42,6 +42,15 @@
}
}
}
.popContainer{
width: 200px;
:global(.ant-popover-inner-content){
padding: 0;
}
.popContent{
padding: @paddingGen;
}
}
.popItem {
border-radius: @borderRadius;
margin-bottom: @marginSm;
......@@ -54,6 +63,5 @@
padding: 5px 10px;
line-height: 1;
font-size: 14px;
color: #2e67c5;
}
}
......@@ -56,10 +56,18 @@ export const Tags = (props: any) => {
{dotVisible && (
<Popover
trigger="click"
onClick={(e) => {
e.stopPropagation();
}}
placement="left"
overlayStyle={{ width: '200px' }}
overlayClassName={s.popContainer}
content={
<div>
<div
className={s.popContent}
onClick={(e) => {
e.stopPropagation();
}}
>
{value.map((item, index) => {
let color = '';
if (options && Array.isArray(options) && options.length > 0) {
......
......@@ -21,7 +21,8 @@ export const ApolloUploadDetail = (props: UploadProps) => {
};
});
}
const onPreview = (item) => {
const onPreview = (item, e) => {
e.stopPropagation();
if (previewModel && previewModel.current && previewModel.current.onPreview) {
previewModel.current.onPreview(item.value, item.name);
}
......
......@@ -20,4 +20,6 @@
.img {
cursor: pointer;
width: 30px;
max-height: 30px;
}
......@@ -5,6 +5,7 @@
overflow: hidden;
display: flex;
align-items: center;
border: 1px solid @primaryColor;
.add {
cursor: pointer;
font-size: @textFontGen;
......
......@@ -71,7 +71,7 @@ export const ApolloUpload = (props: ApolloUploadProps) => {
})}
<Modal visible={visible} title="文件上传" onOk={onOk} onCancel={onCancel}>
<div className={s.uploadContainer}>
<Upload {...selfProps} value={value} onChange={changeValue} />
<Upload {...selfProps} value={props.value} onChange={changeValue} />
</div>
</Modal>
</div>
......
......@@ -24,7 +24,8 @@ export default class uploadDetail extends React.Component {
}
};
handleCancel = () => {
handleCancel = (e) => {
e.stopPropagation();
this.setState({ showDialog: false });
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment