From 4fe1a741d807b55f7fc14aed85e232b9d7972425 Mon Sep 17 00:00:00 2001 From: luxiaotao1123 <t1341870251@163.com> Date: 星期一, 23 九月 2024 13:28:44 +0800 Subject: [PATCH] # --- zy-acs-flow/src/page/agv/show/AgvShowTask.jsx | 53 +++++++++++++++++++++++++++++++++++++++++++---------- 1 files changed, 43 insertions(+), 10 deletions(-) diff --git a/zy-acs-flow/src/page/agv/show/AgvShowTask.jsx b/zy-acs-flow/src/page/agv/show/AgvShowTask.jsx index e96b793..4c479bc 100644 --- a/zy-acs-flow/src/page/agv/show/AgvShowTask.jsx +++ b/zy-acs-flow/src/page/agv/show/AgvShowTask.jsx @@ -24,11 +24,11 @@ import request from '@/utils/request'; import { useTheme } from '@mui/material/styles'; import { getTaskStsColor } from '@/utils/common'; +import ListEmptyTip from "../../components/ListEmptyTip"; const TaskItem = ({ record, now }) => { const translate = useTranslate(); const theme = useTheme(); - console.log(record); return ( <> @@ -50,16 +50,51 @@ </Avatar> </ListItemAvatar> <ListItemText - primary={`${record.taskType$}`} + primary={<> + <Stack direction={'row'}> + <Typography + variant="body1" + color="textSecondary" + component="span" + sx={{ fontWeight: '600' }} + > + {record.taskType$} + </Typography> + <Typography + variant="caption" + color="textSecondary" + component="span" + > + - {record.taskTypeEl} + </Typography> + </Stack> + + </>} secondary={ <> - {record.taskSts$} - + <Typography + variant="body2" + color="textSecondary" + component="span" + sx={{ fontWeight: 'bold' }} + > + {record.taskSts$} + </Typography> </> } /> <ListItemText - primary={`${record.oriLoc$ || ''}${record.oriSta$ || ''} - ${record.destLoc$ || ''}${record.destSta$ || ''}`} + variant="body2" + color="textSecondary" + primary={<> + <Typography + variant="body2" + color="textPrimary" + component="span" + > + {record.oriLoc$ || ''}{record.oriSta$ || ''} - {record.destLoc$ || ''}{record.destSta$ || ''} + </Typography> + </>} secondary={`code: ${record.destCode$ || ''}`} /> <ListItemSecondaryAction> @@ -82,6 +117,7 @@ const [currCount, setCurrCount] = useState(pageSize); const [records, setRecords] = useState(null); const [total, setTotal] = useState(0); + const translate = useTranslate(); useEffect(() => { const http = async () => { @@ -146,7 +182,6 @@ ) })} - {currCount < total && ( <Button onClick={() => @@ -158,15 +193,13 @@ fullWidth sx={{ mt: 1 }} > - Load more activity + {translate('common.action.loadMore')} </Button> )} </List> </Box> ) : ( - <Typography> - no data found - </Typography> + <ListEmptyTip /> )} </> -- Gitblit v1.9.1