|
@@ -5,7 +5,7 @@
|
|
|
type="warning"
|
|
|
style="margin-left:10px"
|
|
|
v-if="position == 'detail'"
|
|
|
- :disabled="data.data.status == '待跟进' || data.data.status == '跟进中' ? false : true"
|
|
|
+ :disabled="!isHandle"
|
|
|
@click="dialogVisible=true">跟进</el-button>
|
|
|
<p @click="dialogVisible=true" v-else>跟进</p>
|
|
|
<el-dialog title="线索跟进" :visible.sync="dialogVisible" width="900" :before-close="handleClose">
|
|
@@ -34,7 +34,7 @@
|
|
|
</el-col>
|
|
|
<el-col :span="24">
|
|
|
<el-form-item label="本次跟进结果" label-width="150px" label-position="left" prop="logtype">
|
|
|
- <el-radio-group v-model="param.content.logtype">
|
|
|
+ <el-radio-group v-model="param.content.logtype" @change="changeClick">
|
|
|
<el-radio label="跟进">跟进</el-radio>
|
|
|
<el-radio label="已成交">成交</el-radio>
|
|
|
<el-radio label="丢单">丢单</el-radio>
|
|
@@ -105,10 +105,11 @@ export default {
|
|
|
},
|
|
|
time:'',
|
|
|
dialogVisible: false,
|
|
|
- };
|
|
|
+ isHandle:''
|
|
|
+ }
|
|
|
},
|
|
|
props: {
|
|
|
- data: {
|
|
|
+ detailInfo: {
|
|
|
default() {
|
|
|
return []
|
|
|
}
|
|
@@ -126,12 +127,42 @@ export default {
|
|
|
computed: {
|
|
|
},
|
|
|
watch: {
|
|
|
+ detailInfo: {
|
|
|
+ handler(val) {
|
|
|
+ // this.isHandle =
|
|
|
+ let is
|
|
|
+ if(JSON.parse(window.sessionStorage.getItem('userInfo')).name == this.detailInfo.data.leadername) {
|
|
|
+ is = true
|
|
|
+ if(this.detailInfo.data.status == '待跟进' || this.detailInfo.data.status == '跟进中') {
|
|
|
+ is = true
|
|
|
+ } else {
|
|
|
+ is = false
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ is = false
|
|
|
+ }
|
|
|
+ this.isHandle = is
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
},
|
|
|
methods: {
|
|
|
handleClose() {
|
|
|
this.dialogVisible = false
|
|
|
},
|
|
|
+ changeClick() {
|
|
|
+ this.param = {
|
|
|
+ "classname": "saletool.orderclue.web.orderclue",
|
|
|
+ "method": "addFollowUpLog",
|
|
|
+ "content": {
|
|
|
+ "sat_orderclueid":0,
|
|
|
+ "content": "",
|
|
|
+ "followupmode": "", //当面拜访、电话沟通
|
|
|
+ "logtype": this.param.content.logtype, //跟进、成交、丢单、无效
|
|
|
+ "competitor": ""
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
followAction() {
|
|
|
this.$refs.ruleForm.validate( async val => {
|
|
|
if(!val) return this.$notify({
|
|
@@ -139,7 +170,7 @@ export default {
|
|
|
message:'请按照要求填写信息',
|
|
|
type:'warning'
|
|
|
})
|
|
|
- this.param.content.sat_orderclueid = this.data.data.sat_orderclueid
|
|
|
+ this.param.content.sat_orderclueid = this.detailInfo.data.sat_orderclueid
|
|
|
let res = await this.$api.requested(this.param)
|
|
|
this.tool.showMessage(res,() => {
|
|
|
this.dialogVisible = false
|