chenhj
2025-12-18 2fc58fbb10745abd97168b8da21d4142e11d7f2e
src/views/salesManagement/receiptPaymentHistory/index.vue
@@ -19,7 +19,7 @@
          :prefix-icon="Search"
        />
      </el-form-item>
      <el-form-item label="项目名称">
      <!-- <el-form-item label="项目名称">
        <el-input
          v-model="searchForm.projectName"
          placeholder="输入项目名称"
@@ -27,7 +27,7 @@
          clearable
          :prefix-icon="Search"
        />
      </el-form-item>
      </el-form-item> -->
      <el-form-item label="回款日期">
        <el-date-picker
          v-model="searchForm.receiptPaymentDate"
@@ -94,11 +94,11 @@
    prop: "customerName",
    width:240
  },
  {
    label: "项目名称",
    prop: "projectName",
    width:200
  },
  // {
  //   label: "项目名称",
  //   prop: "projectName",
  //   width:200
  // },
  {
    label: "回款金额(元)",
    prop: "receiptPaymentAmount",
@@ -150,7 +150,7 @@
  receiptPaymentDateStart: undefined,
  receiptPaymentDateEnd: undefined,
  customerContractNo: undefined,
  projectName: undefined,
  // projectName: undefined,
});
const { receipt_payment_type } = proxy.useDict("receipt_payment_type");
const isShowSummarySon = ref(true);
@@ -168,7 +168,11 @@
const getList = () => {
  tableLoading.value = true;
  const { receiptPaymentDate, ...rest } = searchForm;
  receiptPaymentHistoryListPage({ ...rest, ...page }).then((res) => {
  // 将范围日期字段传递给后端
  const params = { ...rest, ...page };
  // 移除回款日期的默认值设置,只保留范围日期字段
  delete params.receiptPaymentDate;
  receiptPaymentHistoryListPage(params).then((res) => {
    tableLoading.value = false;
    tableData.value = res.records;
      page.total = res.total;
@@ -212,6 +216,12 @@
};
onMounted(() => {
  // 设置回款日期范围默认值为当天
  const today = dayjs().format('YYYY-MM-DD');
  searchForm.receiptPaymentDate = [today, today];
  // 设置范围日期字段的起始和结束时间
  searchForm.receiptPaymentDateStart = dayjs(today).format('YYYY-MM-DD 00:00:00');
  searchForm.receiptPaymentDateEnd = dayjs(today).format('YYYY-MM-DD 23:59:59');
  getList();
});
</script>