Bladeren bron

fix:权限修改

ly 10 maanden geleden
bovenliggende
commit
f66537d3eb

+ 10 - 7
src/views/business/financial/collection/form.vue

@@ -10,14 +10,15 @@
             付款信息</span>
 
           <el-button v-if="editStatus" type="primary" size="small" icon="Finished" @click="submitForm">保存</el-button>
-          <el-button v-show="form.status == 1 " type="warning" size="small" icon="Finished" @click="returnZero"
-            v-hasPermi="['business:collection:return']">退回</el-button>
-          <el-button v-show="!editStatus && form.verifyDate == null " type="warning" size="small" icon="Edit"
-            v-hasPermi="['business:collection:edit']" @click="editStatus = true">修改</el-button>
+          <el-button v-show="form.status == 1 && auth.hasPermi('business:collection:return')" type="warning" size="small" icon="Finished" @click="returnZero"
+           >退回</el-button>
+          <el-button v-show="(!editStatus && form.verifyDate == null)&& auth.hasPermi('business:collection:edit') " type="warning" size="small" icon="Edit"
+            @click="editStatus = true">修改</el-button>
           <el-button v-if="form.id && editStatus" type="info" size="small" icon="Close"
             @click="editStatus = false">取消修改</el-button>
-          <el-button v-show="form.id && !editStatus && form.verifyDate == null"
-            v-hasPermi="['business:collection:verify']" type="primary" size="small" icon="Check"
+          <el-button v-show="(form.id && !editStatus && form.verifyDate == null)
+          && auth.hasPermi('business:collection:verify')"
+           type="primary" size="small" icon="Check"
             @click="verifyHandler">收款审核</el-button>
 
           <div class="screen-btn" @click="handleScreen">
@@ -122,7 +123,8 @@
             </el-col>
             <el-col :span="6">
               <el-form-item label="合同编号:" prop="remark">
-                <el-link :underline="false" type="primary" @click="handleContract(form)">{{ form.contractNo }}</el-link>
+                <el-link v-if="auth.hasPermi('business:archive:order:view')" :underline="false" type="primary" @click="handleContract(form)">{{ form.contractNo }}</el-link>
+                <span v-else>{{form.contractNo}}</span>
               </el-form-item>
             </el-col>
             <el-col :span="6">
@@ -401,6 +403,7 @@
 </template>
 <script setup>
   import { uploadFile } from "@/api/tool/file";
+  import auth from "@/plugins/auth";
   // import {
   //   getOrder,
   //   initTaskTypes,

+ 3 - 1
src/views/business/financial/contract/form.vue

@@ -126,7 +126,8 @@
             </el-col>
             <el-col :span="6">
               <el-form-item label="合同编号:" prop="remark">
-                <el-link :underline="false" type="primary" @click="handleContract(form)">{{ form.contractNo }}</el-link>
+                <el-link v-if="auth.hasPermi('business:archive:order:view')" :underline="false" type="primary" @click="handleContract(form)">{{ form.contractNo }}</el-link>
+                <span v-else>{{form.contractNo}}</span>
               </el-form-item>
             </el-col>
             <el-col :span="6">
@@ -344,6 +345,7 @@
   import contractForm from "@/views/business/crm/order/form.vue";
   import match from "@/utils/match";
   import useUserStore from "@/store/modules/user";
+  import auth from "@/plugins/auth";
   const { proxy } = getCurrentInstance();
   const baseUrl = import.meta.env.VITE_APP_BASE_API;
 

+ 1 - 1
src/views/business/production/onceWork/index.vue

@@ -193,7 +193,7 @@
       </el-table-column>
       <el-table-column label="合同" align="center" min-width="50" >
         <template #default="scope">
-          <el-button v-hasPermi="['business:archive:order:list']" link type="primary" size="small" @click="viewContract(scope.row)">查看</el-button>
+          <el-button v-hasPermiView="['business:archive:order:view']" link type="primary" size="small" @click="viewContract(scope.row)">查看</el-button>
         </template>
       </el-table-column>
       <el-table-column label="执行人" align="center" width="100" :show-overflow-tooltip="true">