From 07f464a5ca04788d38086803433b979ae58ff4b0 Mon Sep 17 00:00:00 2001
From: yaowanxin <3588231647@qq.com>
Date: 星期五, 26 十二月 2025 13:32:07 +0800
Subject: [PATCH] 统一输入框模糊查询,黑名单,添加资质管理字段,可上传资质文件

---
 src/views/procurementManagement/procurementLedger/index.vue    |   29 
 src/views/basicData/supplierManage/index.vue                   |  558 ----------------
 src/views/qualityManagement/nearExpiryReturn/index.vue         |    2 
 src/api/procurementManagement/procurementLedger.js             |    2 
 src/views/basicData/supplierManage/components/BlacklistTab.vue |  564 +++++++++++++++++
 src/api/basicData/supplierManageFile.js                        |   25 
 src/views/basicData/supplierManage/filesDia.vue                |  199 ++++++
 src/views/basicData/supplierManage/components/HomeTab.vue      |  569 +++++++++++++++++
 8 files changed, 1,410 insertions(+), 538 deletions(-)

diff --git a/src/api/basicData/supplierManageFile.js b/src/api/basicData/supplierManageFile.js
index 3b1ab97..6d3f28b 100644
--- a/src/api/basicData/supplierManageFile.js
+++ b/src/api/basicData/supplierManageFile.js
@@ -49,4 +49,27 @@
         data: ids
     })
 }
-
+// 鏌ヨ闄勪欢鍒楄〃
+export function fileListPage(query) {
+    return request({
+        url: "/basic/supplierManageFile/listPage",
+        method: "get",
+        params: query,
+    });
+}
+// 淇濆瓨闄勪欢鍒楄〃
+export function fileAdd(query) {
+    return request({
+        url: "/basic/supplierManageFile/add",
+        method: "post",
+        data: query,
+    });
+}
+// 鍒犻櫎闄勪欢鍒楄〃
+export function fileDel(query) {
+    return request({
+        url: "/basic/supplierManageFile/del",
+        method: "delete",
+        data: query,
+    });
+}
diff --git a/src/api/procurementManagement/procurementLedger.js b/src/api/procurementManagement/procurementLedger.js
index 9fb284e..c3b5d86 100644
--- a/src/api/procurementManagement/procurementLedger.js
+++ b/src/api/procurementManagement/procurementLedger.js
@@ -57,7 +57,7 @@
     params: query,
   });
 }
