chenrui
2025-06-03 936b9e3576964243604f64a08543314488aa3cc1
src/views/procurementManagement/procurementLedger/index.vue
@@ -225,7 +225,7 @@
          </el-col>
          <el-col :span="12">
            <el-form-item label="税率(%):" prop="taxRate">
              <el-select v-model="productForm.taxRate" placeholder="请选择" clearable>
              <el-select v-model="productForm.taxRate" placeholder="请选择" clearable @change="mathNum">
                <el-option label="1" value="1"/>
                <el-option label="6" value="6"/>
                <el-option label="13" value="13"/>
@@ -378,6 +378,13 @@
  page.current = 1
  getList()
}
// 子表合计方法
const summarizeChildrenTable = (param) => {
  return proxy.summarizeTable(param, ['taxInclusiveUnitPrice', 'taxInclusiveTotalPrice', 'taxExclusiveTotalPrice', 'ticketsNum', 'ticketsAmount', 'futureTickets', 'futureTicketsAmount'], {
    ticketsNum: { noDecimal: true }, // 不保留小数
    futureTickets: { noDecimal: true }, // 不保留小数
  });
};
const paginationChange = ({ current, limit }) => {
  page.current = current;
  page.size = limit;
@@ -413,7 +420,7 @@
      productList({salesLedgerId: row.id, type: 2}).then(res => {
        const index = tableData.value.findIndex(item => item.id === row.id);
        if (index > -1) {
          tableData.value[index].children = res.rows;
          tableData.value[index].children = res;
        }
        expandedRowKeys.value.push(row.id)
      })
@@ -584,7 +591,7 @@
    if (children && children.length > 0) {
      newItem.children = convertIdToValue(children);
    }
    return newItem;
  });
}
@@ -653,7 +660,7 @@
    }).catch(() => {
      proxy.$modal.msg("已取消")
    })
  }
}
// 关闭产品弹框
@@ -709,12 +716,12 @@
  const day = String(today.getDate()).padStart(2, '0');
  return `${year}-${month}-${day}`;
}
const mathNum = (val) => {
  productForm.value.taxExclusiveTotalPrice = proxy.calculateTaxExclusiveTotalPrice(val, productForm.value.taxRate)
const mathNum = () => {
  productForm.value.taxExclusiveTotalPrice = proxy.calculateTaxExclusiveTotalPrice(productForm.value.taxInclusiveTotalPrice, productForm.value.taxRate)
}
getList()
</script>
<style scoped lang="scss">
</style>
</style>