chenrui
2025-06-06 ece2dfeb926d728b10db38038e4d12e9e9851c24
src/views/salesManagement/salesLedger/index.vue
@@ -56,7 +56,7 @@
        <el-table-column label="合同金额(元)" prop="contractAmount" width="180" show-overflow-tooltip :formatter="formattedNumber"/>
        <el-table-column label="录入人" prop="entryPersonName" width="100" show-overflow-tooltip/>
        <el-table-column label="录入日期" prop="entryDate" width="120" show-overflow-tooltip/>
        <el-table-column label="录入日期" prop="executionDate" width="120" show-overflow-tooltip/>
        <el-table-column label="签订日期" prop="executionDate" width="120" show-overflow-tooltip/>
        <el-table-column fixed="right" label="操作" min-width="60" align="center">
          <template #default="scope">
            <el-button link type="primary" size="small" @click="openForm('edit', scope.row);">编辑</el-button>
@@ -307,7 +307,7 @@
import useUserStore from '@/store/modules/user'
import {userListNoPage} from "@/api/system/user.js";
import {
  ledgerList,
  ledgerListPage,
  productList,
  customerList,
  addOrUpdateSalesLedger,
@@ -411,9 +411,9 @@
}
const getList = () => {
  tableLoading.value = true
  ledgerList({...searchForm.value, ...page}).then(res => {
  ledgerListPage({...searchForm.value, ...page}).then(res => {
    tableLoading.value = false
    tableData.value = res.rows
    tableData.value = res.records
    tableData.value.map(item => {
      item.children = []
    })
@@ -439,11 +439,14 @@
  })
}
const getProductModel =(value) => {
  console.log('value', value)
  const index = modelOptions.value.findIndex(item => item.id === value);
  if (index !== -1) {
    productForm.value.specificationModel = modelOptions.value[index].model;
    productForm.value.unit = modelOptions.value[index].unit;
  } else {
    productForm.value.specificationModel = null;
    productForm.value.unit = null;
  }
}
const findNodeById = (nodes, productId) => {