From ffba2c405154eb6de9be00d9b5632e8a33ffc366 Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期四, 30 十月 2025 18:09:26 +0800
Subject: [PATCH] 改bug
---
admin/src/views/business/internalCompany.vue | 27 ++++++++++++++++++++++++---
1 files changed, 24 insertions(+), 3 deletions(-)
diff --git a/admin/src/views/business/internalCompany.vue b/admin/src/views/business/internalCompany.vue
index ae0e822..6bfea48 100644
--- a/admin/src/views/business/internalCompany.vue
+++ b/admin/src/views/business/internalCompany.vue
@@ -17,14 +17,16 @@
<!-- 琛ㄦ牸鍜屽垎椤� -->
<template v-slot:table-wrap>
<ul class="toolbar" v-permissions="['business:company:create', 'business:company:sync']">
-<!-- <li><el-button type="primary" v-permissions="['business:company:create']"-->
-<!-- @click="$refs.OperaInternalCompanyWindow.open('鏂板缓浼佷笟', null, null)">鏂板缓</el-button></li>-->
+ <li><el-button type="primary" v-permissions="['business:company:create']"
+ @click="$refs.OperaInternalCompanyWindow.open('鏂板缓缁勭粐', null, null)">鏂板缓</el-button></li>
<li><el-button @click="sort('top')" :loading="sorting" icon="el-icon-sort-up"
v-permissions="['business:company:sort']">涓婄Щ</el-button></li>
<li><el-button @click="sort('bottom')" :loading="sorting" icon="el-icon-sort-down"
v-permissions="['business:company:sort']">涓嬬Щ</el-button></li>
<li><el-button type="primary" v-permissions="['business:company:sync']" :loading="loading"
@click="synchronous()">鍚屾</el-button></li>
+ <li><el-button type="primary" v-permissions="['business:company:create']" :loading="loading"
+ @click="synchronousDingding()">鍚屾閽夐拤</el-button></li>
</ul>
<el-table :max-height="tableHeight" v-loading="isWorking.search" :data="list" stripe
:tree-props="{ children: 'childList', hasChildren: 'hasChildren' }" row-key="id"
@@ -43,6 +45,7 @@
<el-table-column prop="editDate" label="鏈�鍚庢洿鏂版椂闂�" min-width="100px"></el-table-column>
<el-table-column label="鎿嶄綔" width="230" fixed="right">
<template slot-scope="{row}">
+<!-- v-if="row.type ==0"-->
<el-button type="text"
@click="$refs.OperaInternalCompanyWindow.open('缂栬緫浼佷笟淇℃伅', { id: row.parentId, name: row.parentName, type: row.parentType, companyPath: row.parentCompanyPath }, row, 'edit')"
icon="el-icon-edit" v-permissions="['business:company:update']">缂栬緫</el-button>
@@ -62,7 +65,7 @@
<script>
import BaseTable from '@/components/base/BaseTable'
import TableLayout from '@/layouts/TableLayout'
-import { companySync, sort } from '@/api/business/company'
+import { companySync,companySyncDingding, sort } from '@/api/business/company'
import OperaInternalCompanyWindow from '@/components/business/OperaInternalCompanyWindow'
export default {
name: 'internalCompany',
@@ -129,6 +132,24 @@
})
.catch(() => { })
},
+ async synchronousDingding() {
+ this.$dialog.actionConfirm('璇ユ搷浣滃皢绯荤粺娓呯┖宸叉湁鍐呴儴缁勭粐淇℃伅锛屾偍纭鍚屾鍏ㄩ儴淇℃伅鍚楋紵', '鎿嶄綔纭鎻愰啋')
+ .then(() => {
+ this.loading = true
+ companySyncDingding({})
+ .then(res => {
+ this.$tip.apiSuccess(res || '鍚屾鎴愬姛')
+ this.search()
+ })
+ .catch(e => {
+ this.$tip.apiFailed(e)
+ })
+ .finally(() => {
+ this.loading = false
+ })
+ })
+ .catch(() => { })
+ },
// 鎺掑簭
sort(direction) {
if (this.sorting) {
--
Gitblit v1.9.3