Commit 64817be0 by Jaxon

feat(督导统计): 业务开发

1 parent 78b6d601
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
class="tab-section" class="tab-section"
:class="{ isSticky }" :class="{ isSticky }"
:style="{ background: customBackground }"> :style="{ background: customBackground }">
<div class="tab-slider" :style="tabSliderStyle"></div>
<div v-for="item in dateList" <div v-for="item in dateList"
:key="item.index" :key="item.index"
class="tab" class="tab"
...@@ -127,6 +128,13 @@ export default { ...@@ -127,6 +128,13 @@ export default {
maxDateObj() { maxDateObj() {
return new Date(this.maxDate); return new Date(this.maxDate);
}, },
tabSliderStyle() {
const tabCount = this.dateList.length || 1;
return {
width: `calc((100% - 4px) / ${tabCount})`,
transform: `translateX(${this.dateCurrent * 100}%)`,
};
},
}, },
watch: { watch: {
tabSelected(n) { tabSelected(n) {
...@@ -415,9 +423,10 @@ export default { ...@@ -415,9 +423,10 @@ export default {
justify-content: center; justify-content: center;
.tab-section { .tab-section {
position: relative;
overflow: hidden;
box-sizing: border-box; box-sizing: border-box;
width: 139px; width: 139px;
height: 28px;
display: flex; display: flex;
align-items: center; align-items: center;
background: #ffffff; background: #ffffff;
...@@ -425,35 +434,47 @@ export default { ...@@ -425,35 +434,47 @@ export default {
font-size: 13px; font-size: 13px;
color: #999999; color: #999999;
padding: 2px; padding: 2px;
flex-shrink: 0;
.tab-slider {
position: absolute;
top: 2px;
left: 2px;
height: 24px;
border-radius: 24px;
background: #2c66f71a;
transition: transform 0.25s ease;
}
&.isSticky { &.isSticky {
background: #f7f8fa; background: #f7f8fa;
} }
.tab { .tab {
position: relative;
z-index: 1;
flex: 1; flex: 1;
text-align: center; text-align: center;
height: 24px; line-height: 26px;
line-height: 24px;
border-radius: 24px; border-radius: 24px;
transition: color 0.25s ease;
flex-shrink: 0;
&.active { &.active {
color: #2c66f7; color: #2c66f7;
font-weight: 500; font-weight: 500;
background: #2c66f71a;
} }
} }
} }
.date-section { .date-section {
box-sizing: border-box; box-sizing: border-box;
height: 28px;
flex: 1; flex: 1;
// max-width: calc(100% - 139px);
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
margin-left: 22px;
flex-shrink: 0;
.date-text { .date-text {
font-family: "numberNor"; font-family: "numberNor";
font-size: 13px; font-size: 13px;
......
...@@ -15,6 +15,14 @@ export const performance = [ ...@@ -15,6 +15,14 @@ export const performance = [
showTabBar: true, showTabBar: true,
}, },
}, },
{
path: "supervisor-outlet",
name: "supervisorOutlet",
component: () => import("@/views/performance/view/supervisorOutlet/index.vue"),
meta: {
title: "门店业绩",
},
},
], ],
}, },
]; ];
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
:ref="`tab-${index}`" :ref="`tab-${index}`"
class="tab-item" class="tab-item"
:class="{ 'is-active': activeKey === item.key }" :class="{ 'is-active': activeKey === item.key }"
:style="item.style"
@click="onTap(item, index)"> @click="onTap(item, index)">
<SvgIcon v-if="shouldRenderSvgIcon(item)" <SvgIcon v-if="shouldRenderSvgIcon(item)"
class="icon svg-icon-image" class="icon svg-icon-image"
...@@ -99,12 +100,12 @@ export default { ...@@ -99,12 +100,12 @@ export default {
}, },
methods: { methods: {
syncFromProps() { syncFromProps() {
let nextActiveKey = this.getValidActiveKey({ const nextActiveKey = this.getValidActiveKey({
normalizedList: this.normalizedList, normalizedList: this.normalizedList,
value: this.value, value: this.value,
prevActiveKey: this.activeKey, prevActiveKey: this.activeKey,
}); });
let nextActiveIndex = this.getIndexByKey(this.normalizedList, nextActiveKey); const nextActiveIndex = this.getIndexByKey(this.normalizedList, nextActiveKey);
this.activeKey = nextActiveKey; this.activeKey = nextActiveKey;
this.activeIndex = nextActiveIndex; this.activeIndex = nextActiveIndex;
...@@ -118,59 +119,26 @@ export default { ...@@ -118,59 +119,26 @@ export default {
if (!Array.isArray(list)) { if (!Array.isArray(list)) {
return []; return [];
} }
return list.map((raw) => {
return list const item = raw || {};
.map((raw) => { return {
let item = raw || {}; icon: item.icon || "",
let labelObject = item.label && typeof item.label === "object" ? item.label : null; key: String(item.key),
let key label: item.label,
= item.key != null ? item.key : item.value != null ? item.value : item.id != null ? item.id : labelObject ? (labelObject.key != null ? labelObject.key : labelObject.value) : undefined; showIconOnActiveOnly: Boolean(item.showIconOnActiveOnly),
let label = labelObject style: item.style || {},
? labelObject.text != null };
? labelObject.text });
: labelObject.name != null
? labelObject.name
: labelObject.label != null
? labelObject.label
: labelObject.value != null
? labelObject.value
: labelObject.key
: item.label != null
? item.label
: item.text != null
? item.text
: item.name != null
? item.name
: "";
return {
icon: item.icon || "",
key,
label: label == null ? "" : String(label),
showIconOnActiveOnly: Boolean(item.showIconOnActiveOnly),
};
})
.filter((item) => {
return item.key !== undefined && item.key !== null;
})
.map((item) => {
return {
icon: item.icon,
key: String(item.key),
label: item.label,
showIconOnActiveOnly: item.showIconOnActiveOnly,
};
});
}, },
getValidActiveKey(options) { getValidActiveKey(options) {
let normalizedList = options.normalizedList || []; const normalizedList = options.normalizedList || [];
let value = options.value; const value = options.value;
let prevActiveKey = options.prevActiveKey; const prevActiveKey = options.prevActiveKey;
let keys = normalizedList.map((item) => { const keys = normalizedList.map((item) => {
return item.key; return item.key;
}); });
let nextValue = value === undefined || value === null ? null : String(value); const nextValue = value === undefined || value === null ? null : String(value);
let prevValue = prevActiveKey === undefined || prevActiveKey === null ? null : String(prevActiveKey); const prevValue = prevActiveKey === undefined || prevActiveKey === null ? null : String(prevActiveKey);
if (nextValue !== null && keys.includes(nextValue)) { if (nextValue !== null && keys.includes(nextValue)) {
return nextValue; return nextValue;
...@@ -186,8 +154,8 @@ export default { ...@@ -186,8 +154,8 @@ export default {
return 0; return 0;
} }
let targetKey = String(key); const targetKey = String(key);
for (let i = 0; i < normalizedList.length; i += 1) { for (const i = 0; i < normalizedList.length; i += 1) {
if (normalizedList[i].key === targetKey) { if (normalizedList[i].key === targetKey) {
return i; return i;
} }
...@@ -196,7 +164,7 @@ export default { ...@@ -196,7 +164,7 @@ export default {
return 0; return 0;
}, },
onTap(item, index) { onTap(item, index) {
let nextKey = item && item.key != null ? String(item.key) : null; const nextKey = item && item.key != null ? String(item.key) : null;
if (!nextKey || nextKey === this.activeKey) { if (!nextKey || nextKey === this.activeKey) {
return; return;
} }
...@@ -239,7 +207,7 @@ export default { ...@@ -239,7 +207,7 @@ export default {
return; return;
} }
let tabEl = this.getTabElement(this.activeIndex); const tabEl = this.getTabElement(this.activeIndex);
if (!tabEl) { if (!tabEl) {
return; return;
} }
...@@ -252,15 +220,15 @@ export default { ...@@ -252,15 +220,15 @@ export default {
return; return;
} }
let wrapperEl = this.$refs.wrapper; const wrapperEl = this.$refs.wrapper;
let tabEl = this.getTabElement(this.activeIndex); const tabEl = this.getTabElement(this.activeIndex);
if (!wrapperEl || !tabEl) { if (!wrapperEl || !tabEl) {
return; return;
} }
let targetScrollLeft = tabEl.offsetLeft - (wrapperEl.clientWidth - tabEl.offsetWidth) / 2; const targetScrollLeft = tabEl.offsetLeft - (wrapperEl.clientWidth - tabEl.offsetWidth) / 2;
let maxScrollLeft = Math.max(wrapperEl.scrollWidth - wrapperEl.clientWidth, 0); const maxScrollLeft = Math.max(wrapperEl.scrollWidth - wrapperEl.clientWidth, 0);
let nextScrollLeft = Math.max(0, Math.min(targetScrollLeft, maxScrollLeft)); const nextScrollLeft = Math.max(0, Math.min(targetScrollLeft, maxScrollLeft));
wrapperEl.scrollTo({ wrapperEl.scrollTo({
left: nextScrollLeft, left: nextScrollLeft,
...@@ -268,7 +236,7 @@ export default { ...@@ -268,7 +236,7 @@ export default {
}); });
}, },
getTabElement(index) { getTabElement(index) {
let ref = this.$refs["tab-" + index]; const ref = this.$refs["tab-" + index];
return Array.isArray(ref) ? ref[0] : ref; return Array.isArray(ref) ? ref[0] : ref;
}, },
bindResizeObserver() { bindResizeObserver() {
...@@ -276,7 +244,7 @@ export default { ...@@ -276,7 +244,7 @@ export default {
return; return;
} }
let tabsInner = this.$refs.tabsInner; const tabsInner = this.$refs.tabsInner;
if (!tabsInner) { if (!tabsInner) {
return; return;
} }
...@@ -313,8 +281,8 @@ export default { ...@@ -313,8 +281,8 @@ export default {
display: inline-flex; display: inline-flex;
align-items: center; align-items: center;
min-width: 100%; min-width: 100%;
padding: 3px 0;
width: max-content; width: max-content;
padding: 3px;
box-sizing: border-box; box-sizing: border-box;
border-radius: 24px; border-radius: 24px;
overflow: hidden; overflow: hidden;
...@@ -362,7 +330,7 @@ export default { ...@@ -362,7 +330,7 @@ export default {
.tab-item.is-active { .tab-item.is-active {
color: #ffffff; color: #ffffff;
background: transparent; background: transparent !important;
} }
.tab-item + .tab-item { .tab-item + .tab-item {
......
<template>
<div class="statistics-item-wrapper"
:class="{
'is-tap': beTap,
'is-expand': expanded,
}"
@click="handleTapItem">
<div class="title-wrapper">
<div class="title-label-wrapper text-hide">
<div class="main-label text-hide">
張三
</div>
<div class="sub-label text-hide">
北京博福汽车4S店北京博福汽车4S店北京博福汽车4S店北京博福汽车4S店北京博福汽车4S店北京博福汽车4S店
</div>
</div>
<div class="title-info-wrapper">
<slot name="title-info">
</slot>
<slot name="title-info-icon">
<van-icon color="#000000E5"
name="arrow"
:size="16" />
</slot>
</div>
</div>
<van-row class="container" gutter="4">
<van-col v-for="item in defaultSchema"
:key="item.name"
class="van-col-wrapper"
:span="item.col">
<div class="item-wrapper" :style="item.style">
<div class="label text-hide ">
{{ item.label }}
</div>
<div class="value text-hide ">
{{ item.name }}
</div>
</div>
</van-col>
<van-col v-if="showMoreToggle" span="24">
<div class="more-collapse"
:style="{
height: expanded ? (`${moreHeight}px`) : '0px',
}">
<div class="more-inner">
<van-row gutter="4">
<van-col v-for="item in moreSchema"
:key="item.name"
class="van-col-wrapper"
:span="item.col">
<div class="item-wrapper" :style="item.style">
<div class="label text-hide ">
{{ item.label }}
</div>
<div class="value text-hide ">
{{ item.name }}
</div>
</div>
</van-col>
</van-row>
</div>
</div>
<!-- 用来记录高度 -->
<div class="more-measure">
<div ref="moreMeasureInner" class="more-inner">
<van-row gutter="4">
<van-col v-for="item in moreSchema"
:key="item.name"
class="van-col-wrapper"
:span="item.col">
<div class="item-wrapper" :style="item.style">
<div class="label text-hide ">
{{ item.label }}
</div>
<div class="value text-hide ">
{{ item.name }}
</div>
</div>
</van-col>
</van-row>
</div>
</div>
</van-col>
</van-row>
<div v-if="showMoreToggle"
class="toggle-wrapper"
@click.stop="onToggleMore">
{{ expanded ? '收起2项售后成交指标' : '已隐藏2项售后成交指标' }}
</div>
</div>
</template>
<script>
import { Col, Divider, Icon, Row } from "vant";
export default {
name: "",
components: {
[Col.name]: Col,
[Row.name]: Row,
[Divider.name]: Divider,
[Icon.name]: Icon,
},
props: {
schema: {
type: Array,
default: () => ([]),
},
beTap: {
type: Boolean,
default: true,
},
hasMore: {
type: Boolean,
default: true,
},
},
data() {
return {
expanded: false,
moreHeight: 0,
};
},
computed: {
defaultSchema() {
return this.schema.filter(item => !item.isMore);
},
moreSchema() {
return this.schema.filter(item => item.isMore);
},
showMoreToggle() {
return this.hasMore && this.moreSchema.length > 0;
},
},
watch: {
schema: {
handler() {
this.updateMoreHeight();
},
deep: true,
immediate: true,
},
},
mounted() {
this.updateMoreHeight();
},
methods: {
handleTapItem() {
this.$emit("tap");
},
onToggleMore() {
if (!this.showMoreToggle) {
return;
}
this.updateMoreHeight();
this.expanded = !this.expanded;
},
updateMoreHeight() {
this.$nextTick(() => {
const moreMeasureInner = this.$refs.moreMeasureInner;
this.moreHeight = moreMeasureInner ? moreMeasureInner.clientHeight : 0;
});
},
},
};
</script>
<style scoped lang="scss">
.text-hide {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.statistics-item-wrapper {
background-color: white;
padding: 8px;
box-sizing: border-box;
overflow: hidden;
border-radius: 12px;
position: relative;
transition: background 250ms cubic-bezier(0.2, 0.8, 0.2, 1);
padding-bottom: 14px;
&.is-expand {
padding-bottom: 42px;
}
&.is-tap {
&:active {
background: rgb(252, 252, 252);
}
}
> .title-wrapper {
display: flex;
align-items: center;
padding: 8px 16px;
border-bottom: 1px solid #eeeef0;
overflow: hidden;
.title-label-wrapper {
flex-shrink: 0;
width: 45%;
font-weight: 500;
font-size: 14px;
line-height: 22px;
color: rgba(0, 0, 0, 0.9);
.sub-label {
font-weight: 400;
font-size: 10px;
line-height: 16px;
color: #00000066;
}
}
.title-info-wrapper {
flex: 1;
flex-shrink: 0;
display: flex;
align-items: center;
justify-content: flex-end;
overflow: hidden;
margin-left: 16px;
.sub-label {
font-weight: 400;
font-size: 14px;
line-height: 22px;
text-align: right;
flex: 1;
flex-shrink: 0;
color: rgba(0, 0, 0, 0.4);
}
.icon {
flex-shrink: 0;
width: 16px;
height: 16px;
margin-left: 8px;
display: flex;
align-items: center;
justify-content: flex-end;
}
}
}
.container {
overflow: hidden;
box-sizing: border-box;
border-radius: 8px;
margin-top: 8px;
}
}
.van-col-wrapper {
overflow: hidden;
.item-wrapper {
background: #f8f8f8;
padding: 8px 12px;
overflow: hidden;
box-sizing: border-box;
.label {
font-weight: 400;
font-size: 12px;
line-height: 20px;
color: rgba(0, 0, 0, 0.26);
}
.value {
margin-top: 4px;
font-family: D-numberNor;
font-weight: 500;
font-size: 16px;
line-height: 20px;
color: var(--themeColor);
}
}
}
.toggle-wrapper {
background-image: linear-gradient(top, rgba(255, 255, 255, 0.2) 15%, rgba(255, 255, 255, 0.6) 30%, #ffffff 100%);
padding: 6px 0;
position: absolute;
left: 0;
bottom: 4px;
width: 100%;
text-align: center;
font-size: 12px;
line-height: 20px;
color: #00000066;
}
.more-collapse {
overflow: hidden;
transition: height 300ms ease;
}
.more-measure {
position: absolute;
left: 0;
top: 0;
width: 100%;
visibility: hidden;
z-index: -1;
pointer-events: none;
}
</style>
export const brandTypeList = [
{
showIconOnActiveOnly: true,
icon: "brand-icon|svg",
key: "0",
label: "问界鸿蒙-延保权益",
},
{
showIconOnActiveOnly: true,
icon: "brand-icon|svg",
key: "1",
label: "通用品牌-延保权益",
},
];
export const brandTypeList = [
{
showIconOnActiveOnly: true,
icon: "brand-icon|svg",
key: "0",
label: "问界鸿蒙-延保权益",
style: {
backgroundColor: "#fff",
},
},
{
showIconOnActiveOnly: true,
icon: "brand-icon|svg",
key: "1",
label: "通用品牌-延保权益",
style: {
backgroundColor: "#fff",
},
},
];
export const staticInfoList = [
{
key: "",
background: "linear-gradient(90deg, #42CCCF 0%, #36D9A5 100%)",
label: "达标门店数",
},
{
key: "",
background: "linear-gradient(90deg, #7552FF 0%, #977DFF 100%)",
label: "需关注门店数",
},
{
key: "",
background: "linear-gradient(90deg, #3D76FC 0%, #4DA6FF 100%)",
label: "预警门店数",
},
];
export const supervisorSchemaList = [
{
name: "brandType",
label: "总产值",
col: 8,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "交付数",
col: 8,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "触客数",
col: 8,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "整车延保",
col: 6,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "安心包",
col: 6,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "电池",
col: 6,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "轮胎",
col: 6,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "整车延保售后成交/总成交",
col: 12,
isMore: true,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "安心包售后成交/总成交",
col: 12,
isMore: true,
style: "margin-bottom: 4px",
},
{
name: "brandType",
label: "电池售后成交/总成交",
col: 12,
isMore: true,
},
{
name: "brandType",
label: "轮胎售后成交/总成交",
col: 12,
isMore: true,
},
];
<template> <template>
<div class="page-container" :style="{ backgroundImage: `url(${pageBgUrl})` }"> <div class="page-container" :style="{ backgroundImage: `url(${pageBgUrl})` }">
<van-tabs> <van-pull-refresh v-model="list.loading"
<van-tab title="督导业绩" /> @refresh="handleResetList">
<van-tab title="门店业绩" /> <van-tabs>
</van-tabs> <van-tab title="督导业绩" />
<div class="filter-wrapper"> <van-tab title="门店业绩" />
<BrandTabs :list="options.brandTypeList" /> </van-tabs>
<div class="filter-wrapper">
<div class="brand-filter">
<BrandTabs :list="options.brandTypeList" />
</div>
<div class="date-filter">
<DateSearch show-date-type-filter
:is-sticky="false"
:tab-selected="3"
@search="search">
</DateSearch>
</div>
<div class="static-wrapper">
<StaticInfo :list="options.staticInfoList" />
</div>
<div class="search-wrapper">
<SearchInput />
</div>
</div>
<div class="list-wrapper">
<div class="title-wrapper">
督导列表
</div>
<div class="container-wrapper">
<StatisticsItem v-for="(item, index) in 10"
:key="index"
class="statistics-item"
:schema="options.supervisorSchemaList"
@tap="handleTapItem" />
</div>
</div>
</van-pull-refresh>
</div>
</div> </div>
</template> </template>
<script> <script>
import DateSearch from "@/components/dateSearch/dateSearch.vue";
import SearchInput from "@/components/searchBar/index.vue";
import StaticInfo from "@/components/staticInfo/index.vue";
import StatisticsItem from "@/views/performance/components/statisticsItem/statisticsItem.vue";
import BrandTabs from "../components/brandTabs/index.vue"; import BrandTabs from "../components/brandTabs/index.vue";
import { brandTypeList } from "./data"; import { brandTypeList, staticInfoList, supervisorSchemaList } from "./index.data";
export default { export default {
name: "PerformanceOverview", name: "PerformanceOverview",
components: { components: {
BrandTabs, BrandTabs,
DateSearch,
StaticInfo,
SearchInput,
StatisticsItem,
}, },
data() { data() {
return { return {
pageBgUrl: "https://img02.glsx.com.cn/weapp/resource/supervise-wecom/page-bg.png", pageBgUrl: "https://img02.glsx.com.cn/weapp/resource/supervise-wecom/page-bg.png",
options: { options: {
brandTypeList, brandTypeList,
staticInfoList,
supervisorSchemaList,
},
list: {
loading: false,
data: [],
}, },
}; };
}, },
methods: {
handleTapItem() {
this.$router.push({
name: "supervisorOutlet",
});
},
handleResetList() {
this.list.loading = true;
setTimeout(() => {
this.list.loading = false;
}, 3000);
},
search() {},
},
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.page-container { .page-container {
height: 100%;
background-position: 0 0; background-position: 0 0;
background-size: 100% 240px; background-size: 100% 240px;
background-repeat: no-repeat; background-repeat: no-repeat;
height: 100%; background-color: #f2f3f7;
padding-top: 12px; box-sizing: border-box;
overflow: hidden;
.page-header {
display: flex;
align-items: center;
padding: 0 12px 12px;
}
.page-title { ::v-deep .van-pull-refresh {
color: #3975c6; height: 100%;
font-size: 16px; overflow: auto !important;
font-weight: 600; box-sizing: border-box;
line-height: 20px;
margin-left: 8px;
} }
::v-deep .van-tabs { ::v-deep .van-tabs {
...@@ -80,5 +134,49 @@ export default { ...@@ -80,5 +134,49 @@ export default {
width: 18px; width: 18px;
} }
} }
.filter-wrapper {
padding: 0 12px;
.brand-filter {
padding: 6px 0;
}
.date-filter {
padding: 8px 0;
}
.static-wrapper {
padding: 8px 0;
::v-deep .static-info {
padding: 0;
}
}
.search-wrapper {
padding: 8px 0;
.search-bar-wrapper {
padding: 0;
::v-deep .van-search {
padding: 0;
}
}
}
}
.list-wrapper {
padding: 0 12px 20px;
> .title-wrapper {
font-weight: 400;
font-size: 14px;
line-height: 14px;
color: #000000e5;
padding: 8px 0;
}
.container-wrapper {
margin-top: 4px;
.statistics-item {
margin-top: 8px;
&:first-child {
margin-top: 0;
}
}
}
}
} }
</style> </style>
<template>
<div class="page-container" :style="{ backgroundImage: `url(${pageBgUrl})` }">
<van-pull-refresh v-model="list.loading"
@refresh="handleResetList">
<div class="filter-wrapper">
<div class="brand-filter">
<BrandTabs :list="options.brandTypeList" />
</div>
<div class="date-filter">
<DateSearch show-date-type-filter
:is-sticky="false"
:tab-selected="3"
@search="search">
</DateSearch>
</div>
<div class="static-wrapper">
<StaticInfo :list="options.staticInfoList" />
</div>
<div class="search-wrapper">
<SearchInput />
</div>
</div>
<div class="list-wrapper">
<div class="title-wrapper">
督导 - 门店列表
</div>
<div class="container-wrapper">
<StatisticsItem v-for="(item, index) in 10"
:key="index"
class="statistics-item"
:schema="options.supervisorSchemaList"
@tap="handleTapItem" />
</div>
</div>
</van-pull-refresh>
</div>
</template>
<script>
import DateSearch from "@/components/dateSearch/dateSearch.vue";
import SearchInput from "@/components/searchBar/index.vue";
import StaticInfo from "@/components/staticInfo/index.vue";
import StatisticsItem from "@/views/performance/components/statisticsItem/statisticsItem.vue";
import BrandTabs from "../../components/brandTabs/index.vue";
import { brandTypeList, staticInfoList, supervisorSchemaList } from "../index.data";
export default {
name: "PerformanceOverview",
components: {
BrandTabs,
DateSearch,
StaticInfo,
SearchInput,
StatisticsItem,
},
data() {
return {
pageBgUrl: "https://img02.glsx.com.cn/weapp/resource/supervise-wecom/page-bg.png",
options: {
brandTypeList,
staticInfoList,
supervisorSchemaList,
},
list: {
loading: false,
data: [],
},
};
},
methods: {
handleTapItem() {
this.$router.push({
name: "supervisorOutlet",
});
},
handleResetList() {
this.list.loading = true;
setTimeout(() => {
this.list.loading = false;
}, 3000);
},
search() {},
},
};
</script>
<style lang="scss" scoped>
.page-container {
height: 100%;
background-position: 0 0;
background-size: 100% 240px;
background-repeat: no-repeat;
background-color: #f2f3f7;
box-sizing: border-box;
overflow: hidden;
::v-deep .van-pull-refresh {
height: 100%;
overflow: auto !important;
box-sizing: border-box;
}
::v-deep .van-tabs {
.van-tab {
flex: none;
font-weight: 500;
line-height: 20px;
margin-left: 16px;
&:first-child {
margin-left: 0;
}
&__text {
}
&--active {
color: var(--themeColor);
}
}
&__wrap {
background-color: transparent;
padding: 0 12px;
}
&__nav {
background-color: transparent;
}
&__line {
bottom: 18px;
width: 18px;
}
}
.filter-wrapper {
padding: 0 12px;
.brand-filter {
padding: 6px 0;
}
.date-filter {
padding: 8px 0;
}
.static-wrapper {
padding: 8px 0;
::v-deep .static-info {
padding: 0;
}
}
.search-wrapper {
padding: 8px 0;
.search-bar-wrapper {
padding: 0;
::v-deep .van-search {
padding: 0;
}
}
}
}
.list-wrapper {
padding: 0 12px 20px;
> .title-wrapper {
font-weight: 400;
font-size: 14px;
line-height: 14px;
color: #000000e5;
padding: 8px 0;
}
.container-wrapper {
margin-top: 4px;
.statistics-item {
margin-top: 8px;
&:first-child {
margin-top: 0;
}
}
}
}
}
</style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!