Commit 0c05b731 by 陈羽

Merge branch 'feature/销售线索4' into dev

parents 66c246d0 25835e31
......@@ -90,12 +90,12 @@ export default {
tabId: '14',
tabName: '会员详情设置',
icon: ''
},
{
tabId: '15',
tabName: '会员标签设置',
icon: ''
}
// {
// tabId: '15',
// tabName: '会员标签设置',
// icon: ''
// }
]
},
{
......@@ -131,6 +131,28 @@ export default {
},
computed: {},
methods: {
checkTagTab() {
let para = {
enterpriseId: this.activeBrand
};
getRequest('/haoban-app-customer-web/tag/open-tag', para)
.then(res => {
if (!!res.data.result) {
this.tabListData[0].children.push({
tabId: '15',
tabName: '会员标签设置',
icon: ''
});
}
// errMsg.errorMsg(resData);
})
.catch(function(error) {
this.$message.error({
duration: 1000,
message: error.message
});
});
},
getExpired() {
const that = this;
let para = {
......@@ -163,10 +185,12 @@ export default {
* 返回 的 brandId
*/
selectBrandId(id, groupId) {
console.log(id);
let that = this;
that.activeBrand = id;
that.activeGroup = groupId;
that.getExpired(); // 到期通知
that.checkTagTab();
},
/**
......
......@@ -40,13 +40,12 @@
<el-option label="未同步" :value="0"></el-option>
<el-option label="同步中" :value="1"></el-option>
<el-option label="同步完成" :value="2"></el-option>
<el-option label="同步失败" :value="3"></el-option>
<el-option label="全部同步状态" :value="-1"></el-option>
</el-select>
</div>
<div class="btn-group">
<el-button @click="$router.push('/syncHistory')">同步历史</el-button>
<el-button @click="drawer = true" type="primary" :disabled="!canSync" :class="['sync-btn', isShake ? 'shake' : '']">待开启同步标签( {{ tagIds.length }}</el-button><span v-if="canUseCount === 0" class="no-use-count">本月同步次数已用尽</span>
<el-button @click="drawer = true" type="primary" :disabled="!canSync || !canUseCount" :class="['sync-btn', isShake ? 'shake' : '']">待开启同步标签( {{ tagIds.length }}</el-button><span v-if="canUseCount === 0" class="no-use-count">本月同步次数已用尽</span>
</div>
</div>
<div class="tag-content-bottom">
......@@ -176,7 +175,7 @@ export default {
totalCount: 4, // 总同步次数
canUseCount: 0, // 剩余同步次数
checkFirst: '',
syncStatusOpt: { 0: '未同步', 1: '同步中', 2: '同步完成 ', 3: '同步失败 ' },
syncStatusOpt: { 0: '未同步', 1: '同步中', 2: '同步完成 ' },
syncStatusClass: { 0: 'state-point-default', 1: 'state-point-loading-scale', 2: 'state-point-success', 3: 'state-point-error' }
};
},
......@@ -216,15 +215,20 @@ export default {
};
tagList(params).then(res => {
this.total = res.data.result.totalCount;
res.data.result.result.map((el, index) => {
el.expend = false;
el.index = index;
});
this.tableData = res.data.result.result;
this.loading = false;
this.$nextTick(() => {
this.chengePageToggleSelect();
});
if (Array.isArray(res.data.result.result) && res.data.result.result.length) {
res.data.result.result.map((el, index) => {
el.expend = false;
el.index = index;
});
this.tableData = res.data.result.result;
this.loading = false;
this.$nextTick(() => {
this.chengePageToggleSelect();
});
} else {
this.tableData = [];
this.loading = false;
}
});
},
// 关闭同步接口
......
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