-
+// 鏌ヨ閲囪喘鍙拌处鍒楄〃
 export function purchaseListPage(query) {
   return request({
     url: "/purchase/ledger/listPage",
diff --git a/src/views/basicData/supplierManage/components/BlacklistTab.vue b/src/views/basicData/supplierManage/components/BlacklistTab.vue
new file mode 100644
index 0000000..894a286
--- /dev/null
+++ b/src/views/basicData/supplierManage/components/BlacklistTab.vue
@@ -0,0 +1,564 @@
+<template>
+  <div class="app-container">
+    <div class="search_form">
+      <div>
+        <span class="search_title">渚涘簲鍟嗘。妗堬細</span>
+        <el-input
+            v-model="searchForm.supplierName"
+            style="width: 240px"
+            placeholder="杈撳叆渚涘簲鍟嗗悕绉版悳绱�"
+            @change="handleQuery"
+            clearable
+            :prefix-icon="Search"
+        />
+        <el-button type="primary" @click="handleQuery" style="margin-left: 10px"
+        >鎼滅储</el-button
+        >
+      </div>
+      <div>
+        <el-button @click="handleOut">瀵煎嚭</el-button>
+        <el-button type="danger" plain @click="handleDelete">鍒犻櫎</el-button>
+      </div>
+    </div>
+    <div class="table_list">
+      <PIMTable
+          rowKey="id"
+          :column="tableColumn"
+          :tableData="tableData"
+          :page="page"
+          :isSelection="true"
+          @selection-change="handleSelectionChange"
+          :tableLoading="tableLoading"
+          @pagination="pagination"
+      ></PIMTable>
+    </div>
+    <el-dialog
+        v-model="dialogFormVisible"
+        :title="operationType === 'add' ? '鏂板渚涘簲鍟嗕俊鎭�' : '缂栬緫渚涘簲鍟嗕俊鎭�'"
+        width="70%"
+        @close="closeDia"
+    >
+      <el-form
+          :model="form"
+          label-width="140px"
+          label-position="top"
+          :rules="rules"
+          ref="formRef"
+      >
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="渚涘簲鍟嗗悕绉帮細" prop="supplierName">
+              <el-input
+                  v-model="form.supplierName"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item
+                label="绾崇◣浜鸿瘑鍒彿锛�"
+                prop="taxpayerIdentificationNum"
+            >
+              <el-input
+                  v-model="form.taxpayerIdentificationNum"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="鍏徃鍦板潃锛�" prop="companyAddress">
+              <el-input
+                  v-model="form.companyAddress"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="鍏徃鐢佃瘽锛�" prop="companyPhone">
+              <el-input
+                  v-model="form.companyPhone"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="寮�鎴疯锛�" prop="bankAccountName">
+              <el-input
+                  v-model="form.bankAccountName"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="璐﹀彿锛�" prop="bankAccountNum">
+              <el-input
+                  v-model="form.bankAccountNum"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="鑱旂郴浜猴細" prop="contactUserName">
+              <el-input
+                  v-model="form.contactUserName"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="鑱旂郴鐢佃瘽锛�" prop="contactUserPhone">
+              <el-input
+                  v-model="form.contactUserPhone"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="缁存姢浜猴細" prop="maintainUserId">
+              <el-select
+                  v-model="form.maintainUserId"
+                  placeholder="璇烽�夋嫨"
+                  clearable
+                  disabled
+              >
+                <el-option
+                    v-for="item in userList"
+                    :key="item.nickName"
+                    :label="item.nickName"
+                    :value="item.userId"
+                />
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="缁存姢鏃堕棿锛�" prop="maintainTime">
+              <el-date-picker
+                  style="width: 100%"
+                  v-model="form.maintainTime"
+                  value-format="YYYY-MM-DD"
+                  format="YYYY-MM-DD"
+                  type="date"
+                  placeholder="璇烽�夋嫨"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="鏄惁鐧藉悕鍗曪細" prop="isWhite">
+              <el-select v-model="form.isWhite" placeholder="璇烽�夋嫨" clearable>
+                <el-option label="鏄�" :value="0" />
+                <el-option label="鍚�" :value="1" />
+              </el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <template #footer>
+        <div class="dialog-footer">
+          <el-button type="primary" @click="submitForm">纭</el-button>
+          <el-button @click="closeDia">鍙栨秷</el-button>
+        </div>
+      </template>
+    </el-dialog>
+
+    <!-- 渚涘簲鍟嗗鍏ュ璇濇 -->
+    <el-dialog
+        :title="upload.title"
+        v-model="upload.open"
+        width="400px"
+        append-to-body
+    >
+      <el-upload
+          ref="uploadRef"
+          :limit="1"
+          accept=".xlsx, .xls"
+          :headers="upload.headers"
+          :action="upload.url + '?updateSupport=' + upload.updateSupport"
+          :disabled="upload.isUploading"
+          :on-progress="handleFileUploadProgress"
+          :on-success="handleFileSuccess"
+          :on-error="handleFileError"
+          :auto-upload="false"
+          drag
+      >
+        <el-icon class="el-icon--upload"><upload-filled /></el-icon>
+        <div class="el-upload__text">灏嗘枃浠舵嫋鍒版澶勶紝鎴�<em>鐐瑰嚮涓婁紶</em></div>
+        <template #tip>
+          <div class="el-upload__tip text-center">
+            <span>浠呭厑璁稿鍏ls銆亁lsx鏍煎紡鏂囦欢銆�</span>
+            <el-link
+                type="primary"
+                :underline="false"
+                style="font-size: 12px; vertical-align: baseline"
+                @click="importTemplate"
+            >涓嬭浇妯℃澘</el-link
+            >
+          </div>
+        </template>
+      </el-upload>
+      <template #footer>
+        <div class="dialog-footer">
+          <el-button type="primary" @click="submitFileForm">纭� 瀹�</el-button>
+          <el-button @click="upload.open = false">鍙� 娑�</el-button>
+        </div>
+      </template>
+    </el-dialog>
+    <files-dia ref="filesDia"></files-dia>
+  </div>
+</template>
+
+<script setup>
+import { onMounted, ref } from "vue";
+import { Search } from "@element-plus/icons-vue";
+import { delSupplier } from "@/api/basicData/supplierManageFile.js";
+import { ElMessageBox } from "element-plus";
+import { userListNoPage } from "@/api/system/user.js";
+import {
+  addSupplier,
+  getSupplier,
+  listSupplier,
+  updateSupplier,
+} from "@/api/basicData/supplierManageFile.js";
+import useUserStore from "@/store/modules/user";
+import { getToken } from "@/utils/auth.js";
+import FilesDia from "../filesDia.vue";
+const { proxy } = getCurrentInstance();
+const userStore = useUserStore();
+
+const tableColumn = ref([
+  {
+    label: "渚涘簲鍟嗗悕绉�",
+    prop: "supplierName",
+    width: 250,
+  },
+  {
+    label: "绾崇◣浜鸿瘑鍒彿",
+    prop: "taxpayerIdentificationNum",
+    width: 230,
+  },
+  {
+    label: "鍏徃鍦板潃",
+    prop: "companyAddress",
+    width: 220,
+  },
+  {
+    label: "鑱旂郴鏂瑰紡",
+    prop: "companyPhone",
+    width:150
+  },
+  {
+    label: "寮�鎴疯",
+    prop: "bankAccountName",
+    width: 220,
+  },
+  {
+    label: "璐﹀彿",
+    prop: "bankAccountNum",
+    width: 220,
+  },
+  {
+    label: "鑱旂郴浜�",
+    prop: "contactUserName",
+  },
+  {
+    label: "鑱旂郴鐢佃瘽",
+    prop: "contactUserPhone",
+    width: 150,
+  },
+  {
+    label: "缁存姢浜�",
+    prop: "maintainUserName",
+  },
+
+  {
+    label: "缁存姢鏃堕棿",
+    prop: "maintainTime",
+    width:100
+  },
+  {
+    dataType: "action",
+    label: "鎿嶄綔",
+    align: "center",
+    fixed: 'right',
+    width: 150,
+    operation: [
+      {
+        name: "缂栬緫",
+        type: "text",
+        clickFun: (row) => {
+          openForm("edit", row);
+        },
+      },
+      {
+        //璧勮川闄勪欢
+        name: "璧勮川鏂囦欢",
+        type: "text",
+        clickFun: (row) => {
+          openFilesFormDia(row)
+        }
+      }
+    ],
+  },
+]);
+const tableData = ref([]);
+const selectedRows = ref([]);
+const userList = ref([]);
+const tableLoading = ref(false);
+const page = reactive({
+  current: 1,
+  size: 100,
+  total: 0,
+});
+const filesDia = ref()
+// 鐢ㄦ埛淇℃伅琛ㄥ崟寮规鏁版嵁
+const operationType = ref("");
+const dialogFormVisible = ref(false);
+const data = reactive({
+  searchForm: {
+    supplierName: "",
+  },
+  form: {
+    supplierName: "",
+    taxpayerIdentificationNum: "",
+    companyAddress: "",
+    companyPhone: "",
+    bankAccountName: "",
+    bankAccountNum: "",
+    contactUserName: "",
+    contactUserPhone: "",
+    maintainUserId: "",
+    maintainTime: "",
+    isWhite: "",
+  },
+  rules: {
+    supplierName: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    taxpayerIdentificationNum: [
+      { required: true, message: "璇疯緭鍏�", trigger: "blur" },
+    ],
+    companyAddress: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    companyPhone: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    bankAccountName: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    bankAccountNum: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    contactUserName: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
+    contactUserPhone: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
+    maintainUserId: [{ required: false, message: "璇烽�夋嫨", trigger: "change" }],
+    maintainTime: [{ required: false, message: "璇烽�夋嫨", trigger: "change" }],
+  },
+});
+const { searchForm, form, rules } = toRefs(data);
+
+// 鏌ヨ鍒楄〃
+/** 鎼滅储鎸夐挳鎿嶄綔 */
+const handleQuery = () => {
+  page.current = 1;
+  getList();
+};
+const pagination = (obj) => {
+  page.current = obj.page;
+  page.size = obj.limit;
+  getList();
+};
+/** 鎻愪氦涓婁紶鏂囦欢 */
+function submitFileForm() {
+  upload.isUploading = true;
+  proxy.$refs["uploadRef"].submit();
+}
+const getList = () => {
+  tableLoading.value = true;
+  listSupplier({ ...searchForm.value, ...page, isWhite: 1 }).then((res) => {
+    tableLoading.value = false;
+    tableData.value = res.data.records;
+    page.total = res.data.total;
+  });
+};
+const upload = reactive({
+  // 鏄惁鏄剧ず寮瑰嚭灞傦紙渚涘簲鍟嗗鍏ワ級
+  open: false,
+  // 寮瑰嚭灞傛爣棰橈紙渚涘簲鍟嗗鍏ワ級
+  title: "",
+  // 鏄惁绂佺敤涓婁紶
+  isUploading: false,
+  // 鏄惁鏇存柊宸茬粡瀛樺湪鐨勭敤鎴锋暟鎹�
+  updateSupport: 1,
+  // 璁剧疆涓婁紶鐨勮姹傚ご閮�
+  headers: { Authorization: "Bearer " + getToken() },
+  // 涓婁紶鐨勫湴鍧�
+  url: import.meta.env.VITE_APP_BASE_API + "/system/supplier/import",
+});
+/** 瀵煎叆鎸夐挳鎿嶄綔 */
+function handleImport() {
+  upload.title = "渚涘簲鍟嗗鍏�";
+  upload.open = true;
+}
+/** 涓嬭浇妯℃澘 */
+function importTemplate() {
+  proxy.download("/system/supplier/downloadTemplate", {}, "渚涘簲鍟嗗鍏ユā鏉�.xlsx");
+}
+
+/**鏂囦欢涓婁紶涓鐞� */
+const handleFileUploadProgress = (event, file, fileList) => {
+  upload.isUploading = true;
+};
+
+/** 鏂囦欢涓婁紶鎴愬姛澶勭悊 */
+const handleFileSuccess = (response, file, fileList) => {
+  upload.isUploading = false;
+  if(response.code === 200){
+    proxy.$modal.msgSuccess("鏂囦欢涓婁紶鎴愬姛");
+    upload.open = false;
+    proxy.$refs["uploadRef"].clearFiles();
+    getList();
+  }else if(response.code === 500){
+    proxy.$modal.msgError(response.msg);
+  }else{
+    proxy.$modal.msgWarning(response.msg);
+  }
+};
+
+/** 鏂囦欢涓婁紶澶辫触澶勭悊 */
+const handleFileError = (error, file, fileList) => {
+  upload.isUploading = false;
+  proxy.$modal.msgError("鏂囦欢涓婁紶澶辫触");
+};
+// 琛ㄦ牸閫夋嫨鏁版嵁
+const handleSelectionChange = (selection) => {
+  selectedRows.value = selection;
+};
+// 鎵撳紑寮规
+const openForm = (type, row) => {
+  operationType.value = type;
+  form.value = {};
+  form.value.maintainUserId = userStore.id;
+  form.value.maintainTime = getCurrentDate();
+  userListNoPage().then((res) => {
+    userList.value = res.data;
+  });
+  if (type === "edit") {
+    getSupplier(row.id).then((res) => {
+      form.value = { ...res.data };
+    });
+  }
+  dialogFormVisible.value = true;
+};
+// 鎻愪氦琛ㄥ崟
+const submitForm = () => {
+  proxy.$refs["formRef"].validate((valid) => {
+    if (valid) {
+      if (operationType.value === "edit") {
+        submitEdit();
+      } else {
+        submitAdd();
+      }
+    }
+  });
+};
+// 鎻愪氦鏂板
+const submitAdd = () => {
+  addSupplier(form.value).then((res) => {
+    proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
+    closeDia();
+    getList();
+  });
+};
+// 鎻愪氦淇敼
+const submitEdit = () => {
+  updateSupplier(form.value).then((res) => {
+    proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
+    closeDia();
+    getList();
+  });
+};
+// 鍏抽棴寮规
+const closeDia = () => {
+  proxy.resetForm("formRef");
+  dialogFormVisible.value = false;
+};
+// 瀵煎嚭
+const handleOut = () => {
+  ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚鍑猴紝鏄惁纭瀵煎嚭锛�", "瀵煎嚭", {
+    confirmButtonText: "纭",
+    cancelButtonText: "鍙栨秷",
+    type: "warning",
+  })
+      .then(() => {
+        proxy.download("/system/supplier/export", {}, "渚涘簲鍟嗘。妗�.xlsx");
+      })
+      .catch(() => {
+        proxy.$modal.msg("宸插彇娑�");
+      });
+};
+// 鍒犻櫎
+const handleDelete = () => {
+  let ids = [];
+  if (selectedRows.value.length > 0) {
+    // 妫�鏌ユ槸鍚︽湁浠栦汉缁存姢鐨勬暟鎹�
+    const unauthorizedData = selectedRows.value.filter(item => item.maintainUserName !== userStore.nickName);
+    if (unauthorizedData.length > 0) {
+      proxy.$modal.msgWarning("涓嶅彲鍒犻櫎浠栦汉缁存姢鐨勬暟鎹�");
+      return;
+    }
+    ids = selectedRows.value.map((item) => item.id);
+  } else {
+    proxy.$modal.msgWarning("璇烽�夋嫨鏁版嵁");
+    return;
+  }
+  ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚垹闄わ紝鏄惁纭鍒犻櫎锛�", "鍒犻櫎鎻愮ず", {
+    confirmButtonText: "纭",
+    cancelButtonText: "鍙栨秷",
+    type: "warning",
+  })
+      .then(() => {
+        tableLoading.value = true;
+        delSupplier(ids)
+            .then((res) => {
+              proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+              getList();
+            })
+            .finally(() => {
+              tableLoading.value = false;
+            });
+      })
+      .catch(() => {
+        proxy.$modal.msg("宸插彇娑�");
+      });
+};
+
+// 鑾峰彇褰撳墠鏃ユ湡骞舵牸寮忓寲涓� YYYY-MM-DD
+function getCurrentDate() {
+  const today = new Date();
+  const year = today.getFullYear();
+  const month = String(today.getMonth() + 1).padStart(2, "0"); // 鏈堜唤浠�0寮�濮�
+  const day = String(today.getDate()).padStart(2, "0");
+  return `${year}-${month}-${day}`;
+}
+// 鎵撳紑闄勪欢寮规
+const openFilesFormDia = (row) => {
+  nextTick(() => {
+    filesDia.value?.openDialog(row)
+  })
+};
+
+onMounted(() => {
+  getList();
+});
+</script>
+
+
diff --git a/src/views/basicData/supplierManage/components/HomeTab.vue b/src/views/basicData/supplierManage/components/HomeTab.vue
new file mode 100644
index 0000000..67e3646
--- /dev/null
+++ b/src/views/basicData/supplierManage/components/HomeTab.vue
@@ -0,0 +1,569 @@
+<template>
+  <div class="app-container">
+    <div class="search_form">
+      <div>
+        <span class="search_title">渚涘簲鍟嗘。妗堬細</span>
+        <el-input
+            v-model="searchForm.supplierName"
+            style="width: 240px"
+            placeholder="杈撳叆渚涘簲鍟嗗悕绉版悳绱�"
+            @change="handleQuery"
+            clearable
+            :prefix-icon="Search"
+        />
+        <el-button type="primary" @click="handleQuery" style="margin-left: 10px"
+        >鎼滅储</el-button
+        >
+      </div>
+      <div>
+        <el-button type="primary" @click="openForm('add')"
+        >鏂板渚涘簲鍟�</el-button
+        >
+        <el-button @click="handleOut">瀵煎嚭</el-button>
+        <el-button type="info" plain icon="Upload" @click="handleImport"
+        >瀵煎叆</el-button
+        >
+        <el-button type="danger" plain @click="handleDelete">鍒犻櫎</el-button>
+      </div>
+    </div>
+    <div class="table_list">
+      <PIMTable
+          rowKey="id"
+          :column="tableColumn"
+          :tableData="tableData"
+          :page="page"
+          :isSelection="true"
+          @selection-change="handleSelectionChange"
+          :tableLoading="tableLoading"
+          @pagination="pagination"
+      ></PIMTable>
+    </div>
+    <el-dialog
+        v-model="dialogFormVisible"
+        :title="operationType === 'add' ? '鏂板渚涘簲鍟嗕俊鎭�' : '缂栬緫渚涘簲鍟嗕俊鎭�'"
+        width="70%"
+        @close="closeDia"
+    >
+      <el-form
+          :model="form"
+          label-width="140px"
+          label-position="top"
+          :rules="rules"
+          ref="formRef"
+      >
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="渚涘簲鍟嗗悕绉帮細" prop="supplierName">
+              <el-input
+                  v-model="form.supplierName"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item
+                label="绾崇◣浜鸿瘑鍒彿锛�"
+                prop="taxpayerIdentificationNum"
+            >
+              <el-input
+                  v-model="form.taxpayerIdentificationNum"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="鍏徃鍦板潃锛�" prop="companyAddress">
+              <el-input
+                  v-model="form.companyAddress"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="鍏徃鐢佃瘽锛�" prop="companyPhone">
+              <el-input
+                  v-model="form.companyPhone"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="寮�鎴疯锛�" prop="bankAccountName">
+              <el-input
+                  v-model="form.bankAccountName"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="璐﹀彿锛�" prop="bankAccountNum">
+              <el-input
+                  v-model="form.bankAccountNum"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="鑱旂郴浜猴細" prop="contactUserName">
+              <el-input
+                  v-model="form.contactUserName"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="鑱旂郴鐢佃瘽锛�" prop="contactUserPhone">
+              <el-input
+                  v-model="form.contactUserPhone"
+                  placeholder="璇疯緭鍏�"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="缁存姢浜猴細" prop="maintainUserId">
+              <el-select
+                  v-model="form.maintainUserId"
+                  placeholder="璇烽�夋嫨"
+                  clearable
+                  disabled
+              >
+                <el-option
+                    v-for="item in userList"
+                    :key="item.nickName"
+                    :label="item.nickName"
+                    :value="item.userId"
+                />
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="缁存姢鏃堕棿锛�" prop="maintainTime">
+              <el-date-picker
+                  style="width: 100%"
+                  v-model="form.maintainTime"
+                  value-format="YYYY-MM-DD"
+                  format="YYYY-MM-DD"
+                  type="date"
+                  placeholder="璇烽�夋嫨"
+                  clearable
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="鏄惁鐧藉悕鍗曪細" prop="isWhite">
+              <el-select v-model="form.isWhite" placeholder="璇烽�夋嫨" clearable>
+                <el-option label="鏄�" :value="0" />
+                <el-option label="鍚�" :value="1" />
+              </el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <template #footer>
+        <div class="dialog-footer">
+          <el-button type="primary" @click="submitForm">纭</el-button>
+          <el-button @click="closeDia">鍙栨秷</el-button>
+        </div>
+      </template>
+    </el-dialog>
+
+    <!-- 渚涘簲鍟嗗鍏ュ璇濇 -->
+    <el-dialog
+        :title="upload.title"
+        v-model="upload.open"
+        width="400px"
+        append-to-body
+    >
+      <el-upload
+          ref="uploadRef"
+          :limit="1"
+          accept=".xlsx, .xls"
+          :headers="upload.headers"
+          :action="upload.url + '?updateSupport=' + upload.updateSupport"
+          :disabled="upload.isUploading"
+          :on-progress="handleFileUploadProgress"
+          :on-success="handleFileSuccess"
+          :on-error="handleFileError"
+          :auto-upload="false"
+          drag
+      >
+        <el-icon class="el-icon--upload"><upload-filled /></el-icon>
+        <div class="el-upload__text">灏嗘枃浠舵嫋鍒版澶勶紝鎴�<em>鐐瑰嚮涓婁紶</em></div>
+        <template #tip>
+          <div class="el-upload__tip text-center">
+            <span>浠呭厑璁稿鍏ls銆亁lsx鏍煎紡鏂囦欢銆�</span>
+            <el-link
+                type="primary"
+                :underline="false"
+                style="font-size: 12px; vertical-align: baseline"
+                @click="importTemplate"
+            >涓嬭浇妯℃澘</el-link
+            >
+          </div>
+        </template>
+      </el-upload>
+      <template #footer>
+        <div class="dialog-footer">
+          <el-button type="primary" @click="submitFileForm">纭� 瀹�</el-button>
+          <el-button @click="upload.open = false">鍙� 娑�</el-button>
+        </div>
+      </template>
+    </el-dialog>
+    <files-dia ref="filesDia"></files-dia>
+  </div>
+</template>
+
+<script setup>
+import { onMounted, ref } from "vue";
+import { Search } from "@element-plus/icons-vue";
+import { delSupplier } from "@/api/basicData/supplierManageFile.js";
+import { ElMessageBox } from "element-plus";
+import { userListNoPage } from "@/api/system/user.js";
+import {
+  addSupplier,
+  getSupplier,
+  listSupplier,
+  updateSupplier,
+} from "@/api/basicData/supplierManageFile.js";
+import useUserStore from "@/store/modules/user";
+import { getToken } from "@/utils/auth.js";
+import FilesDia from "../filesDia.vue";
+const { proxy } = getCurrentInstance();
+const userStore = useUserStore();
+
+const tableColumn = ref([
+  {
+    label: "渚涘簲鍟嗗悕绉�",
+    prop: "supplierName",
+    width: 250,
+  },
+  {
+    label: "绾崇◣浜鸿瘑鍒彿",
+    prop: "taxpayerIdentificationNum",
+    width: 230,
+  },
+  {
+    label: "鍏徃鍦板潃",
+    prop: "companyAddress",
+    width: 220,
+  },
+  {
+    label: "鑱旂郴鏂瑰紡",
+    prop: "companyPhone",
+    width:150
+  },
+  {
+    label: "寮�鎴疯",
+    prop: "bankAccountName",
+    width: 220,
+  },
+  {
+    label: "璐﹀彿",
+    prop: "bankAccountNum",
+    width: 220,
+  },
+  {
+    label: "鑱旂郴浜�",
+    prop: "contactUserName",
+  },
+  {
+    label: "鑱旂郴鐢佃瘽",
+    prop: "contactUserPhone",
+    width: 150,
+  },
+  {
+    label: "缁存姢浜�",
+    prop: "maintainUserName",
+  },
+
+  {
+    label: "缁存姢鏃堕棿",
+    prop: "maintainTime",
+    width:100
+  },
+  {
+    dataType: "action",
+    label: "鎿嶄綔",
+    align: "center",
+    fixed: 'right',
+    width: 150,
+    operation: [
+      {
+        name: "缂栬緫",
+        type: "text",
+        clickFun: (row) => {
+          openForm("edit", row);
+        },
+      },
+      {
+        //璧勮川闄勪欢
+        name: "璧勮川鏂囦欢",
+        type: "text",
+        clickFun: (row) => {
+          openFilesFormDia(row)
+        }
+      }
+    ],
+  },
+]);
+const tableData = ref([]);
+const selectedRows = ref([]);
+const userList = ref([]);
+const tableLoading = ref(false);
+const page = reactive({
+  current: 1,
+  size: 100,
+  total: 0,
+});
+const filesDia = ref()
+// 鐢ㄦ埛淇℃伅琛ㄥ崟寮规鏁版嵁
+const operationType = ref("");
+const dialogFormVisible = ref(false);
+const data = reactive({
+  searchForm: {
+    supplierName: "",
+  },
+  form: {
+    supplierName: "",
+    taxpayerIdentificationNum: "",
+    companyAddress: "",
+    companyPhone: "",
+    bankAccountName: "",
+    bankAccountNum: "",
+    contactUserName: "",
+    contactUserPhone: "",
+    maintainUserId: "",
+    maintainTime: "",
+    isWhite: "",
+  },
+  rules: {
+    supplierName: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    taxpayerIdentificationNum: [
+      { required: true, message: "璇疯緭鍏�", trigger: "blur" },
+    ],
+    companyAddress: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    companyPhone: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    bankAccountName: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    bankAccountNum: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    contactUserName: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
+    contactUserPhone: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
+    maintainUserId: [{ required: false, message: "璇烽�夋嫨", trigger: "change" }],
+    maintainTime: [{ required: false, message: "璇烽�夋嫨", trigger: "change" }],
+  },
+});
+const { searchForm, form, rules } = toRefs(data);
+
+// 鏌ヨ鍒楄〃
+/** 鎼滅储鎸夐挳鎿嶄綔 */
+const handleQuery = () => {
+  page.current = 1;
+  getList();
+};
+const pagination = (obj) => {
+  page.current = obj.page;
+  page.size = obj.limit;
+  getList();
+};
+/** 鎻愪氦涓婁紶鏂囦欢 */
+function submitFileForm() {
+  upload.isUploading = true;
+  proxy.$refs["uploadRef"].submit();
+}
+const getList = () => {
+  tableLoading.value = true;
+  listSupplier({ ...searchForm.value, ...page, isWhite: 0 }).then((res) => {
+    tableLoading.value = false;
+    tableData.value = res.data.records;
+    page.total = res.data.total;
+  });
+};
+const upload = reactive({
+  // 鏄惁鏄剧ず寮瑰嚭灞傦紙渚涘簲鍟嗗鍏ワ級
+  open: false,
+  // 寮瑰嚭灞傛爣棰橈紙渚涘簲鍟嗗鍏ワ級
+  title: "",
+  // 鏄惁绂佺敤涓婁紶
+  isUploading: false,
+  // 鏄惁鏇存柊宸茬粡瀛樺湪鐨勭敤鎴锋暟鎹�
+  updateSupport: 1,
+  // 璁剧疆涓婁紶鐨勮姹傚ご閮�
+  headers: { Authorization: "Bearer " + getToken() },
+  // 涓婁紶鐨勫湴鍧�
+  url: import.meta.env.VITE_APP_BASE_API + "/system/supplier/import",
+});
+/** 瀵煎叆鎸夐挳鎿嶄綔 */
+function handleImport() {
+  upload.title = "渚涘簲鍟嗗鍏�";
+  upload.open = true;
+}
+/** 涓嬭浇妯℃澘 */
+function importTemplate() {
+  proxy.download("/system/supplier/downloadTemplate", {}, "渚涘簲鍟嗗鍏ユā鏉�.xlsx");
+}
+
+/**鏂囦欢涓婁紶涓鐞� */
+const handleFileUploadProgress = (event, file, fileList) => {
+  upload.isUploading = true;
+};
+
+/** 鏂囦欢涓婁紶鎴愬姛澶勭悊 */
+const handleFileSuccess = (response, file, fileList) => {
+  upload.isUploading = false;
+  if(response.code === 200){
+    proxy.$modal.msgSuccess("鏂囦欢涓婁紶鎴愬姛");
+    upload.open = false;
+    proxy.$refs["uploadRef"].clearFiles();
+    getList();
+  }else if(response.code === 500){
+    proxy.$modal.msgError(response.msg);
+  }else{
+    proxy.$modal.msgWarning(response.msg);
+  }
+};
+
+/** 鏂囦欢涓婁紶澶辫触澶勭悊 */
+const handleFileError = (error, file, fileList) => {
+  upload.isUploading = false;
+  proxy.$modal.msgError("鏂囦欢涓婁紶澶辫触");
+};
+// 琛ㄦ牸閫夋嫨鏁版嵁
+const handleSelectionChange = (selection) => {
+  selectedRows.value = selection;
+};
+// 鎵撳紑寮规
+const openForm = (type, row) => {
+  operationType.value = type;
+  form.value = {};
+  form.value.maintainUserId = userStore.id;
+  form.value.maintainTime = getCurrentDate();
+  userListNoPage().then((res) => {
+    userList.value = res.data;
+  });
+  if (type === "edit") {
+    getSupplier(row.id).then((res) => {
+      form.value = { ...res.data };
+    });
+  }
+  dialogFormVisible.value = true;
+};
+// 鎻愪氦琛ㄥ崟
+const submitForm = () => {
+  proxy.$refs["formRef"].validate((valid) => {
+    if (valid) {
+      if (operationType.value === "edit") {
+        submitEdit();
+      } else {
+        submitAdd();
+      }
+    }
+  });
+};
+// 鎻愪氦鏂板
+const submitAdd = () => {
+  addSupplier(form.value).then((res) => {
+    proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
+    closeDia();
+    getList();
+  });
+};
+// 鎻愪氦淇敼
+const submitEdit = () => {
+  updateSupplier(form.value).then((res) => {
+    proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
+    closeDia();
+    getList();
+  });
+};
+// 鍏抽棴寮规
+const closeDia = () => {
+  proxy.resetForm("formRef");
+  dialogFormVisible.value = false;
+};
+// 瀵煎嚭
+const handleOut = () => {
+  ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚鍑猴紝鏄惁纭瀵煎嚭锛�", "瀵煎嚭", {
+    confirmButtonText: "纭",
+    cancelButtonText: "鍙栨秷",
+    type: "warning",
+  })
+      .then(() => {
+        proxy.download("/system/supplier/export", {}, "渚涘簲鍟嗘。妗�.xlsx");
+      })
+      .catch(() => {
+        proxy.$modal.msg("宸插彇娑�");
+      });
+};
+// 鍒犻櫎
+const handleDelete = () => {
+  let ids = [];
+  if (selectedRows.value.length > 0) {
+    // 妫�鏌ユ槸鍚︽湁浠栦汉缁存姢鐨勬暟鎹�
+    const unauthorizedData = selectedRows.value.filter(item => item.maintainUserName !== userStore.nickName);
+    if (unauthorizedData.length > 0) {
+      proxy.$modal.msgWarning("涓嶅彲鍒犻櫎浠栦汉缁存姢鐨勬暟鎹�");
+      return;
+    }
+    ids = selectedRows.value.map((item) => item.id);
+  } else {
+    proxy.$modal.msgWarning("璇烽�夋嫨鏁版嵁");
+    return;
+  }
+  ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚垹闄わ紝鏄惁纭鍒犻櫎锛�", "鍒犻櫎鎻愮ず", {
+    confirmButtonText: "纭",
+    cancelButtonText: "鍙栨秷",
+    type: "warning",
+  })
+      .then(() => {
+        tableLoading.value = true;
+        delSupplier(ids)
+            .then((res) => {
+              proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+              getList();
+            })
+            .finally(() => {
+              tableLoading.value = false;
+            });
+      })
+      .catch(() => {
+        proxy.$modal.msg("宸插彇娑�");
+      });
+};
+
+// 鑾峰彇褰撳墠鏃ユ湡骞舵牸寮忓寲涓� YYYY-MM-DD
+function getCurrentDate() {
+  const today = new Date();
+  const year = today.getFullYear();
+  const month = String(today.getMonth() + 1).padStart(2, "0"); // 鏈堜唤浠�0寮�濮�
+  const day = String(today.getDate()).padStart(2, "0");
+  return `${year}-${month}-${day}`;
+}
+// 鎵撳紑闄勪欢寮规
+const openFilesFormDia = (row) => {
+  nextTick(() => {
+    filesDia.value?.openDialog(row)
+  })
+};
+
+onMounted(() => {
+  getList();
+});
+</script>
+
diff --git a/src/views/basicData/supplierManage/filesDia.vue b/src/views/basicData/supplierManage/filesDia.vue
new file mode 100644
index 0000000..6284d6b
--- /dev/null
+++ b/src/views/basicData/supplierManage/filesDia.vue
@@ -0,0 +1,199 @@
+<template>
+  <div>
+    <el-dialog
+        v-model="dialogFormVisible"
+        title="涓婁紶闄勪欢"
+        width="50%"
+        @close="closeDia"
+    >
+      <div style="margin-bottom: 10px;text-align: right">
+        <el-upload
+            v-model:file-list="fileList"
+            class="upload-demo"
+            :action="uploadUrl"
+            :on-success="handleUploadSuccess"
+            :on-error="handleUploadError"
+            name="file"
+            :show-file-list="false"
+            :headers="headers"
+            style="display: inline;margin-right: 10px"
+        >
+          <el-button type="primary">涓婁紶闄勪欢</el-button>
+        </el-upload>
+        <el-button type="danger" plain @click="handleDelete">鍒犻櫎</el-button>
+      </div>
+      <PIMTable
+          rowKey="id"
+          :column="tableColumn"
+          :tableData="tableData"
+          :tableLoading="tableLoading"
+          :isSelection="true"
+          @selection-change="handleSelectionChange"
+          height="500"
+      >
+      </PIMTable>
+			<pagination
+				style="margin: 10px 0"
+				v-show="total > 0"
+				@pagination="paginationSearch"
+				:total="total"
+				:page="page.current"
+				:limit="page.size"
+			/>
+      <template #footer>
+        <div class="dialog-footer">
+          <el-button @click="closeDia">鍙栨秷</el-button>
+        </div>
+      </template>
+    </el-dialog>
+    <filePreview ref="filePreviewRef" />
+  </div>
+</template>
+
+<script setup>
+import {ref} from "vue";
+import {ElMessageBox} from "element-plus";
+import {getToken} from "@/utils/auth.js";
+import filePreview from '@/components/filePreview/index.vue'
+import {
+  fileAdd,
+  fileDel,
+  fileListPage
+} from "@/api/basicData/supplierManageFile.js";
+import Pagination from "@/components/PIMTable/Pagination.vue";
+const { proxy } = getCurrentInstance()
+const emit = defineEmits(['close'])
+
+const dialogFormVisible = ref(false);
+const currentId = ref('')
+const selectedRows = ref([]);
+const filePreviewRef = ref()
+const tableColumn = ref([
+  {
+    label: "鏂囦欢鍚嶇О",
+    prop: "name",
+  },
+  {
+    dataType: "action",
+    label: "鎿嶄綔",
+    align: "center",
+    operation: [
+      {
+        name: "涓嬭浇",
+        type: "text",
+        clickFun: (row) => {
+          downLoadFile(row);
+        },
+      },
+      {
+        name: "棰勮",
+        type: "text",
+        clickFun: (row) => {
+          lookFile(row);
+        },
+      }
+    ],
+  },
+]);
+const page = reactive({
+	current: 1,
+	size: 100,
+});
+const total = ref(0);
+const tableData = ref([]);
+const fileList = ref([]);
+const tableLoading = ref(false);
+const headers = ref({
+  Authorization: "Bearer " + getToken(),
+});
+const uploadUrl = ref(import.meta.env.VITE_APP_BASE_API + "/file/upload"); // 涓婁紶鐨勫浘鐗囨湇鍔″櫒鍦板潃
+
+// 鎵撳紑寮规
+const openDialog = (row) => {
+  dialogFormVisible.value = true;
+  currentId.value = row.id;
+  getList()
+}
+const paginationSearch = (obj) => {
+	page.current = obj.page;
+	page.size = obj.limit;
+	getList();
+};
+const getList = () => {
+  fileListPage({supplierId: currentId.value, ...page}).then(res => {
+    tableData.value = res.data.records;
+		total.value = res.data.total;
+  })
+}
+// 琛ㄦ牸閫夋嫨鏁版嵁
+const handleSelectionChange = (selection) => {
+  selectedRows.value = selection;
+};
+
+// 鍏抽棴寮规
+const closeDia = () => {
+  dialogFormVisible.value = false;
+  emit('close')
+};
+// 涓婁紶鎴愬姛澶勭悊
+function handleUploadSuccess(res, file) {
+  // 濡傛灉涓婁紶鎴愬姛
+  if (res.code == 200) {
+    const fileRow = {}
+    fileRow.name = res.data.originalName
+    fileRow.url = res.data.tempPath
+    uploadFile(fileRow)
+  } else {
+    proxy.$modal.msgError("鏂囦欢涓婁紶澶辫触");
+  }
+}
+function uploadFile(file) {
+  file.supplierId = currentId.value;
+  fileAdd(file).then(res => {
+    proxy.$modal.msgSuccess("鏂囦欢涓婁紶鎴愬姛");
+    getList()
+  })
+}
+// 涓婁紶澶辫触澶勭悊
+function handleUploadError() {
+  proxy.$modal.msgError("鏂囦欢涓婁紶澶辫触");
+}
+// 涓嬭浇闄勪欢
+const downLoadFile = (row) => {
+  proxy.$download.name(row.url);
+}
+// 鍒犻櫎
+const handleDelete = () => {
+  let ids = [];
+  if (selectedRows.value.length > 0) {
+    ids = selectedRows.value.map((item) => item.id);
+  } else {
+    proxy.$modal.msgWarning("璇烽�夋嫨鏁版嵁");
+    return;
+  }
+  ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚垹闄わ紝鏄惁纭鍒犻櫎锛�", "瀵煎嚭", {
+    confirmButtonText: "纭",
+    cancelButtonText: "鍙栨秷",
+    type: "warning",
+  }).then(() => {
+    fileDel(ids).then((res) => {
+      proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+      getList();
+    });
+  }).catch(() => {
+    proxy.$modal.msg("宸插彇娑�");
+  });
+};
+// 棰勮闄勪欢
+const lookFile = (row) => {
+  filePreviewRef.value.open(row.url)
+}
+
+defineExpose({
+  openDialog,
+});
+</script>
+
+<style scoped>
+
+</style>
\ No newline at end of file
diff --git a/src/views/basicData/supplierManage/index.vue b/src/views/basicData/supplierManage/index.vue
index 5d55907..963a3db 100644
--- a/src/views/basicData/supplierManage/index.vue
+++ b/src/views/basicData/supplierManage/index.vue
@@ -1,542 +1,38 @@
+<!-- 鍦ㄤ綘鐨勪富椤甸潰涓� -->
 <template>
   <div class="app-container">
