import React from 'react'; import { PageHeaderWrapper } from '@ant-design/pro-layout'; import { Col, Row, Divider } from 'antd'; import { getMachineryDetail } from '@/services/machinery'; import Summary from './components/Summary'; import Machines from './components/Machines'; import MaImg from './components/MaImg'; export default (props) => { const { location } = props; const { user, machineryId } = location.query || {}; const [current, setCurrent] = React.useState({}); const userId = user || current.ownerId; React.useEffect(() => { if (machineryId) { getMachineryDetail(machineryId).then(setCurrent); } }, [machineryId]); return (
); };