| | |
| | | prop="unit" |
| | | width="100" /> |
| | | <el-table-column label="需求数量" |
| | | prop="demandedQuantity" |
| | | width="100" /> |
| | | min-width="100"> |
| | | <template #default="{ row }"> |
| | | {{ stripTrailingZeros(row.demandedQuantity) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="领用数量" |
| | | prop="pickQuantity" |
| | | width="100" /> |
| | | min-width="100"> |
| | | <template #default="{ row }"> |
| | | {{ stripTrailingZeros(row.pickQuantity) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="已补数量" |
| | | prop="feedingQty" |
| | | width="100" /> |
| | | min-width="100"> |
| | | <template #default="{ row }"> |
| | | {{ stripTrailingZeros(row.feedingQty) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="补料数量" |
| | | min-width="150"> |
| | | <template #default="{ row }"> |
| | | <el-input-number v-model="row.newSupplementQty" |
| | | :min="0" |
| | | :precision="3" |
| | | :step="1" |
| | | controls-position="right" |
| | | placeholder="输入补料数量" |
| | | :formatter="value => stripTrailingZeros(value)" |
| | | :parser="value => parseFloat(value) || 0" |
| | | style="width: 100%;" /> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | updateMaterialPickingLedger, |
| | | } from "@/api/productionManagement/productionOrder.js"; |
| | | |
| | | const stripTrailingZeros = val => { |
| | | const str = String(val ?? ""); |
| | | if (str.includes(".")) { |
| | | return parseFloat(str).toString(); |
| | | } |
| | | return str; |
| | | }; |
| | | |
| | | const props = defineProps({ |
| | | modelValue: { type: Boolean, default: false }, |
| | | orderRow: { type: Object, default: null }, |