Commit de088d7e by 李伟康

修改样式

1 parent 84280f84
......@@ -55,17 +55,19 @@
<div class="tabs-content box">
<div class="tabs-title">客户增长趋势</div>
<div class="tabs-content-chart flex">
<div class="line">
<template v-if="flag">
<template v-if="isEmpty">
<div class="empty">
<img src="@/assets/images/empty.png" />
</div>
</template>
<template v-else>
<div
class="line"
ref="canvas"
class="canvas"
></div>
</template>
</template>
</div>
<div class="table user-select pointer">
<div class="table-head">
<template v-for="(i,index) in tabHead">
......@@ -145,7 +147,8 @@ export default {
canvas: null,
req: {},
isGroup: true,
isEmpty: true
isEmpty: true,
flag: false
}
},
mounted () {
......@@ -159,6 +162,7 @@ export default {
if (params.brand) this.isGroup = false
this.req = req
this.isEmpty = true
this.flag = false
this.getOverallbase('total')
this.getOverallbase('wechat')
this.getOverallbase('wechatGroup')
......@@ -181,7 +185,6 @@ export default {
this.api.overview[this.isGroup ? 'getBrandOverallbase' : 'getMerchantOverallbase'](params).then(({ code, data }) => {
if (code == 0) {
let [dataList] = data.dataList
console.log(dataList)
if (dataList) {
dataList.top = this.ObjectToArray(dataList.topList)
dataList.last = this.ObjectToArray(dataList.lastList)
......@@ -213,6 +216,7 @@ export default {
queryendTime: queryType == 1 ? this.getNDate(-1) : this.getNMonth(-1),
}
this.api.overview[this.isGroup ? 'getBrandOveralltrend' : 'getMerchantOveralltrend'](params).then(({ data, code }) => {
this.flag = true
if (code == 0) {
if (!data.dataList.map(item => item.totalNum).every(item => item === 0)) {
this.isEmpty = false
......@@ -389,7 +393,7 @@ export default {
color: #e60115;
}
}
>div{
> div {
flex-shrink: 0;
}
}
......@@ -410,9 +414,12 @@ export default {
margin-top: auto;
justify-content: space-between;
gap: 0 8px;
.line,
.empty {
.line {
flex: 7;
.canvas {
width: 100%;
height: 100%;
}
}
.table {
flex: 3;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!