Takes were mismade
This commit is contained in:
Binary file not shown.
@@ -76,8 +76,8 @@ const Column: React.FC<PropsWithChildren<{ status: OrderStatusEnum; onDrop: (id:
|
|||||||
}));
|
}));
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div ref={drop} style={{ flex: 1, backgroundColor: isOver ? theme.palette.background.paper : 'transparent', padding: 1, minHeight: 200 }}>
|
<div ref={drop} style={{ flex: 1, backgroundColor: isOver ? theme.palette.background.paper : 'transparent', padding: 1 }}>
|
||||||
<Card>
|
<Card sx={{ minHeight: '100%', marginTop: 2, marginLeft: 1 }} elevation={4}>
|
||||||
<CardContent>
|
<CardContent>
|
||||||
<Typography variant="h6">{t(status)}</Typography>
|
<Typography variant="h6">{t(status)}</Typography>
|
||||||
{children}
|
{children}
|
||||||
@@ -158,7 +158,7 @@ export default function OrdersInfo() {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
await patchOrderMutation.mutateAsync({ id: obj.id, status: obj.status });
|
await patchOrderMutation.mutateAsync({ id: obj.id, status: status });
|
||||||
refetch();
|
refetch();
|
||||||
setOrders(orders.map((o) => (o.id === id ? { ...o, status } : o)));
|
setOrders(orders.map((o) => (o.id === id ? { ...o, status } : o)));
|
||||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||||
@@ -170,7 +170,7 @@ export default function OrdersInfo() {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<DndProvider backend={HTML5Backend}>
|
<DndProvider backend={HTML5Backend}>
|
||||||
<div style={{ display: 'flex', gap: 16 }}>
|
<div style={{ display: 'flex', gap: 10, minHeight: '90%' }}>
|
||||||
{statusOrder.map((status) => (
|
{statusOrder.map((status) => (
|
||||||
<Column key={status} status={status} onDrop={handleDrop}>
|
<Column key={status} status={status} onDrop={handleDrop}>
|
||||||
{orders
|
{orders
|
||||||
|
|||||||
Reference in New Issue
Block a user