-    <div class="search_form">
-      <div>
-        <span class="search_title">渚涘簲鍟嗘。妗堬細</span>
-        <el-input
-          v-model="searchForm.supplierName"
-          style="width: 240px"
-          placeholder="杈撳叆渚涘簲鍟嗗悕绉版悳绱�"
-          @change="handleQuery"
-          clearable
-          :prefix-icon="Search"
-        />
-        <el-button type="primary" @click="handleQuery" style="margin-left: 10px"
-          >鎼滅储</el-button
-        >
-      </div>
-      <div>
-        <el-button type="primary" @click="openForm('add')"
-          >鏂板渚涘簲鍟�</el-button
-        >
-        <el-button @click="handleOut">瀵煎嚭</el-button>
-        <el-button type="info" plain icon="Upload" @click="handleImport"
-          >瀵煎叆</el-button
-        >
-        <el-button type="danger" plain @click="handleDelete">鍒犻櫎</el-button>
-      </div>
-    </div>
-    <div class="table_list">
-      <PIMTable
-        rowKey="id"
-        :column="tableColumn"
-        :tableData="tableData"
-        :page="page"
-        :isSelection="true"
-        @selection-change="handleSelectionChange"
-        :tableLoading="tableLoading"
-				@pagination="pagination"
-      ></PIMTable>
-    </div>
-    <el-dialog
-      v-model="dialogFormVisible"
-      :title="operationType === 'add' ? '鏂板渚涘簲鍟嗕俊鎭�' : '缂栬緫渚涘簲鍟嗕俊鎭�'"
-      width="70%"
-      @close="closeDia"
-    >
-      <el-form
-        :model="form"
-        label-width="140px"
-        label-position="top"
-        :rules="rules"
-        ref="formRef"
-      >
-        <el-row :gutter="30">
-          <el-col :span="12">
-            <el-form-item label="渚涘簲鍟嗗悕绉帮細" prop="supplierName">
-              <el-input
-                v-model="form.supplierName"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-          <el-col :span="12">
-            <el-form-item
-              label="绾崇◣浜鸿瘑鍒彿锛�"
-              prop="taxpayerIdentificationNum"
-            >
-              <el-input
-                v-model="form.taxpayerIdentificationNum"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-        </el-row>
-        <el-row :gutter="30">
-          <el-col :span="12">
-            <el-form-item label="鍏徃鍦板潃锛�" prop="companyAddress">
-              <el-input
-                v-model="form.companyAddress"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-          <el-col :span="12">
-            <el-form-item label="鍏徃鐢佃瘽锛�" prop="companyPhone">
-              <el-input
-                v-model="form.companyPhone"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-        </el-row>
-        <el-row :gutter="30">
-          <el-col :span="12">
-            <el-form-item label="寮�鎴疯锛�" prop="bankAccountName">
-              <el-input
-                v-model="form.bankAccountName"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-          <el-col :span="12">
-            <el-form-item label="璐﹀彿锛�" prop="bankAccountNum">
-              <el-input
-                v-model="form.bankAccountNum"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-        </el-row>
-        <el-row :gutter="30">
-          <el-col :span="12">
-            <el-form-item label="鑱旂郴浜猴細" prop="contactUserName">
-              <el-input
-                v-model="form.contactUserName"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-          <el-col :span="12">
-            <el-form-item label="鑱旂郴鐢佃瘽锛�" prop="contactUserPhone">
-              <el-input
-                v-model="form.contactUserPhone"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-        </el-row>
-        <el-row :gutter="30">
-          <el-col :span="12">
-            <el-form-item label="缁存姢浜猴細" prop="maintainUserId">
-              <el-select
-                v-model="form.maintainUserId"
-                placeholder="璇烽�夋嫨"
-                clearable
-                disabled
-              >
-                <el-option
-                  v-for="item in userList"
-                  :key="item.nickName"
-                  :label="item.nickName"
-                  :value="item.userId"
-                />
-              </el-select>
-            </el-form-item>
-          </el-col>
-          <el-col :span="12">
-            <el-form-item label="缁存姢鏃堕棿锛�" prop="maintainTime">
-              <el-date-picker
-                style="width: 100%"
-                v-model="form.maintainTime"
-                value-format="YYYY-MM-DD"
-                format="YYYY-MM-DD"
-                type="date"
-                placeholder="璇烽�夋嫨"
-                clearable
-              />
-            </el-form-item>
-          </el-col>
-        </el-row>
-      </el-form>
-      <template #footer>
-        <div class="dialog-footer">
-          <el-button type="primary" @click="submitForm">纭</el-button>
-          <el-button @click="closeDia">鍙栨秷</el-button>
-        </div>
-      </template>
-    </el-dialog>
-
-    <!-- 渚涘簲鍟嗗鍏ュ璇濇 -->
-    <el-dialog
-      :title="upload.title"
-      v-model="upload.open"
-      width="400px"
-      append-to-body
-    >
-      <el-upload
-        ref="uploadRef"
-        :limit="1"
-        accept=".xlsx, .xls"
-        :headers="upload.headers"
-        :action="upload.url + '?updateSupport=' + upload.updateSupport"
-        :disabled="upload.isUploading"
-        :on-progress="handleFileUploadProgress"
-        :on-success="handleFileSuccess"
-        :on-error="handleFileError"
-        :auto-upload="false"
-        drag
-      >
-        <el-icon class="el-icon--upload"><upload-filled /></el-icon>
-        <div class="el-upload__text">灏嗘枃浠舵嫋鍒版澶勶紝鎴�<em>鐐瑰嚮涓婁紶</em></div>
-        <template #tip>
-          <div class="el-upload__tip text-center">
-            <span>浠呭厑璁稿鍏ls銆亁lsx鏍煎紡鏂囦欢銆�</span>
-            <el-link
-              type="primary"
-              :underline="false"
-              style="font-size: 12px; vertical-align: baseline"
-              @click="importTemplate"
-              >涓嬭浇妯℃澘</el-link
-            >
-          </div>
-        </template>
-      </el-upload>
-      <template #footer>
-        <div class="dialog-footer">
-          <el-button type="primary" @click="submitFileForm">纭� 瀹�</el-button>
-          <el-button @click="upload.open = false">鍙� 娑�</el-button>
-        </div>
-      </template>
-    </el-dialog>
+    <el-tabs v-model="activeTab" type="card">
+      <el-tab-pane label="姝e父渚涘簲鍟�" name="home">
+        <HomeTab />
+      </el-tab-pane>
+      <el-tab-pane label="榛戝悕鍗�" name="blacklist">
+        <BlacklistTab />
+      </el-tab-pane>
+    </el-tabs>
   </div>
 </template>
 
