diff --git a/01-frontend/src/helper/adminpanel/ItemsInfo.tsx b/01-frontend/src/helper/adminpanel/ItemsInfo.tsx index 62f8dd1..d5f8d3d 100644 --- a/01-frontend/src/helper/adminpanel/ItemsInfo.tsx +++ b/01-frontend/src/helper/adminpanel/ItemsInfo.tsx @@ -4,7 +4,7 @@ import {Box, Button, IconButton, Toolbar, useTheme} from "@mui/material"; import Item from "../../components/Item"; import {useTranslation} from "react-i18next"; import {DataGrid, GridColDef, GridRowId, GridRowSelectionModel} from "@mui/x-data-grid"; -import {useEffect, useState} from "react"; +import {useState} from "react"; import {Gauge, gaugeClasses} from "@mui/x-charts"; export default function ItemsInfo() { @@ -147,23 +147,23 @@ export default function ItemsInfo() { width: 100, editable: true, type: 'number', - renderCell: params => {return mapValueToColor(0, params.row.stockExpected, params.row.stock)}, }, - }}/> + }} text={() => `${params.row.stock}`} /> }, { field: 'rating', headerName: t('rating'), width: 100, - editable: true, + editable: false, //the rating is averaged from ratings type: 'number', - renderCell: params => {return mapValueToColor(0, 10, params.row.rating)}, }, - }}/> + }} text={() => `${params.row.rating}`} /> }, { //edit billing information button field: "actualPrice",