liding
8 天以前 06372ae6f71fd776fc3db320c410c38966576c7c
src/views/projectManagement/Management/components/formDia.vue
@@ -583,9 +583,9 @@
          <el-form-item label="含税单价(元):" prop="taxInclusiveUnitPrice">
            <el-input-number
              v-model="productForm.taxInclusiveUnitPrice"
              :step="0.01"
              :step="0.0001"
              :min="0"
              :precision="2"
              :precision="4"
              style="width: 100%"
              placeholder="请输入"
              clearable
@@ -863,7 +863,8 @@
function formattedNumber(row, column, cellValue) {
  const val = Number(cellValue ?? 0)
  return Number.isFinite(val) ? val.toFixed(2) : '0.00'
  if (!Number.isFinite(val)) return '0.00'
  return column.property === 'taxInclusiveUnitPrice' ? val.toFixed(4) : val.toFixed(2)
}
function summarizeProductTable(param) {
@@ -1029,7 +1030,7 @@
  const quantity = parseFloat(productForm.value.quantity)
  if (!totalPrice || !quantity || quantity <= 0) return
  isCalculating.value = true
  productForm.value.taxInclusiveUnitPrice = (totalPrice / quantity).toFixed(2)
  productForm.value.taxInclusiveUnitPrice = (totalPrice / quantity).toFixed(4)
  if (productForm.value.taxRate) {
    productForm.value.taxExclusiveTotalPrice = proxy.calculateTaxExclusiveTotalPrice(totalPrice, productForm.value.taxRate)
  }
@@ -1050,7 +1051,7 @@
  const taxRateDecimal = taxRate / 100
  const inclusiveTotalPrice = exclusiveTotalPrice / (1 - taxRateDecimal)
  productForm.value.taxInclusiveTotalPrice = inclusiveTotalPrice.toFixed(2)
  productForm.value.taxInclusiveUnitPrice = (inclusiveTotalPrice / quantity).toFixed(2)
  productForm.value.taxInclusiveUnitPrice = (inclusiveTotalPrice / quantity).toFixed(4)
  isCalculating.value = false
}