|
@@ -1,13 +1,12 @@
|
|
|
<template>
|
|
|
<div class="app-container">
|
|
|
- <div class="btn_grooup" v-if="bo.winningState == 0 ? true : false">
|
|
|
+ <div class="btn_grooup" v-if="source == 'BO' && bo.winningState == 0 && boAuthority.boAuthority.behaviorAdd">
|
|
|
<el-button
|
|
|
type="primary"
|
|
|
plain
|
|
|
icon="el-icon-plus"
|
|
|
size="mini"
|
|
|
@click="handleAdd"
|
|
|
- v-if="boAuthority.boAuthority.behaviorAdd"
|
|
|
>新增</el-button>
|
|
|
</div>
|
|
|
<el-table v-loading="loading" :data="behaviorList">
|
|
@@ -226,22 +225,22 @@
|
|
|
<el-row>
|
|
|
<el-col :span="6">
|
|
|
<el-form-item label="创建人">
|
|
|
- <el-input v-model="form.createByName" size="small" readonly></el-input>
|
|
|
+ <el-input v-model="form.createByName" readonly></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
|
<el-form-item label="创建时间">
|
|
|
- <el-input v-model="form.createTime" size="small" readonly></el-input>
|
|
|
+ <el-input v-model="form.createTime" readonly></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
|
<el-form-item label="修改人">
|
|
|
- <el-input v-model="form.updateByName" size="small" readonly></el-input>
|
|
|
+ <el-input v-model="form.updateByName" readonly></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
|
<el-form-item label="修改时间">
|
|
|
- <el-input v-model="form.updateTime" size="small" readonly></el-input>
|
|
|
+ <el-input v-model="form.updateTime" readonly></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
@@ -262,7 +261,7 @@ import SaleaeaRef from '@/views/business/spd/bo/refer/saleaea/index.vue';
|
|
|
|
|
|
export default {
|
|
|
name: "BehaviorList",
|
|
|
- props:["source","bo","query","boAuthority"],
|
|
|
+ props:["source","bo","boAuthority","task"],
|
|
|
dicts: ['mk_bo_behavior_res','mk_bo_behavior_type','sys_yes_no','mk_bo_behavior_goal'],
|
|
|
components: {ContactRef,SaleaeaRef},
|
|
|
data() {
|
|
@@ -274,14 +273,6 @@ export default {
|
|
|
fileList: [],
|
|
|
// 遮罩层
|
|
|
loading: true,
|
|
|
- // 选中数组
|
|
|
- ids: [],
|
|
|
- // 非单个禁用
|
|
|
- single: true,
|
|
|
- // 非多个禁用
|
|
|
- multiple: true,
|
|
|
- // 显示搜索条件
|
|
|
- showSearch: true,
|
|
|
// 总条数
|
|
|
total: 0,
|
|
|
// 行动表格数据
|
|
@@ -342,16 +333,17 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
|
- console.log("this.bo",this.bo);
|
|
|
- if(this.source == "Task"){
|
|
|
- this.queryParams.task = this.query.id;
|
|
|
+ //组件创建时初始化查询参数
|
|
|
+ if(this.source == "TASK"){
|
|
|
+ this.queryParams.task = this.task.id;
|
|
|
}
|
|
|
- if(this.source == "Bo"){
|
|
|
- this.queryParams.bo = this.query.id;
|
|
|
- this.queryParams.boStage = this.query.boStage;
|
|
|
+ if(this.source == "BO"){
|
|
|
+ this.queryParams.bo = this.bo.id;
|
|
|
+ this.queryParams.boStage = this.bo.boStage;
|
|
|
let params = {"post":this.boAuthority.post};
|
|
|
this.queryParams.params = params;
|
|
|
}
|
|
|
+ //查询
|
|
|
this.getList();
|
|
|
},
|
|
|
methods: {
|
|
@@ -444,12 +436,20 @@ export default {
|
|
|
this.reset();
|
|
|
this.operatingState = "Insert";
|
|
|
//新增行动设置默认值
|
|
|
- this.queryParams.bo = this.bo.id;
|
|
|
- this.form.bo = this.bo.id;
|
|
|
- this.form.boName = this.bo.boName;
|
|
|
- this.form.boStage = this.bo.boStage;
|
|
|
- this.form.customer = this.bo.customer;
|
|
|
- this.form.customerName = this.bo.customerName;
|
|
|
+ if(this.source == "TASK"){
|
|
|
+ this.form.bo = this.task.id;
|
|
|
+ this.form.boName = this.task.boName;
|
|
|
+ this.form.boStage = this.task.boStage;
|
|
|
+ this.form.customer = this.task.customer;
|
|
|
+ this.form.customerName = this.task.customerName;
|
|
|
+ }
|
|
|
+ if(this.source == "BO"){
|
|
|
+ this.form.bo = this.bo.id;
|
|
|
+ this.form.boName = this.bo.boName;
|
|
|
+ this.form.boStage = this.bo.boStage;
|
|
|
+ this.form.customer = this.bo.customer;
|
|
|
+ this.form.customerName = this.bo.customerName;
|
|
|
+ }
|
|
|
this.form.type = '0';
|
|
|
this.form.staff = this.$store.state.user.id;
|
|
|
this.form.staffName = this.$store.state.user.nickName;
|