Tim Mathias Wall Fehlerbehebung.

This commit is contained in:
FlorianSpeicher
2025-06-16 11:37:19 +02:00
parent 838498227c
commit d6e7498c1d
5 changed files with 4 additions and 11 deletions

View File

@@ -104,6 +104,7 @@
"actualPrice": "Endpreis in €",
"stock": "Bestand",
"price100": "Preis in ct",
"price100€": "Preis in €",
"discount100": "Rabatt in %",
"deleteProduct": "Produkt löschen",
"description": "Beschreibung",

View File

@@ -104,6 +104,7 @@
"actualPrice": "Price in €",
"stock": "Stock",
"price100": "Price in ct",
"price100€": "Price in €",
"discount100": "Discount in %",
"deleteProduct": "Delete Product",
"description": "Description",

View File

@@ -18,14 +18,6 @@ export default function AccountsInfo() {
console.log("CustomerEdit", account);
}
/*
for testing purposes
for (let i = 0; i < 100; i++) {
_rows.push(_rows[5]);
}
* */
//TODO: get per REST
const [rows, setRows] = useState<AccountType[]>([]);
const [selectedRows, setSelectedRows] = useState<Set<GridRowId>>(new Set());
@@ -33,7 +25,7 @@ export default function AccountsInfo() {
const { data } = useQuery({
queryKey: ["fetchAccounts", loginData],
queryFn: () => fetchAccounts(loginData? loginData : {email: "", password: "", session: "", customerId: -1}),
queryFn: () => fetchAccounts(loginData? loginData : {email: "", password: "", session: "", customerId: -1, isAdmin: false}),
retry: 3,
retryDelay: 1000,
});
@@ -123,7 +115,6 @@ export default function AccountsInfo() {
showToolbar
processRowUpdate={(updatedRow) => {
setRows(rows.map(row => row.id === updatedRow.id ? updatedRow : row));
//TODO: make REST callback
return updatedRow;
}}
/>

View File

@@ -119,7 +119,7 @@ export default function ItemsInfo() {
},
{
field: 'price100',
headerName: t('price100'),
headerName: t('price100'),
width: 100,
editable: true,
type: 'number',