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