duhe
2025-11-19 a9ca5dafb781919fe8a24cd586258e9144966271
src/views/sell/XsSeOutStockBackBillList.vue
@@ -9,15 +9,23 @@
      class="searchBox"
    >
      <el-row>
        <el-form-item label="日期" style="margin-left: 100px">
        <el-form-item label="开始日期" style="margin-left: 100px">
          <el-date-picker
            v-model="dateRange"
            value-format="yyyy-MM-dd"
            type="daterange"
            range-separator="-"
            start-placeholder="开始日期"
            end-placeholder="结束日期"
          ></el-date-picker>
            v-model="sTime"
            type="date"
            placeholder="开始日期"
            style="width: 150px"
          >
          </el-date-picker>
        </el-form-item>
        <el-form-item label="结束日期">
          <el-date-picker
            v-model="eTime"
            type="date"
            placeholder="结束日期"
            style="width: 150px"
          >
          </el-date-picker>
        </el-form-item>
        <el-form-item label="日期间隔">
          <el-select
@@ -776,10 +784,18 @@
      uploadTotal: 0,
    };
  },
  mounted() {},
  mounted() {
    window.editGyClose = () => {
      this.editGyClose(); // 组件内的方法绑定到windows
    };
  },
  created() {
    this.riqiChange();
    this.getList();
  },
  beforeDestroy() {
    // 组件销毁时清理全局方法,避免内存泄漏
    delete window.editGyClose;
  },
  methods: {
    BillSync() {
@@ -875,7 +891,6 @@
      // const ddE = String(end.getDate()).padStart(2, "0");
      this.sTime = start;
      this.eTime = end;
      this.dateRange = [this.sTime, this.eTime];
    },
    organizationChange(val) {
      // let options=undefined
@@ -929,11 +944,9 @@
      // this.sWhere += ` and CONVERT(varchar(100),日期, 23) >= '2020-01-01' and CONVERT(varchar(100),日期, 23) <= '2030-01-01'`;
      // 收料通知单列表
      if (this.dateRange.length > 0) {
        this.sWhere +=
          " and CONVERT(varchar(100),日期, 23) >= '" + this.dateRange[0] + "'";
        this.sWhere +=
          " and CONVERT(varchar(100),日期, 23) <= '" + this.dateRange[1] + "'";
      if (this.sTime && this.eTime) {
        this.sWhere += " and CONVERT(varchar(100),日期, 23) >= '" + this.sTime + "'";
        this.sWhere += " and CONVERT(varchar(100),日期, 23) <= '" + this.eTime + "'";
      }
      try {
@@ -1285,6 +1298,7 @@
        }
        this.sWhere += " and " + this.queryParams.ColName2 + " " + com2;
      }
      if (this.queryParams.HBillNo) {
        this.sWhere += " and 单据号 like '%" + this.queryParams.HBillNo + "%'";
      }