-<script setup>
-import { onMounted, ref } from "vue";
-import { Search } from "@element-plus/icons-vue";
-import { delSupplier } from "@/api/basicData/supplierManageFile.js";
-import { ElMessageBox } from "element-plus";
-import { userListNoPage } from "@/api/system/user.js";
-import {
-  addSupplier,
-  getSupplier,
-  listSupplier,
-  updateSupplier,
-} from "@/api/basicData/supplierManageFile.js";
-import useUserStore from "@/store/modules/user";
-import { getToken } from "@/utils/auth.js";
-const { proxy } = getCurrentInstance();
-const userStore = useUserStore();
+<script>
+import HomeTab from './components/HomeTab.vue'
+import BlacklistTab from './components/BlacklistTab.vue'
 
-const tableColumn = ref([
-  {
-    label: "渚涘簲鍟嗗悕绉�",
-    prop: "supplierName",
-    width: 250,
+export default {
+  name: 'MainPage',
+  components: {
+    HomeTab,
+    BlacklistTab
   },
-  {
-    label: "绾崇◣浜鸿瘑鍒彿",
-    prop: "taxpayerIdentificationNum",
-    width: 230,
-  },
-  {
-    label: "鍏徃鍦板潃",
-    prop: "companyAddress",
-    width: 220,
-  },
-  {
-    label: "鑱旂郴鏂瑰紡",
-    prop: "companyPhone",
-    width:150
-  },
-  {
-    label: "寮�鎴疯",
-    prop: "bankAccountName",
-    width: 220,
-  },
-  {
-    label: "璐﹀彿",
-    prop: "bankAccountNum",
-    width: 220,
-  },
-  {
-    label: "鑱旂郴浜�",
-    prop: "contactUserName",
-  },
-  {
-    label: "鑱旂郴鐢佃瘽",
-    prop: "contactUserPhone",
-    width: 150,
-  },
-  {
-    label: "缁存姢浜�",
-    prop: "maintainUserName",
-  },
-
-  {
-    label: "缁存姢鏃堕棿",
-    prop: "maintainTime",
-    width:100
-  },
-  {
-    dataType: "action",
-    label: "鎿嶄綔",
-    align: "center",
-		fixed: 'right',
-    operation: [
-      {
-        name: "缂栬緫",
-        type: "text",
-        clickFun: (row) => {
-          openForm("edit", row);
-        },
-      },
-    ],
-  },
-]);
-const tableData = ref([]);
-const selectedRows = ref([]);
-const userList = ref([]);
-const tableLoading = ref(false);
-const page = reactive({
-  current: 1,
-  size: 100,
-  total: 0,
-});
-
-// 鐢ㄦ埛淇℃伅琛ㄥ崟寮规鏁版嵁
-const operationType = ref("");
-const dialogFormVisible = ref(false);
-const data = reactive({
-  searchForm: {
-    supplierName: "",
-  },
-  form: {
-    supplierName: "",
-    taxpayerIdentificationNum: "",
-    companyAddress: "",
-    companyPhone: "",
-    bankAccountName: "",
-    bankAccountNum: "",
-    contactUserName: "",
-    contactUserPhone: "",
-    maintainUserId: "",
-    maintainTime: "",
-  },
-  rules: {
-    supplierName: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
-    taxpayerIdentificationNum: [
-      { required: true, message: "璇疯緭鍏�", trigger: "blur" },
-    ],
-    companyAddress: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
-    companyPhone: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
-    bankAccountName: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
-    bankAccountNum: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
-    contactUserName: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
-    contactUserPhone: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
-    maintainUserId: [{ required: false, message: "璇烽�夋嫨", trigger: "change" }],
-    maintainTime: [{ required: false, message: "璇烽�夋嫨", trigger: "change" }],
-  },
-});
-const { searchForm, form, rules } = toRefs(data);
-
-// 鏌ヨ鍒楄〃
-/** 鎼滅储鎸夐挳鎿嶄綔 */
-const handleQuery = () => {
-  page.current = 1;
-  getList();
-};
-const pagination = (obj) => {
-  page.current = obj.page;
-  page.size = obj.limit;
-  getList();
-};
-/** 鎻愪氦涓婁紶鏂囦欢 */
-function submitFileForm() {
-  upload.isUploading = true;
-  proxy.$refs["uploadRef"].submit();
-}
-const getList = () => {
-  tableLoading.value = true;
-  listSupplier({ ...searchForm.value, ...page }).then((res) => {
-    tableLoading.value = false;
-    tableData.value = res.data.records;
-    page.total = res.data.total;
-  });
-};
-const upload = reactive({
-  // 鏄惁鏄剧ず寮瑰嚭灞傦紙渚涘簲鍟嗗鍏ワ級
-  open: false,
-  // 寮瑰嚭灞傛爣棰橈紙渚涘簲鍟嗗鍏ワ級
-  title: "",
-  // 鏄惁绂佺敤涓婁紶
-  isUploading: false,
-  // 鏄惁鏇存柊宸茬粡瀛樺湪鐨勭敤鎴锋暟鎹�
-  updateSupport: 1,
-  // 璁剧疆涓婁紶鐨勮姹傚ご閮�
-  headers: { Authorization: "Bearer " + getToken() },
-  // 涓婁紶鐨勫湴鍧�
-  url: import.meta.env.VITE_APP_BASE_API + "/system/supplier/import",
-});
-/** 瀵煎叆鎸夐挳鎿嶄綔 */
-function handleImport() {
-  upload.title = "渚涘簲鍟嗗鍏�";
-  upload.open = true;
-}
-/** 涓嬭浇妯℃澘 */
-function importTemplate() {
-  proxy.download("/system/supplier/downloadTemplate", {}, "渚涘簲鍟嗗鍏ユā鏉�.xlsx");
-}
-
-/**鏂囦欢涓婁紶涓鐞� */
-const handleFileUploadProgress = (event, file, fileList) => {
-  upload.isUploading = true;
-};
-
-/** 鏂囦欢涓婁紶鎴愬姛澶勭悊 */
-const handleFileSuccess = (response, file, fileList) => {
-  upload.isUploading = false;
-  if(response.code === 200){
-    proxy.$modal.msgSuccess("鏂囦欢涓婁紶鎴愬姛");
-    upload.open = false;
-    proxy.$refs["uploadRef"].clearFiles();
-    getList();
-  }else if(response.code === 500){
-    proxy.$modal.msgError(response.msg);
-  }else{
-    proxy.$modal.msgWarning(response.msg);
-  }
-};
-
-/** 鏂囦欢涓婁紶澶辫触澶勭悊 */
-const handleFileError = (error, file, fileList) => {
-  upload.isUploading = false;
-  proxy.$modal.msgError("鏂囦欢涓婁紶澶辫触");
-};
-// 琛ㄦ牸閫夋嫨鏁版嵁
-const handleSelectionChange = (selection) => {
-  selectedRows.value = selection;
-};
-// 鎵撳紑寮规
-const openForm = (type, row) => {
-  operationType.value = type;
-  form.value = {};
-  form.value.maintainUserId = userStore.id;
-  form.value.maintainTime = getCurrentDate();
-  userListNoPage().then((res) => {
-    userList.value = res.data;
-  });
-  if (type === "edit") {
-    getSupplier(row.id).then((res) => {
-      form.value = { ...res.data };
-    });
-  }
-  dialogFormVisible.value = true;
-};
-// 鎻愪氦琛ㄥ崟
-const submitForm = () => {
-  proxy.$refs["formRef"].validate((valid) => {
-    if (valid) {
-      if (operationType.value === "edit") {
-        submitEdit();
-      } else {
-        submitAdd();
-      }
+  data() {
+    return {
+      activeTab: 'home'
     }
-  });
-};
-// 鎻愪氦鏂板
-const submitAdd = () => {
-  addSupplier(form.value).then((res) => {
-    proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
-    closeDia();
-    getList();
-  });
-};
-// 鎻愪氦淇敼
-const submitEdit = () => {
-  updateSupplier(form.value).then((res) => {
-    proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
-    closeDia();
-    getList();
-  });
-};
-// 鍏抽棴寮规
-const closeDia = () => {
-  proxy.resetForm("formRef");
-  dialogFormVisible.value = false;
-};
-// 瀵煎嚭
-const handleOut = () => {
-  ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚鍑猴紝鏄惁纭瀵煎嚭锛�", "瀵煎嚭", {
-    confirmButtonText: "纭",
-    cancelButtonText: "鍙栨秷",
-    type: "warning",
-  })
-    .then(() => {
-      proxy.download("/system/supplier/export", {}, "渚涘簲鍟嗘。妗�.xlsx");
-    })
-    .catch(() => {
-      proxy.$modal.msg("宸插彇娑�");
-    });
-};
-// 鍒犻櫎
-const handleDelete = () => {
-  let ids = [];
-  if (selectedRows.value.length > 0) {
-		// 妫�鏌ユ槸鍚︽湁浠栦汉缁存姢鐨勬暟鎹�
-		const unauthorizedData = selectedRows.value.filter(item => item.maintainUserName !== userStore.nickName);
-		if (unauthorizedData.length > 0) {
-			proxy.$modal.msgWarning("涓嶅彲鍒犻櫎浠栦汉缁存姢鐨勬暟鎹�");
-			return;
-		}
-    ids = selectedRows.value.map((item) => item.id);
-  } else {
-    proxy.$modal.msgWarning("璇烽�夋嫨鏁版嵁");
-    return;
   }
-  ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚垹闄わ紝鏄惁纭鍒犻櫎锛�", "鍒犻櫎鎻愮ず", {
-    confirmButtonText: "纭",
-    cancelButtonText: "鍙栨秷",
-    type: "warning",
-  })
-    .then(() => {
-      tableLoading.value = true;
-      delSupplier(ids)
-        .then((res) => {
-          proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
-          getList();
-        })
-        .finally(() => {
-          tableLoading.value = false;
-        });
-    })
-    .catch(() => {
-      proxy.$modal.msg("宸插彇娑�");
-    });
-};
-
-// 鑾峰彇褰撳墠鏃ユ湡骞舵牸寮忓寲涓� YYYY-MM-DD
-function getCurrentDate() {
-  const today = new Date();
-  const year = today.getFullYear();
-  const month = String(today.getMonth() + 1).padStart(2, "0"); // 鏈堜唤浠�0寮�濮�
-  const day = String(today.getDate()).padStart(2, "0");
-  return `${year}-${month}-${day}`;
+}
+</script>
+<style>
+.main-container :deep(.el-tabs__item.is-active) {
+  color: #1883f6 !important;
+  border-bottom: 2px solid #409EFF;
 }
 
