verou
2025-03-19 932bd3b979d52a4f9147a63adbe6a258a865ed5f
rsf-admin/src/page/basicInfo/loc/LocCreate.jsx
@@ -16,6 +16,7 @@
    useDataProvider,
    useNotify,
    Form,
    SelectArrayInput,
    useCreateController,
} from 'react-admin';
import {
@@ -33,6 +34,7 @@
const LocCreate = (props) => {
    const { open, setOpen } = props;
    const dicts = JSON.parse(localStorage.getItem('sys_dicts'))?.filter(dict => (dict.dictTypeCode == 'sys_loc_type')) || [];
    const translate = useTranslate();
    const notify = useNotify();
@@ -86,7 +88,7 @@
                            <Grid container rowSpacing={2} columnSpacing={2}>
                                <Grid item xs={6} display="flex" gap={1}>
                                    <ReferenceInput
                                        source="warehouseId$"
                                        source="warehouseId"
                                        reference="warehouse"
                                    >
                                        <AutocompleteInput
@@ -119,7 +121,7 @@
                                    />
                                </Grid>
                                <Grid item xs={6} display="flex" gap={1}>
                                    <ReferenceInput
                                    {/* <ReferenceInput
                                        source="type"
                                        reference="dictData"
                                        filter={{ dictTypeCode: 'sys_loc_type' }}
@@ -131,7 +133,19 @@
                                            parse={v => v}
                                            validate={[required()]}
                                        />
                                    </ReferenceInput>
                                    </ReferenceInput> */}
                                    {/* <AutocompleteInput
                                        choices={dicts}
                                        source="type"
                                        optionText="label"
                                        label="table.field.loc.type"
                                        optionValue="value"
                                        parse={v => v}
                                        validate={[required()]}
                                    /> */}
                                    <ReferenceArrayInput source="typeIds" reference="locType" >
                                        <SelectArrayInput label="table.field.loc.type" />
                                    </ReferenceArrayInput>
                                </Grid>
                                {/* <Grid item xs={6} display="flex" gap={1}>
                                    <TextInput
@@ -140,7 +154,7 @@
                                        parse={v => v}
                                    />
                                </Grid> */}
                                <Grid item xs={6} display="flex" gap={1}>
                                {/* <Grid item xs={6} display="flex" gap={1}>
                                    <NumberInput
                                        label="table.field.loc.flagLogic"
                                        source="flagLogic"
@@ -159,7 +173,7 @@
                                        source="barcode"
                                        parse={v => v}
                                    />
                                </Grid>
                                </Grid> */}
                                {/* <Grid item xs={6} display="flex" gap={1}>
                                    <TextInput
                                        label="table.field.loc.unit"
@@ -208,7 +222,7 @@
                                        validate={required()}
                                    />
                                </Grid>
                                <Grid item xs={6} display="flex" gap={1}>
                                {/* <Grid item xs={6} display="flex" gap={1}>
                                    <NumberInput
                                        label="table.field.loc.channel"
                                        source="channel"
@@ -240,7 +254,7 @@
                                        parse={v => v}
                                        validate={required()}
                                    />
                                </Grid>
                                </Grid> */}
                                <Grid item xs={6} display="flex" gap={1}>
                                    <StatusSelectInput />