import ObjectSelect, {ObjectSelectProps} from "../../ObjectSelect/ObjectSelect.tsx";
import {BarcodeTemplateSchema} from "../../../client";
import useGetAllBarcodeTemplates from "../../../api/barcode/useGetAllBarcodeTemplates.tsx";

type Props = Omit<ObjectSelectProps<BarcodeTemplateSchema>, 'data'>;

const BarcodeTemplateSelect = (props: Props) => {
    const {barcodeTemplates} = useGetAllBarcodeTemplates();

    return (
        <ObjectSelect
            data={barcodeTemplates}
            {...props}
        />
    )
}

export default BarcodeTemplateSelect;