zzq
2023-09-28 2b78cf0cd68e1809bc4cad7d730bef6ab9c4c118
src/views/reportForm/locationReport/index.vue
@@ -48,9 +48,9 @@
</template>
<script>
import pageMixin from "@/components/makepager/pager/mixin/pageMixin"
import { getLocationData } from "@/api/locationApi/locationApi"
import AddOverviewDialog from "@/views/overview/AddOverviewDialog"
import pageMixin from "@/components/makepager/pager/mixin/pageMixin";
import { getLocationData } from "@/api/locationApi/locationApi";
import AddOverviewDialog from "@/views/overview/AddOverviewDialog";
export default {
  name: "InventoryReport",
@@ -106,8 +106,9 @@
        infomation: {}
      },
      productId: this.$route.params.id,
      productName: this.$route.params.name
    }
      productName: this.$route.params.name,
      metaTitle: this.$route.meta.title,
    };
  },
  created() {
    this.setTable()
@@ -164,14 +165,14 @@
          prop: "amount",
          isShowColumn: true,
          default: true,
          unit: ""
          unit: "",
        },
        {
          label: "预留数量",
          prop: "availableStore",
          isShowColumn: true,
          default: true,
          unit: ""
          unit: "",
        },
        {
          label: "单位",
@@ -186,10 +187,10 @@
          width: 120,
          default: false,
          isShowColumn: showcol.includes("价值"),
          unit: "¥"
        }
      ]
      return tableColumn
          unit: "¥",
        },
      ];
      return tableColumn;
    },
    selTableCol(val) {
      this.showcol = val
@@ -202,10 +203,9 @@
        pageSize: this.pagerOptions.pageSize
      }).then((res) => {
        if (res.code === 200) {
          console.log(res.data, "接口请求成功")
          const list = res.data
          this.tableList.tableInfomation = list || []
          this.pagerOptions.totalCount = res.total
          const list = res.data;
          this.tableList.tableInfomation = list || [];
          this.pagerOptions.totalCount = res.total;
        }
      })
    },
@@ -223,16 +223,42 @@
    },
    // 新建
    addBtnClick() {
      this.editConfig.visible = true
      this.editConfig.title = "新建"
      this.getData()
      this.editConfig.visible = true;
      this.editConfig.title = "新建";
      this.getData();
    },
    // 状态
    getStatus(val) {
      return val === 1 ? "草稿" : val === 3 ? "就绪" : "完成"
    },
    // 历史
    handleHistoryClick() {},
    handleHistoryClick(row) {
      this.$router.push({
        name: "inboundOutboundDetail",
        params: {
          name: this.metaTitle,
          pageName:"报表",
          product: {
            page: this.pagerOptions.currPage,
            pageSize: this.pagerOptions.pageSize,
            produceId: row.produceId,
            productName: row.productName,
            unit: row.unit,
          },
          paramsKey: {
            amount: "amount",
            productName:"productName",
            status: "status",
            contactedName: "contactedName",
            date: "date",
            fromLocation: "fromLocation",
            number: "number",
            toLocation: "toLocation",
            unit: "unit",
          },
        },
      });
    },
    // 补货
    handleAddGoods() {}
  }