FPSMS-frontend
Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.
 
 

49 wiersze
1.2 KiB

  1. import { Metadata } from "next";
  2. import { getServerI18n, I18nProvider } from "@/i18n";
  3. import Typography from "@mui/material/Typography";
  4. import { Button, Link, Stack } from "@mui/material";
  5. import { Add } from "@mui/icons-material";
  6. import { Suspense } from "react";
  7. import { preloadQcItem } from "@/app/api/settings/qcItem";
  8. import QcItemSearch from "@/components/QcItemSearch";
  9. export const metadata: Metadata = {
  10. title: "Qc Item",
  11. };
  12. const qcItem: React.FC = async () => {
  13. const { t } = await getServerI18n("qcItem");
  14. preloadQcItem();
  15. return (
  16. <>
  17. <Stack
  18. direction="row"
  19. justifyContent="space-between"
  20. flexWrap="wrap"
  21. rowGap={2}
  22. >
  23. <Typography variant="h4" marginInlineEnd={2}>
  24. {t("Qc Item")}
  25. </Typography>
  26. <Button
  27. variant="contained"
  28. startIcon={<Add />}
  29. LinkComponent={Link}
  30. href="qcItem/create"
  31. >
  32. {t("Create Qc Item")}
  33. </Button>
  34. </Stack>
  35. <Suspense fallback={<QcItemSearch.Loading />}>
  36. <I18nProvider namespaces={["common", "qcItem"]}>
  37. <QcItemSearch />
  38. </I18nProvider>
  39. </Suspense>
  40. </>
  41. );
  42. };
  43. export default qcItem;