56 lines
1.7 KiB
TypeScript
56 lines
1.7 KiB
TypeScript
import { MyBetaModalFormProps } from '@/common';
|
|
import { MyModal } from '@/components/MyModal';
|
|
import { ProCard, ProDescriptions } from '@ant-design/pro-components';
|
|
import { Typography } from 'antd';
|
|
|
|
const { Text } = Typography;
|
|
|
|
export default function info(props: MyBetaModalFormProps) {
|
|
return (
|
|
<MyModal
|
|
title={props.title || '查看'}
|
|
// width="40vw"
|
|
width={600}
|
|
// style={{ maxWidth: '650px' }}
|
|
node={
|
|
<ProCard>
|
|
<ProDescriptions
|
|
// bordered
|
|
// column={{ xs: 1, sm: 2, md: 3 }}
|
|
column={1}
|
|
size="small"
|
|
>
|
|
<ProDescriptions.Item label=" 关联项目">
|
|
{props?.item?.asset_project?.name || '-'}
|
|
</ProDescriptions.Item>
|
|
<ProDescriptions.Item label="公告标题">
|
|
{props?.item?.title || '-'}
|
|
</ProDescriptions.Item>
|
|
|
|
<ProDescriptions.Item label="公告内容">
|
|
<div
|
|
style={{
|
|
whiteSpace: 'pre-wrap',
|
|
maxHeight: '300px',
|
|
overflow: 'auto',
|
|
}}
|
|
>
|
|
{props?.item?.content || '-'}
|
|
</div>
|
|
</ProDescriptions.Item>
|
|
<ProDescriptions.Item label="发布日期">
|
|
{props?.item?.publish_at || '-'}
|
|
</ProDescriptions.Item>
|
|
<ProDescriptions.Item label="创建时间">
|
|
{props?.item?.created_at || '-'}
|
|
</ProDescriptions.Item>
|
|
<ProDescriptions.Item label="是否发布小程序">
|
|
{props?.item?.is_publish ? '是' : '否'}
|
|
</ProDescriptions.Item>
|
|
</ProDescriptions>
|
|
</ProCard>
|
|
}
|
|
/>
|
|
);
|
|
}
|