-onMounted(() => {
-  getList();
-});
-</script>
-
-<style scoped lang="scss"></style>
+</style>
diff --git a/src/views/procurementManagement/procurementLedger/index.vue b/src/views/procurementManagement/procurementLedger/index.vue
index 571e7ab..f6f2fce 100644
--- a/src/views/procurementManagement/procurementLedger/index.vue
+++ b/src/views/procurementManagement/procurementLedger/index.vue
@@ -54,6 +54,7 @@
         :summary-method="summarizeMainTable"
         @expand-change="expandChange"
         height="calc(100vh - 18.5em)"
+        :row-class-name="tableRowClassName"
       >
         <el-table-column align="center" type="selection" width="55" />
         <el-table-column type="expand">
@@ -112,6 +113,12 @@
           prop="supplierName"
           show-overflow-tooltip
         />
+        <el-table-column label="鐘舵��" width="100" align="center">
+          <template #default="scope">
+            <el-tag v-if="scope.row.isInvalid" type="danger" size="small">澶辨晥</el-tag>
+            <el-tag v-else type="success" size="small">姝e父</el-tag>
+          </template>
+        </el-table-column>
         <el-table-column
           label="椤圭洰鍚嶇О"
           prop="projectName"
@@ -979,7 +986,12 @@
   purchaseListPage({ ...rest, ...page })
     .then((res) => {
       tableLoading.value = false;
-      tableData.value = res.data.records;
+      // tableData.value = res.data.records;
+      // 澶勭悊鏁版嵁锛屾坊鍔犲け鏁堢姸鎬佹爣璁�
+      tableData.value = res.data.records.map(record => ({
+        ...record,
+        isInvalid: record.isWhite === 1
+      }));
       tableData.value.map((item) => {
         item.children = [];
       });
@@ -1047,7 +1059,8 @@
     salesContractList.value = res;
   });
   getOptions().then((res) => {
-    supplierList.value = res.data;
+    // 渚涘簲鍟嗚繃婊ゅ嚭isWhite=0 鐨勬暟鎹�
+    supplierList.value = res.data.filter((item) => item.isWhite == 0);
   });
   form.value.recorderId = userStore.id;
   form.value.entryDate = getCurrentDate();
@@ -1599,11 +1612,19 @@
   return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
 }
 
-
+// 娣诲姞琛岀被鍚嶆柟娉�
+const tableRowClassName = ({ row }) => {
+  return row.isInvalid ? 'invalid-row' : '';
+};
 
 onMounted(() => {
   getList();
 });
 </script>
 
-<style scoped lang="scss"></style>
+<style scoped lang="scss">
+.invalid-row {
+  opacity: 0.6;
+  background-color: #f5f7fa;
+}
+</style>
diff --git a/src/views/qualityManagement/nearExpiryReturn/index.vue b/src/views/qualityManagement/nearExpiryReturn/index.vue
index 3758b43..93e19c2 100644
--- a/src/views/qualityManagement/nearExpiryReturn/index.vue
+++ b/src/views/qualityManagement/nearExpiryReturn/index.vue
@@ -1,6 +1,6 @@
 <template>
   <div class="app-container">
-    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
       <el-form-item label="浜у搧鍚嶇О" prop="productName">
         <el-input
           v-model="queryParams.productName"

--
Gitblit v1.9.3