| | |
| | | import { useNavigate, useLocation } from 'react-router-dom'; |
| | | import { |
| | | List, |
| | | DatagridConfigurable, |
| | | Datagrid, |
| | | SearchInput, |
| | | TopToolbar, |
| | | SelectColumnsButton, |
| | | EditButton, |
| | | FilterButton, |
| | | CreateButton, |
| | | ExportButton, |
| | | BulkDeleteButton, |
| | | WrapperField, |
| | | useRecordContext, |
| | | useTranslate, |
| | | useNotify, |
| | | useListContext, |
| | | FunctionField, |
| | | TextField, |
| | | NumberField, |
| | | DateField, |
| | | BooleanField, |
| | | ReferenceField, |
| | | TextInput, |
| | | DateTimeInput, |
| | | DateInput, |
| | | SelectInput, |
| | | NumberInput, |
| | | ReferenceInput, |
| | | ReferenceArrayInput, |
| | | AutocompleteInput, |
| | | DeleteButton, |
| | | Button, |
| | | useEditContext, |
| | | useGetRecordId, |
| | | useGetOne |
| | | } from 'react-admin'; |
| | | import { Box, Typography, Card, Stack, Dialog, DialogActions, DialogTitle } from '@mui/material'; |
| | | import { styled } from '@mui/material/styles'; |
| | | import { Box } from '@mui/material'; |
| | | import PageDrawer from "../../components/PageDrawer"; |
| | | import BillStatusField from '../../components/BillStatusField'; |
| | | import { PAGE_DRAWER_WIDTH, OPERATE_MODE, DEFAULT_PAGE_SIZE, DEFAULT_ITEM_PAGE_SIZE } from '@/config/setting'; |
| | | |
| | | const StyledDatagrid = styled(DatagridConfigurable)(({ theme }) => ({ |
| | | '& .css-1vooibu-MuiSvgIcon-root': { |
| | | height: '.9em', |
| | | }, |
| | | '& .RaDatagrid-row': { |
| | | cursor: 'auto' |
| | | }, |
| | | '& .column-name': { |
| | | }, |
| | | '& .opt': { |
| | | width: 200 |
| | | }, |
| | | })); |
| | | import { PAGE_DRAWER_WIDTH, DEFAULT_ITEM_PAGE_SIZE } from '@/config/setting'; |
| | | |
| | | const filters = [ |
| | | <SearchInput source="condition" alwaysOn />, |
| | |
| | | const [drawerVal, setDrawerVal] = useState(false); |
| | | const [select, setSelect] = useState({}); |
| | | const asnId = useGetRecordId(); |
| | | const { data: dicts, isPending, error } = useGetOne('outStock', { id: asnId }); |
| | | |
| | | if (asnId == null || asnId === undefined) { |
| | | return <Box sx={{ flexGrow: 1, minHeight: 200 }} />; |
| | | } |
| | | |
| | | return ( |
| | | <> |
| | | <Box display="flex"> |
| | | <Box display="flex" sx={{ minWidth: 0 }}> |
| | | <List |
| | | resource="checkItem" |
| | | storeKey='checkItem' |
| | | storeKey={`checkItem-detail-${asnId}`} |
| | | sx={{ |
| | | flexGrow: 1, |
| | | transition: (theme) => |
| | | theme.transitions.create(['all'], { |
| | | duration: theme.transitions.duration.enteringScreen, |
| | | }), |
| | | minWidth: 0, |
| | | marginRight: drawerVal ? `${PAGE_DRAWER_WIDTH}px` : 0, |
| | | }} |
| | | title={"menu.checkItem"} |
| | |
| | | actions={( |
| | | <TopToolbar> |
| | | <FilterButton /> |
| | | <SelectColumnsButton preferenceKey='checkItem' /> |
| | | </TopToolbar> |
| | | )} |
| | | perPage={DEFAULT_ITEM_PAGE_SIZE} |
| | | > |
| | | <StyledDatagrid |
| | | preferenceKey='checkItem' |
| | | <Datagrid |
| | | bulkActionButtons={false} |
| | | rowClick={false} |
| | | omit={['id', 'createTime', 'createBy$', 'memo', 'poDetlId', 'purQty', 'trackCode', 'qty','qrcode', 'splrName', 'matnrId', 'orderId']} |
| | | > |
| | | <NumberField source="id" /> |
| | | <NumberField source="orderId" label="table.field.checkOrderItem.orderId" /> |
| | | <TextField source="orderCode" label="table.field.checkOrderItem.orderCode" /> |
| | | <TextField source="matnrId" label="table.field.checkOrderItem.matnrId" /> |
| | |
| | | <TextField source="platOrderCode" label="table.field.checkOrderItem.platOrderCode" /> |
| | | <NumberField source="anfme" label="table.field.checkOrderItem.anfme" /> |
| | | <NumberField source="workQty" label="table.field.checkOrderItem.workQty" /> |
| | | <NumberField source="qty" label="table.field.checkOrderItem.qty" /> |
| | | <TextField source="stockUnit" label="table.field.checkOrderItem.stockUnit" /> |
| | | <TextField source="splrBatch" label="table.field.checkOrderItem.splrBatch" /> |
| | | <TextField source="splrCode" label="table.field.checkOrderItem.splrCode" /> |
| | | <TextField source="splrName" label="table.field.checkOrderItem.splrName" /> |
| | | <DateField source="updateTime" label="common.field.updateTime" showTime /> |
| | | <TextField source="updateBy$" label="common.field.updateBy" /> |
| | | <TextField source="createBy$" label="common.field.createBy" /> |
| | | <DateField source="createTime" label="common.field.createTime" showTime /> |
| | | <TextField source="memo" label="common.field.memo" sortable={false} /> |
| | | </StyledDatagrid> |
| | | </Datagrid> |
| | | </List> |
| | | |
| | | {/* <OutOrderItemCreate |