Commit ea33030b authored by caixingbing's avatar caixingbing

*

parent 9cf622f0
......@@ -8,3 +8,12 @@ export const idRemark = (data) => {
data: data
})
}
// 认领用户
export const claim= function claim(param) {
return request({
url: '/customer/claim',
method: 'post',
data: param
})
}
......@@ -65,7 +65,7 @@
</div>
</div>
<div class="company-menu">
<el-button @click="handleClaim" v-if="ifClaim" class="hasClaim" v-loading="claimLoading"><i class="el-ico-claim" alt="已认领" title="已认领"></i> 已认领</el-button>
<el-button @click="handleClaim" v-if="ifClaim==1" class="hasClaim" v-loading="claimLoading"><i class="el-ico-claim" alt="已认领" title="已认领"></i> 已认领</el-button>
<el-button @click="handleClaim" v-else class="claim" v-loading="claimLoading"><i class="el-ico-claim" alt="认领客户" title="认领客户"></i> 认领客户</el-button>
</div>
......@@ -121,6 +121,19 @@
</div>
<!-- 分条件:滚动与不滚动 -->
</div>
<el-dialog
title=""
:visible.sync="dialogVisible"
:modal="false"
custom-class='dialog-renlin'
:show-close="false"
width="244px">
<span>认领成功,是否完善客户信息?</span>
<div slot="footer" class="dialog-footer">
<span class="dialog-footer-btn1" type="primary" @click="renlin()">立即完善</span>
<span class="dialog-footer-btn2" @click="renHide()">稍后</span>
</div>
</el-dialog>
</div>
</template>
......@@ -128,6 +141,7 @@
import { changePath } from '@/assets/js/common'
var Swiper = require('@/assets/lib/swiper/swiper-bundle.min.js')
import "@/assets/lib/swiper/swiper-bundle.css"
import { claim } from "@/api/common"
export default {
name: 'Infoheader',
props: ['companyId', 'companyInfo', 'statistic'],
......@@ -136,7 +150,7 @@ export default {
newStatic: null,
labelList: [], //企业标签
claimLoading: false,
ifClaim: false, //是否认领
ifClaim: 0, //是否认领
showMore: false,
showState: false,
graphList: [
......@@ -151,6 +165,7 @@ export default {
//风险扫描
labelArr:['失信联合惩戒企业','司法纠纷','注销'], //负向经营状态
enterpriseLabel:[],//企业标签
dialogVisible: false
}
},
created() {
......@@ -163,16 +178,18 @@ export default {
methods: {
//认领
async handleClaim(){
let _this = this
_this.claimLoading = true
setTimeout(function (){
_this.claimLoading = false
_this.$confirm(`认领成功,是否完善客户信息`, '提示', {
type: 'warning'
}).then(async () => {
console.log('操作跳转!')
})
}, 1000)
if(this.companyInfo.uipId){
this.claimLoading = true
let param = {companyId:this.companyId, uipId:this.companyInfo.uipId, companyName:this.companyInfo.companyName}
let res = await claim(param)
this.tableLoading = false
if(res.code==200){
this.dialogVisible=true
this.ifClaim = true
}
}else{
this.$message.warning('对不起,当前不能认领')
}
},
companySwiper(){
new Swiper('.swiper-info', {
......@@ -208,8 +225,8 @@ export default {
this.companySwiper() //swiper滚动板块
},
//获取认领状态
async getClaimStatus(){
this.ifClaim = false
getClaimStatus(){
this.ifClaim = this.companyInfo.regCapital
},
handleWidth(){
if(this.companyInfo.introduction){
......@@ -261,6 +278,14 @@ export default {
if(it.id==302 && it.val){
changePath(this, 'administrative')
}
},
renlin(){
this.dialogVisible=false;
// this.$router.push({path:'/home',query: {id:'1'}})
// 跳转地址
},
renHide(){
this.dialogVisible=false;
}
},
watch: {
......@@ -619,4 +644,47 @@ export default {
margin-left: 4px;
}
}
::v-deep .dialog-renlin{
margin-top:40vh !important;
.el-dialog__body{
padding: 0;
text-align: center;
padding-bottom: 24px;
}
.el-dialog__footer{
padding: 0px;
padding-bottom: 24px;
.dialog-footer{
display: inline-flex;
align-items: center;
justify-content: center;
width: 100%;
.dialog-footer-btn1{
cursor: pointer;
width: 72px;
height: 28px;
background: #0081FF;
border-radius: 2px 2px 2px 2px;
font-size: 12px;
font-weight: 400;
color: #FFFFFF;
line-height: 28px;
text-align: center;
margin-right: 8px;
}
.dialog-footer-btn2{
cursor: pointer;
width: 72px;
height: 28px;
border-radius: 2px 2px 2px 2px;
border: 1px solid #CCCCCC;
line-height: 28px;
text-align: center;
font-size: 12px;
font-weight: 400;
color: rgba(35,35,35,0.8);
}
}
}
}
</style>
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