#
luxiaotao1123
2024-09-29 43c57606c1a64097c8d31feced6e19b3f3ef8964
#
1个文件已修改
39 ■■■■■ 已修改文件
zy-acs-flow/src/page/action/Action.jsx 39 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zy-acs-flow/src/page/action/Action.jsx
@@ -3,7 +3,7 @@
    Form,
    ReferenceField,
    useNotify,
    useResourceContext,
    useTheme,
    useTranslate,
} from 'react-admin';
import {
@@ -14,13 +14,13 @@
    Typography,
    Avatar,
} from '@mui/material';
import { format } from 'date-fns';
import { format, formatRelative } from 'date-fns';
import { blueGrey } from '@mui/material/colors';
export const Action = ({ data }) => {
    const notify = useNotify();
    const translate = useTranslate();
    const theme = useTheme();
    const [isHover, setHover] = useState(false);
    return (
@@ -32,15 +32,15 @@
            <Stack direction="row" spacing={1} alignItems="center" width="100%">
                <Avatar
                    sx={{
                        width: 30,
                        height: 30,
                        bgcolor: blueGrey[500],
                        width: 20,
                        height: 20,
                        fontSize: '.9rem'
                    }}
                >
                    {data.priority}
                </Avatar>
                <Typography color="text.secondary" variant="body2">
                    {data.name}
                    {data.actionType$}
                </Typography>
                <Box flex={1}></Box>
                <Typography
@@ -48,6 +48,7 @@
                    variant="body2"
                    component="span"
                >
                    {/* {formatRelative(new Date(data.ioTime), new Date())} */}
                    {format(data.ioTime, 'yyyy-MM-dd HH:mm:ss') || '-'}
                </Typography>
            </Stack>
@@ -60,21 +61,15 @@
                    },
                }}
            >
                {/* {note.text
                    ?.split('\n')
                    .map((paragraph: string, index: number) => (
                        <Typography
                            component="p"
                            variant="body2"
                            lineHeight={1.5}
                            margin={0}
                            key={index}
                        >
                            {paragraph}
                        </Typography>
                    ))}
                {note.attachments && <NoteAttachments note={note} />} */}
                <Typography
                    component="p"
                    variant="body2"
                    lineHeight={1.5}
                    margin={0}
                >
                    {/* // taskNo code val param action sts uuid
                    {paragraph} */}
                </Typography>
            </Stack>
        </Box>
    );