zouyu
2026-02-25 ea57c9f90d4d5a7698257c7cdf7d681fc91f432b
src/views/business/finishedProductSampling/index.vue
@@ -8,6 +8,7 @@
        <el-button size="small" type="primary" @click="handleStockList">刷新</el-button>
      </div>
      <el-table
        border
        ref="finishedproducttransferTable"
        v-loading="tableLoading"
        :data="stockList"
@@ -18,12 +19,14 @@
        @selection-change="handleSelectionChange"
      >
        <el-table-column type="selection" width="45"></el-table-column>
        <el-table-column type="index" label="序号" align="center" width="60"></el-table-column>
        <el-table-column
          :show-overflow-tooltip="true"
          align="center"
          label="客户订单编号"
          prop="customerOrderNo"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">客户订单编号</div>
@@ -46,7 +49,9 @@
          align="center"
          label="成品零件号"
          prop="partNo"
          width="140"
          width="160"
          min-width="160"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">成品零件号</div>
@@ -69,7 +74,8 @@
          align="center"
          label="零件名称"
          prop="partName"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">零件名称</div>
@@ -89,11 +95,12 @@
          </template>
        </el-table-column>
        <el-table-column
          :show-overflow-tooltip="true"
          align="center"
          label="仓库"
          prop="warehouseName"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">仓库</div>
@@ -113,11 +120,12 @@
          </template>
        </el-table-column>
        <el-table-column
          :show-overflow-tooltip="true"
          align="center"
          label="库位号"
          prop="locationNo"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">库位号</div>
@@ -137,11 +145,12 @@
          </template>
        </el-table-column>
        <el-table-column
          :show-overflow-tooltip="true"
          align="center"
          label="库位名称"
          prop="locationName"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">库位名称</div>
@@ -164,7 +173,9 @@
          align="center"
          label="批次号"
          prop="partBatchNo"
          width="140"
          width="180"
          min-width="180"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">批次号</div>
@@ -188,6 +199,8 @@
          label="入库来源"
          prop="inSource"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">入库来源</div>
@@ -211,6 +224,8 @@
          label="外护颜色"
          prop="outerColor"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
          <template slot="header" slot-scope="scope">
            <div style="line-height: 14px;margin-bottom: 6px">外护颜色</div>
@@ -234,6 +249,8 @@
          label="库存数量"
          prop="stockQuantity"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
        </el-table-column>
        <el-table-column
@@ -241,6 +258,8 @@
          label="可用库存数量"
          prop="availableStockQuantity"
          width="140"
          min-width="140"
          show-overflow-tooltip
        >
          <template slot-scope="scope">
            <span>{{ scope.row.availableStockQuantity }}</span>
@@ -273,6 +292,7 @@
import {mapGetters} from "vuex";
export default {
  name: 'FinishedProductSampling',
  data() {
    return {
      stockList: [],
@@ -350,31 +370,29 @@
      this.tableLoading = true
      this.stockList = []
      const newReqParam = this.getFinalParam()
      getIfsStock(newReqParam)
        .then((response) => {
          const resData = response.data
          this.queryReport.total = resData.total
          const resStockList = resData.data
          resStockList.forEach((item) => {
            this.stockList.push({
              partNo: item.PART_NO,
              partName: item.PART_DESC,
              warehouseName: item.WAREHOUSE_ID,
              locationName: item.LOCATION_DESC,
              locationNo: item.LOCATION_NO,
              partBatchNo: item.LOT_BATCH_NO,
              stockQuantity: item.QTY_ONHAND,
              availableStockQuantity: item.QTY_AVAILABLE,
              outerColor: item.ATTR4,
              customerOrderNo: item.ATTR6,
              inSource: item.ATTR23,
            })
      getIfsStock(newReqParam).then((response) => {
        this.tableLoading = false
        const resData = response.data
        this.queryReport.total = resData.count
        const resStockList = resData.data
        resStockList.forEach((item) => {
          this.stockList.push({
            partNo: item.PART_NO,
            partName: item.PART_DESC,
            warehouseName: item.WAREHOUSE_ID,
            locationName: item.LOCATION_DESC,
            locationNo: item.LOCATION_NO,
            partBatchNo: item.LOT_BATCH_NO,
            stockQuantity: item.QTY_ONHAND,
            availableStockQuantity: item.QTY_AVAILABLE,
            outerColor: item.ATTR4,
            customerOrderNo: item.ATTR6,
            inSource: item.ATTR23,
          })
          this.tableLoading = false
        })
        .catch(() => {
          this.tableLoading = false
        })
      }).catch(() => {
        this.tableLoading = false
      })
    },
    getFinalParam() {
      const newReqParam = {