From dc1879fd0713eed48b2c75af5f29a1085291d276 Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期二, 07 五月 2024 14:40:55 +0800
Subject: [PATCH] 1.文件替换
---
src/views/basicSettings/contactUnitList.vue | 56 +++++++++++++++++++++++++++++++++++++++++++++++---------
1 files changed, 47 insertions(+), 9 deletions(-)
diff --git a/src/views/basicSettings/contactUnitList.vue b/src/views/basicSettings/contactUnitList.vue
index 448a898..b62fa97 100644
--- a/src/views/basicSettings/contactUnitList.vue
+++ b/src/views/basicSettings/contactUnitList.vue
@@ -61,8 +61,13 @@
<div
style=" width:calc(100% - 300px);"
>
- <div class="bodyTopButtonGroup">
+ <div class="bodyTopButtonGroup" style="justify-content: space-between">
<el-button v-waves type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">鏂板</el-button>
+ <div style="display: flex">
+ <el-button v-waves type="success" icon="el-icon-download" @click="$router.push('./../systemSetting/dataImport?fileCode=5')">瀵煎叆</el-button>
+ <el-button v-waves icon="el-icon-refresh-right" @click="syncERP">鍚屾寰�鏉ュ崟浣�</el-button>
+
+ </div>
</div>
<div class="bodyTopFormGroup">
@@ -216,12 +221,12 @@
{{ row.addr?row.addr:'/' }}
</template>
</el-table-column>
- <el-table-column
- label="鏁版嵁鏉ユ簮"
- prop="data_sources"
- sortable="custom"
- width="110"
- />
+ <!-- <el-table-column-->
+ <!-- label="鏁版嵁鏉ユ簮"-->
+ <!-- prop="data_sources"-->
+ <!-- sortable="custom"-->
+ <!-- width="110"-->
+ <!-- />-->
<el-table-column
label="鍒涘缓浜哄憳"
prop="username"
@@ -418,6 +423,7 @@
TCunstomerClassTreeDelete,
TCunstomerData, TCunstomerDelete
} from '@/api/basicSettings'
+import { SeaveSearchPartner } from '@/api/ErpSyncMes'
export default {
name: 'RoleList',
@@ -519,12 +525,15 @@
i.idparent = i.idparent ? i.idparent : '-1'
})
this.treeLeftArr = res.data
+ this.treeLeftArr.forEach(e => {
+ e.name = e.code + ' ' + e.name
+ })
this.treeLeft = arrayToTree(this.treeLeft.concat(res.data), {
parentProperty: 'idparent',
customID: 'code',
childrenProperty: 'children'
})
-
+ console.log(JSON.stringify(this.treeLeft), 1)
this.$nextTick(() => {
this.$refs.treeLeftRef.setCurrentKey('-1')
this.getTCunstomerData(this.$refs.treeLeftRef.getCurrentNode())
@@ -660,7 +669,7 @@
treeEditClick(node, data, operation) {
this.dialogClassForm.data_sources = data.data_sources
this.dialogClassForm.customerclasscode = data.code
- this.dialogClassForm.customerclassname = data.name
+ this.dialogClassForm.customerclassname = data.name.split(' ')[1]
this.dialogClassForm.parentcode = data.idparent === '-1' ? '' : data.idparent
this.dialogClassForm.OperType = 'Update'
this.operation = operation
@@ -762,6 +771,35 @@
this.dialogForm.idUnitBySale = mainUnitCode
this.dialogForm.idunitbymanufacture = mainUnitCode
}
+ },
+ // 鍚屾ERP
+ syncERP() {
+ const loading = this.$loading({
+ lock: true,
+ text: '姝e湪鍚屾ERP锛岃绋嶇瓑...',
+ spinner: 'el-icon-loading',
+ customClass: 'osloading',
+ background: 'rgba(0, 0, 0, 0.7)'
+ })
+
+ SeaveSearchPartner().then(res => {
+ if (res.code === '200') {
+ setTimeout(() => {
+ this.getTCunstomerData(this.$refs.treeLeftRef.getCurrentNode())
+ this.getTCunstomerClassTree()
+ loading.close()
+ this.$notify.success('鍚屾鎴愬姛锛�')
+ }, 2000)
+ }
+ // else if (res.code === '300') {
+ // setTimeout(() => {
+ // loading.close()
+ // this.$message.error('鍚屾澶辫触锛�')
+ // }, 10000)
+ // }
+ }).catch(e => {
+ loading.close()
+ })
}
}
}
--
Gitblit v1.9.3