spring
2025-04-02 235f0b0e3605082bb2127dc6d87f4a7eef33c6de
src/views/standard/standardLibrary/components/bindSupplierDensityDialogAsk.vue
@@ -1,46 +1,17 @@
<template>
  <div>
    <el-dialog
      title="厂家要求值绑定"
      :visible.sync="isShow"
      width="800px"
      @close="$emit('closeBindPartDialog')"
    >
      <div
        class="body"
        v-if="isShow"
        style="height: 500px; overflow-y: auto; padding: 5px 0"
      >
        <el-table
          ref="bindPartTable"
          :data="bindPartData"
          v-loading="bindPartTableLoading"
          highlight-current-row
          style="width: 100%"
        >
          <el-table-column
            type="index"
            width="70"
            label="序号"
          ></el-table-column>
          <el-table-column
            property="supplierName"
            label="厂家"
            width="200"
          ></el-table-column>
    <el-dialog title="厂家要求值绑定" :visible.sync="isShow" width="800px" @close="$emit('closeBindPartDialog')">
      <div class="body" v-if="isShow" style="height: 500px; overflow-y: auto; padding: 5px 0">
        <el-table ref="bindPartTable" :data="bindPartData" v-loading="bindPartTableLoading" highlight-current-row
          style="width: 100%">
          <el-table-column type="index" width="70" label="序号"></el-table-column>
          <el-table-column property="supplierName" label="厂家" width="200"></el-table-column>
          <el-table-column property="ask" label="要求值"></el-table-column>
          <el-table-column property="tell" label="要求描述"></el-table-column>
          <el-table-column label="操作" width="100">
            <template slot-scope="scope">
              <el-button
                type="text"
                size="small"
                @click="updateBind(scope.row, 'edit')"
                >编辑</el-button
              >
              <el-button type="text" size="small" @click="deleteBind(scope.row)"
                >删除</el-button
              >
              <el-button type="text" size="small" @click="updateBind(scope.row, 'edit')">编辑</el-button>
              <el-button type="text" size="small" @click="deleteBind(scope.row)">删除</el-button>
            </template>
          </el-table-column>
        </el-table>
@@ -53,55 +24,28 @@
      <!--      </div>-->
      <span slot="footer" class="dialog-footer">
        <el-button @click="$emit('closeBindPartDialog')">取 消</el-button>
        <el-button
          type="primary"
          @click="addBindPart('add')"
          :loading="addBindLoad"
          >新 增</el-button
        >
        <el-button type="primary" @click="addBindPart('add')" :loading="addBindLoad">新 增</el-button>
      </span>
    </el-dialog>
    <el-dialog
      title="厂家要求值绑定"
      :visible.sync="addBindSupplierDensityDialog"
      v-if="addBindSupplierDensityDialog"
      width="400px"
      @close="closeBindPartDialog"
      :close-on-click-modal="false"
    >
    <el-dialog title="厂家要求值绑定" :visible.sync="addBindSupplierDensityDialog" v-if="addBindSupplierDensityDialog"
      width="400px" @close="closeBindPartDialog" :close-on-click-modal="false">
      <div class="body" v-if="addBindSupplierDensityDialog">
        <el-form
          label-position="right"
          label-width="100px"
          ref="bindSupplierDensityData"
          :rules="bindPartDataRules"
          :model="bindSupplierDensityData"
        >
        <el-form label-position="right" label-width="100px" ref="bindSupplierDensityData" :rules="bindPartDataRules"
          :model="bindSupplierDensityData">
          <el-form-item label="厂家:" prop="supplierName">
            <el-input
              v-model="bindSupplierDensityData.supplierName"
              size="small"
            ></el-input>
            <el-input v-model="bindSupplierDensityData.supplierName" size="small"></el-input>
          </el-form-item>
          <el-form-item label="要求值:" prop="ask">
            <el-input
              v-model="bindSupplierDensityData.ask"
              size="small"
            ></el-input>
            <el-input v-model="bindSupplierDensityData.ask" size="small"></el-input>
          </el-form-item>
          <el-form-item label="要求描述:" prop="tell">
            <el-input
              v-model="bindSupplierDensityData.tell"
              size="small"
            ></el-input>
            <el-input v-model="bindSupplierDensityData.tell" size="small"></el-input>
          </el-form-item>
        </el-form>
      </div>
      <span slot="footer" class="dialog-footer">
        <el-button @click="closeBindPartDialog">取 消</el-button>
        <el-button type="primary" @click="submitBind" :loading="bindLoad"
          >确 认</el-button
        >
        <el-button type="primary" @click="submitBind" :loading="bindLoad">确 认</el-button>
      </span>
    </el-dialog>
  </div>
@@ -125,7 +69,7 @@
    currentRow: {
      // 选择本条数据的信息
      type: Object,
      default: () => {},
      default: () => { },
    },
  },
  data() {
@@ -202,7 +146,7 @@
              this.$message.error("删除失败");
            });
        })
        .catch(() => {});
        .catch(() => { });
    },
    sizeChange(val) {
      this.page.size = val;
@@ -236,6 +180,7 @@
                  this.addBindSupplierDensityDialog = false;
                  this.$message.success("操作成功");
                  this.searchTableData();
                  this.$emit('refreshList')
                }
              })
              .catch((err) => {
@@ -251,6 +196,7 @@
                  this.addBindSupplierDensityDialog = false;
                  this.$message.success("操作成功");
                  this.searchTableData();
                  this.$emit('refreshList')
                }
              })
              .catch((err) => {