lxr 6 өдөр өмнө
parent
commit
f8f798aa0b

+ 11 - 17
src/views/lawyerManagement/lawFirm/index.vue

@@ -4,24 +4,18 @@
       <template #tableHeader>
         <!-- <el-button type="primary" :icon="CirclePlus" :disabled="!isAdmin" @click="handleCreate"> 新增律所 </el-button>
         <el-button type="primary" :icon="Upload" :disabled="!isAdmin" @click="handleImport"> 导入 </el-button> -->
-        <!-- <el-button
-          type="primary"
-          :icon="Download"
-          :loading="exportLoading"
-          :disabled="!hasExportableData || !isAdmin"
-          @click="handleExport"
-        >
+        <el-button type="primary" :icon="Download" :loading="exportLoading" :disabled="!hasExportableData" @click="handleExport">
           导出
-        </el-button> -->
-        <el-button
+        </el-button>
+        <!-- <el-button
           type="primary"
           :icon="Download"
           :loading="exportAllLoading"
-          :disabled="!hasExportableData || !isAdmin"
+          :disabled="!hasExportableData"
           @click="handleExportAll"
         >
           全部导出
-        </el-button>
+        </el-button> -->
       </template>
       <template #paymentAccount="scope">
         <div class="payment-tags">
@@ -236,9 +230,9 @@ const buildExportParams = (override: Record<string, any> = {}) => {
 };
 
 const handleExport = async () => {
-  if (!ensureAdmin()) {
-    return;
-  }
+  // if (!ensureAdmin()) {
+  //   return;
+  // }
   if (!hasExportableData.value) {
     ElMessage.warning("暂无可导出的数据");
     return;
@@ -253,9 +247,9 @@ const handleExport = async () => {
 };
 
 const handleExportAll = async () => {
-  if (!ensureAdmin()) {
-    return;
-  }
+  // if (!ensureAdmin()) {
+  //   return;
+  // }
   if (!hasExportableData.value) {
     ElMessage.warning("暂无可导出的数据");
     return;

+ 2 - 8
src/views/lawyerManagement/lawyer/index.vue

@@ -2,13 +2,7 @@
   <div class="table-box">
     <ProTable ref="proTable" :columns="columns" :request-api="getTableList" :data-callback="dataCallback">
       <template #tableHeader>
-        <el-button
-          type="primary"
-          :icon="Download"
-          :loading="exportLoading"
-          :disabled="!isAdmin || !hasExportableData"
-          @click="handleExport"
-        >
+        <el-button type="primary" :icon="Download" :loading="exportLoading" :disabled="!hasExportableData" @click="handleExport">
           导出
         </el-button>
       </template>
@@ -201,7 +195,7 @@ const collectTableParams = () => {
 };
 
 const handleExport = async () => {
-  if (!ensureAdmin() || !hasExportableData.value) return;
+  // if (!ensureAdmin() || !hasExportableData.value) return;
   exportLoading.value = true;
   try {
     const params = normalizeRequestParams(collectTableParams());