Browse Source

update uom code -> desc

master
cyril.tsui 1 day ago
parent
commit
8b46ff43b6
5 changed files with 7 additions and 7 deletions
  1. +1
    -1
      src/app/api/settings/uom/index.ts
  2. +1
    -1
      src/components/PoDetail/EscalationForm.tsx
  3. +2
    -2
      src/components/PoDetail/PoDetail.tsx
  4. +2
    -2
      src/components/PoDetail/PoInputGrid.tsx
  5. +1
    -1
      src/components/PoDetail/StockInFormVer2.tsx

+ 1
- 1
src/app/api/settings/uom/index.ts View File

@@ -8,7 +8,7 @@ import { BASE_API_URL } from "../../../../config/api";
export interface Uom {
id: number;
code: string;
name: string;
udfudesc: string;
unit1: string;
unit1Qty: number;
unit2?: string;


+ 1
- 1
src/components/PoDetail/EscalationForm.tsx View File

@@ -141,7 +141,7 @@ const EscalationForm: React.FC<Props> = ({
label={t("uom")}
fullWidth
disabled={true}
defaultValue={itemDetail.uom.code}
defaultValue={itemDetail?.uom?.udfudesc}
/>
</Grid>
<Grid item xs={12}>


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

@@ -510,10 +510,10 @@ const PoDetail: React.FC<Props> = ({ po, qc, warehouse, printerCombo }) => {
<TableCell align="left">{row.itemName}</TableCell>
<TableCell align="right">{integerFormatter.format(row.qty)}</TableCell>
<TableCell align="right">{integerFormatter.format(row.processed)}</TableCell>
<TableCell align="left">{row.uom?.code}</TableCell>
<TableCell align="left">{row.uom?.udfudesc}</TableCell>
{/* <TableCell align="right">{decimalFormatter.format(row.stockUom.stockQty)}</TableCell> */}
<TableCell align="right">{decimalFormatter.format(row.stockInLine.filter((sil) => sil.purchaseOrderLineId === row.id).reduce((acc, cur) => acc + (cur.acceptedQty ?? 0),0) * purchaseToStockRatio)}</TableCell>
<TableCell align="left">{row.stockUom.stockUomCode}</TableCell>
<TableCell align="left">{row.stockUom.stockUomDesc}</TableCell>
{/* <TableCell align="right">
{decimalFormatter.format(totalWeight)} {weightUnit}
</TableCell> */}


+ 2
- 2
src/components/PoDetail/PoInputGrid.tsx View File

@@ -531,7 +531,7 @@ const closeNewModal = useCallback(() => {
width: 150,
// flex: 0.5,
renderCell: (params) => {
return params.row.uom?.code;
return params.row.uom?.udfudesc;
},
},
{
@@ -554,7 +554,7 @@ const closeNewModal = useCallback(() => {
width: 150,
// flex: 0.5,
renderCell: (params) => {
return itemDetail.stockUom.stockUomCode;
return itemDetail.stockUom.stockUomDesc;
},
},
// {


+ 1
- 1
src/components/PoDetail/StockInFormVer2.tsx View File

@@ -321,7 +321,7 @@ const StockInFormVer2: React.FC<Props> = ({
<TextField
label={t("uom")}
fullWidth
{...register("uom.code", {
{...register("uom.udfudesc", {
required: "uom required!",
})}
// value={uom?.code}


Loading…
Cancel
Save