chenrui
7 天以前 e2faef4edc8c200b20d9a82206755042dbe5fead
src/views/salesManagement/salesLedger/index.vue
@@ -53,7 +53,7 @@
        <el-table-column label="业务员" prop="salesman" show-overflow-tooltip/>
        <el-table-column label="项目名称" prop="projectName" show-overflow-tooltip/>
        <el-table-column label="合同金额(元)" prop="contractAmount" show-overflow-tooltip/>
        <el-table-column label="录入人" prop="entryPerson" show-overflow-tooltip/>
        <el-table-column label="录入人" prop="entryPersonName" show-overflow-tooltip/>
        <el-table-column label="录入日期" prop="entryDate" show-overflow-tooltip/>
        <el-table-column fixed="right" label="操作" min-width="60" align="center">
          <template #default="scope">
@@ -447,13 +447,16 @@
    if (children && children.length > 0) {
      newItem.children = convertIdToValue(children);
    }
    return newItem;
  });
}
// 表格选择数据
const handleSelectionChange = (selection) => {
  selectedRows.value = selection
  // 过滤掉子数据
  selectedRows.value = selection.filter(item => item.children !== undefined);
  console.log('selection',selectedRows.value)
}
const productSelected = (selectedRows) => {
  productSelectedRows.value = selectedRows
@@ -467,7 +470,7 @@
      productList({salesLedgerId: row.id, type: 1}).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)
    })
@@ -689,7 +692,7 @@
    }).catch(() => {
      proxy.$modal.msg("已取消")
    })
  }
}
// 关闭产品弹框
@@ -753,4 +756,4 @@
<style scoped lang="scss">
</style>
</style>