Browse Source

update po detail

master
cyril.tsui 1 week ago
parent
commit
8394dc29a6
1 changed files with 4 additions and 4 deletions
  1. +4
    -4
      src/components/PoDetail/PoDetail.tsx

+ 4
- 4
src/components/PoDetail/PoDetail.tsx View File

@@ -181,9 +181,9 @@ const PoDetail: React.FC<Props> = ({ po, qc, warehouse }) => {
const pathname = usePathname() const pathname = usePathname()
const searchParams = useSearchParams(); const searchParams = useSearchParams();
const [row, setRow] = useState(rows[0]);
const [stockInLine, setStockInLine] = useState<StockInLine[]>(rows[0].stockInLine);
const [processedQty, setProcessedQty] = useState(rows[0].processed);
const [row, setRow] = useState<PurchaseOrderLine>({});
const [stockInLine, setStockInLine] = useState<StockInLine[]>([]);
const [processedQty, setProcessedQty] = useState(0);


const router = useRouter(); const router = useRouter();
const [poList, setPoList] = useState<PoResult[]>([]); const [poList, setPoList] = useState<PoResult[]>([]);
@@ -671,7 +671,7 @@ const PoDetail: React.FC<Props> = ({ po, qc, warehouse }) => {
{/* area5: selected item info */} {/* area5: selected item info */}
<Grid container xs={12} justifyContent="start"> <Grid container xs={12} justifyContent="start">
<Grid item xs={12}> <Grid item xs={12}>
<Typography variant="h6">已選擇: {row.itemNo}-{row.itemName}</Typography>
<Typography variant="h6">{row.itemNo && row.itemName ? `已選擇: ${row.itemNo}-${row.itemName}` : `未選擇貨品`}</Typography>
</Grid> </Grid>
<Grid item xs={12}> <Grid item xs={12}>
<TableContainer component={Paper} sx={{ width: 'fit-content', overflow: 'auto' }}> <TableContainer component={Paper} sx={{ width: 'fit-content', overflow: 'auto' }}>


Loading…
Cancel
Save