|
|
@@ -1,5 +1,5 @@
|
|
|
<template>
|
|
|
- <div class="noVisit">
|
|
|
+ <div class="unCreateStore">
|
|
|
<div class="header">
|
|
|
<van-nav-bar class="navBar" title="建店" left-arrow @click-left="onClickLeft" />
|
|
|
</div>
|
|
|
@@ -8,11 +8,11 @@
|
|
|
<van-collapse-item v-for="(val, key, ind) in list" :key="ind" :name="key">
|
|
|
<template #title>
|
|
|
<div class="title">{{ key | storeType }}</div>
|
|
|
- <div class="num">{{ val.storeNum }}家</div>
|
|
|
+ <div class="num">{{ val ? val.length : 0 }}家</div>
|
|
|
</template>
|
|
|
<div class="itemContent">
|
|
|
- <template v-if="val.storeList && val.storeList.length">
|
|
|
- <div class="item" v-for="(item, index) in val.storeList" :key="index">
|
|
|
+ <template v-if="val && val.length">
|
|
|
+ <div class="item" v-for="(item, index) in val" :key="index">
|
|
|
<van-cell>
|
|
|
<div class="card">
|
|
|
<div></div>
|
|
|
@@ -96,7 +96,7 @@
|
|
|
">
|
|
|
{{ item.storeLabels.zysslNums }}
|
|
|
</p>
|
|
|
- <van-icon :name="ord" size="26" />
|
|
|
+ <van-icon :name="require('@/assets/ord.png')" size="26" />
|
|
|
</div>
|
|
|
</el-popover>
|
|
|
<el-popover
|
|
|
@@ -258,7 +258,7 @@
|
|
|
</van-cell>
|
|
|
</div>
|
|
|
</template>
|
|
|
- <template v-else><div style="text-align: center">暂无数据</div></template>
|
|
|
+ <van-empty description="暂无数据" v-else />
|
|
|
</div>
|
|
|
</van-collapse-item>
|
|
|
</van-collapse>
|
|
|
@@ -266,15 +266,15 @@
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
|
-import { selectUserStoreNoVisits } from '@/api/index';
|
|
|
-import { getPosition, getTicketFun } from '@/utils/TXApiFun';
|
|
|
+import { getStoreInfos } from '@/api/home';
|
|
|
import { mapState } from 'vuex';
|
|
|
import store from '@/store';
|
|
|
+import { getMonthCommon } from '@/utils';
|
|
|
export default {
|
|
|
name: 'unCreateStore',
|
|
|
computed: {
|
|
|
...mapState({
|
|
|
- activaTypeStore: (state) => state.user.activaTypeStore,
|
|
|
+ activaCreateTypeStore: (state) => state.user.activaCreateTypeStore,
|
|
|
}),
|
|
|
},
|
|
|
data() {
|
|
|
@@ -286,54 +286,38 @@ export default {
|
|
|
activatStoreVal: {}, //当前点击门店数据
|
|
|
visitRoutePath: '', //拜访页面路径
|
|
|
clickIsFlage: true,
|
|
|
+ timeData: '',
|
|
|
};
|
|
|
},
|
|
|
filters: {
|
|
|
storeType(value) {
|
|
|
let type = '';
|
|
|
- if (value == 'keKong') {
|
|
|
- type = '可控店';
|
|
|
- } else if (value == 'jinPai') {
|
|
|
- type = '金牌店';
|
|
|
- } else if (value == 'TuLiao') {
|
|
|
- type = '同城分销-涂料店';
|
|
|
- } else if (value == 'QiTa') {
|
|
|
- type = '同城分销-其他店';
|
|
|
+ if (value == 'keKongAbnormalNum') {
|
|
|
+ type = '可控店45天未结案列表';
|
|
|
+ } else if (value == 'jinPaiUnfinishedNum') {
|
|
|
+ type = '金牌店7天未完工列表';
|
|
|
+ } else if (value == 'jinPaiAbnormalNum') {
|
|
|
+ type = '金牌店30天未结案列表';
|
|
|
+ } else if (value == 'TuLiaoAbnormalNum') {
|
|
|
+ type = '涂料店7天未结案列表';
|
|
|
+ } else if (value == 'QiTaAbnormalNum') {
|
|
|
+ type = '其他店7天未结案列表';
|
|
|
}
|
|
|
return type;
|
|
|
},
|
|
|
},
|
|
|
created() {
|
|
|
- // 授权
|
|
|
- getTicketFun()
|
|
|
- .then(() => {
|
|
|
- // 获取定位
|
|
|
- getPosition()
|
|
|
- .then((res) => {
|
|
|
- let { TXisBD } = res;
|
|
|
- this.toastLoading(0, '加载中...', true);
|
|
|
- this.getList(TXisBD);
|
|
|
- })
|
|
|
- .catch((error) => {
|
|
|
- this.$dialog.alert({
|
|
|
- message: error,
|
|
|
- });
|
|
|
- });
|
|
|
- })
|
|
|
- .catch(() => {
|
|
|
- this.toastLoading().clear();
|
|
|
- });
|
|
|
- this.activeName = this.activaTypeStore || '';
|
|
|
+ this.timeData = getMonthCommon();
|
|
|
+ this.getList();
|
|
|
+ this.activeName = this.activaCreateTypeStore || '';
|
|
|
},
|
|
|
methods: {
|
|
|
collapseCange(value) {
|
|
|
- store.dispatch('setActivaTypeStore', value);
|
|
|
+ store.dispatch('activaCreateTypeStore', value);
|
|
|
},
|
|
|
- getList(TXisBD) {
|
|
|
- selectUserStoreNoVisits({
|
|
|
- lat: TXisBD.lat,
|
|
|
- lon: TXisBD.lon,
|
|
|
- })
|
|
|
+ getList() {
|
|
|
+ this.toastLoading(0, '加载中...', true);
|
|
|
+ getStoreInfos()
|
|
|
.then((res) => {
|
|
|
this.toastLoading().clear();
|
|
|
this.list = res.data;
|
|
|
@@ -356,7 +340,7 @@ export default {
|
|
|
};
|
|
|
</script>
|
|
|
<style lang="scss" scoped>
|
|
|
-.noVisit {
|
|
|
+.unCreateStore {
|
|
|
height: 100%;
|
|
|
width: 100%;
|
|
|
/* overflow-y: auto; */
|
|
|
@@ -439,9 +423,9 @@ export default {
|
|
|
}
|
|
|
</style>
|
|
|
<style lang="scss">
|
|
|
-.noVisit {
|
|
|
+.unCreateStore {
|
|
|
.van-cell__title {
|
|
|
- font-size: 15px;
|
|
|
+ font-size: 16px;
|
|
|
font-weight: bold;
|
|
|
color: #333;
|
|
|
display: flex;
|