Commit a9172361 authored by xiongjinke's avatar xiongjinke

修改

parent 5bb5cfe3
......@@ -59,7 +59,7 @@ import BasicIinformation from "./component/basicIinformation"
import ElCardinput from "./component/elCardinput"
export default {
name: 'Business',
props: ['customerIds', 'companyInfo'],
props: ['customerIds', 'companyInfo', 'customerInfo'],
components: {
Info,
BasicIinformation,
......@@ -99,25 +99,40 @@ export default {
}
},
created() {
this.handleQuery()
this.infos = this.customerInfo
},
mounted(){
this.customerInfos()
//企业性质
getDictType('company_nature_type').then(result=>{
this.companyType.companyNaturelist = result.code == 200 ? result.data:[]
},
methods: {
async handleQuery() {
let [type1,type2,type3] = await Promise.all([
getDictType('company_nature_type'),
getDictType('company_level_type'),
getDictType('credit_level_type')
])
if(type1.code==200){
type1.data.forEach(item => {
this.companyType.companyNaturelist.push({dictLabel:item.dictLabel,dictValue:item.dictLabel})
})
//企业级别
getDictType('company_level_type').then(result=>{
this.companyType.companyLevellist = result.code == 200 ? result.data:[]
}
if(type2.code==200){
type2.data.forEach(item => {
this.companyType.companyLevellist.push({dictLabel:item.dictLabel,dictValue:item.dictLabel})
})
//资信等级
getDictType('credit_level_type').then(result=>{
this.companyType.creditLevellist = result.code == 200 ? result.data:[]
}
if(type3.code==200){
type3.data.forEach(item => {
this.companyType.creditLevellist.push({dictLabel:item.dictLabel,dictValue:item.dictLabel})
})
}
this.isInfo = true
},
methods: {
customerInfos(){
customerInfo(this.customerIds).then(res=>{
this.infos = res.data
this.isInfo = true
})
},
focusNowedits(e){
......
......@@ -320,5 +320,7 @@ export default {
::v-deep .el-table__fixed::before, ::v-deep .el-table__fixed-right::before{
background-color:unset;
}
::v-deep .el-dialog__headerbtn{
z-index: 9;
}
</style>
......@@ -44,11 +44,11 @@
<OpenacourtsessionNotice v-if="currentPath.pathName=='openacourtsessionNotice'" :company-id="companyId" />
<template v-if="customerId">
<!-- 商务信息 -->
<Business v-if="currentPath.pathName=='business'" :customer-ids="customerId" :companyInfo="companyInfo" />
<Business v-if="currentPath.pathName=='business'" :customer-ids="customerId" :companyInfo="companyInfo" :customerInfo="customerInfo" />
<!-- 招标偏好 -->
<Preference v-if="currentPath.pathName=='preference'" :customer-ids="customerId" />
<Preference v-if="currentPath.pathName=='preference'" :customer-ids="customerId" :customerInfo="customerInfo" />
<!-- 合作情况 -->
<Cooperate v-if="currentPath.pathName=='cooperate'" :customer-ids="customerId" :companyInfo="companyInfo" :cooDetail="cooDetail" @detail="cooperateDetail" />
<Cooperate v-if="currentPath.pathName=='cooperate'" :customer-ids="customerId" :companyInfo="companyInfo" :cooDetail="cooDetail" :customerInfo="customerInfo" @detail="cooperateDetail" />
<!-- 决策链条 -->
<DecisionMaking v-if="currentPath.pathName=='decisionMaking'" :customer-ids="customerId" :companyInfo="companyInfo" />
<!-- 跟进记录 -->
......@@ -64,6 +64,7 @@
<script>
import { idRemark } from '@/api/common'
import { infoHeader } from '@/api/detail/party-a/index'
import { customerInfo } from '@/api/detail/party-a/cooperate'
import elementResizeDetectorMaker from "element-resize-detector"
import Header from "./component/Header"
import SideBar from "./component/Sidebar"
......@@ -146,6 +147,7 @@ export default {
data() {
return {
companyInfo: {},
customerInfo: {},
companyId: '', //企业Id(测试默认3068)
customerId: '', //企业Id(测试默认'a00d582a6041f32c16aac804e4924736')
currentPath: {
......@@ -176,9 +178,6 @@ export default {
if (this.$route.query.path) { // 获取跳转对应板块
this.currentPath.pathName = this.$route.query.path
}
if (this.$route.query.customerId) { // 判断是否显示
this.customerId = this.$route.query.customerId
}
},
mounted() {
},
......@@ -197,6 +196,7 @@ export default {
this.listenSider()
})
this.handleQuery()
this.association(this.$route.query.customerId)
}
},
async handleQuery() {
......@@ -216,7 +216,23 @@ export default {
},
closeDetail(){
this.cooDetail = false
},
// 判断客户是否关联显示修改
association(id){
customerInfo(id).then(res=>{
if(res.code == 200){
if(res.data.companyId == this.companyId && res.data.userId == this.$store.state.user.userId){
this.customerInfo = res.data
this.customerId = res.data.customerId
}else{
this.currentPath.pathName = 'overview'
}
}
}).catch(err=>{
this.currentPath.pathName = 'overview'
})
}
}
}
</script>
......
......@@ -160,7 +160,7 @@ export default {
components: {
},
props: ['customerIds'],
props: ['customerIds','customerInfo'],
data() {
return {
autosize: {
......@@ -181,6 +181,9 @@ export default {
}
},
created() {
this.queryParams = this.customerInfo
},
mounted(){
this.customerInfos()
},
computed: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment