Browse Source

fix: 🧩 新增敬请期待图

pull/10/head
liyongle 3 years ago
parent
commit
0d1da49249
  1. 7
      src/assets/images/empty_big_tra.svg
  2. 26
      src/views/Activity/Activity.vue
  3. 2
      src/views/Activity/ActivityItem.vue
  4. 11
      src/views/Art/Art.vue
  5. 14
      src/views/Member/Member.vue
  6. 14
      src/views/Service/Service.vue
  7. 2
      src/views/Traffic/Traffic.vue

7
src/assets/images/empty_big_tra.svg

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 13 KiB

26
src/views/Activity/Activity.vue

@ -19,12 +19,19 @@
enter-active-class="animate__faster animate__animated animate__fadeInRight"
leave-active-class="animate__animated animate__fadeOutDown"
>
<ScrollView ref="actScroll" :list="actList" :refresh-delay="200" :scroll-x="true" :scrollbar="true" class="act-scroll">
<ScrollView
v-if="actList.length"
ref="actScroll"
:list="actList"
:refresh-delay="200"
:scroll-x="true"
:scrollbar="true"
class="act-scroll"
>
<ul class="act-list">
<ActivityItem v-for="(item, index) in actList" :key="index" :act-info="item" @click="clickItem"></ActivityItem>
</ul>
</ScrollView>
<!-- -->
<!-- <swiper
v-if="showList"
class="act-scroll"
@ -57,6 +64,7 @@
</swiper-slide>
</swiper> -->
</transition>
<img v-if="showEmpty" class="tra" src="@/assets/images/empty_big_tra.svg" alt="" />
<activityDetail v-if="showDetail" :act-info="currentItem" @close="showDetail = false"></activityDetail>
</div>
</template>
@ -123,6 +131,8 @@ function handleSwitch(index: number) {
// list[index].fun()
}
//
const showEmpty = ref(false)
function getData(type: 'mall' | 'shop') {
const fun = type === 'mall' ? getMallActivity() : getShopActivity()
fun.then(res => {
@ -130,6 +140,9 @@ function getData(type: 'mall' | 'shop') {
for (let t = 0; t < res.data.length; t++) {
actList.value.push({ id: res.data[t].id, ...res.data[t].content })
}
if (!res.data.length) {
showEmpty.value = true
}
showList.value = true
})
}
@ -181,4 +194,13 @@ getData('mall')
}
}
}
.tra {
position: fixed;
top: 268px;
left: 56px;
width: 1808px;
height: 576px;
border-radius: 16px;
}
</style>

2
src/views/Activity/ActivityItem.vue

@ -1,5 +1,5 @@
<template>
<div v-if="showThis" :key="actInfo.id" class="act-item animate__faster animate__animated animate__fadeInUp">
<div v-if="showThis" :key="actInfo.id" class="act-item">
<!-- 图片 -->
<div class="img-container" @click="clickActItem">
<img :style="{ backgroundImage: `url(${getBackGround()})` }" alt="" />

11
src/views/Art/Art.vue

@ -3,13 +3,14 @@
<div class="art-container">
<div class="name">艺术装置</div>
<div class="nameEn">ARTWORK</div>
<ScrollView class="myScroll" :list="artPlaceList" scroll-x scrollbar>
<ScrollView v-if="artPlaceList.length" class="myScroll" :list="artPlaceList" scroll-x scrollbar>
<div style="display: inline-block">
<div class="lists">
<ArtItem v-for="item in artPlaceList" :key="item.id" :art-info="item" />
</div>
</div>
</ScrollView>
<img v-else class="tra" src="@/assets/images/empty_big_tra.svg" alt="" />
</div>
</Transition>
</template>
@ -70,4 +71,12 @@ const { artPlaceList } = toRefs(store)
}
}
}
.tra {
position: fixed;
top: 268px;
left: 56px;
width: 1808px;
height: 576px;
border-radius: 16px;
}
</style>

14
src/views/Member/Member.vue

@ -32,6 +32,7 @@
</ul>
</ScrollView>
</transition>
<img v-if="switchIdx !== 0 && showEmpty" class="tra" src="@/assets/images/empty_big_tra.svg" alt="" />
<activityDetail v-if="showDetail" :act-info="currentItem" @close="showDetail = false"></activityDetail>
</div>
</template>
@ -93,8 +94,13 @@ function handleSwitch(index: number) {
}
}
//
const showEmpty = ref(false)
function getData() {
getMemberServices().then(res => {
if (!res.data.length) {
showEmpty.value = true
}
for (let t = 0; t < res.data.length; t++) {
const { name, nameEn, content, contentEn, file_code, point } = res.data[t].content
memberServiceList.value.push({
@ -159,4 +165,12 @@ getData()
}
}
}
.tra {
position: fixed;
top: 268px;
left: 56px;
width: 1808px;
height: 576px;
border-radius: 16px;
}
</style>

14
src/views/Service/Service.vue

@ -26,6 +26,7 @@
</div>
</ScrollView>
</transition>
<img v-if="switchIdx !== 1 && showEmpty" class="tra" src="@/assets/images/empty_big_tra.svg" alt="" />
<activityDetail v-if="showDetail" :act-info="currentItem" @close="showDetail = false"></activityDetail>
</div>
</template>
@ -82,8 +83,13 @@ function handleSwitch(index: number) {
}
}
//
const showEmpty = ref(false)
function getData() {
getServeList().then(res => {
if (!res.data.length) {
showEmpty.value = true
}
for (let t = 0; t < res.data.length; t++) {
const { name, nameEn, content, contentEn, file_code, logo_code, facilityCode } = res.data[t].content
serviceList.value.push({
@ -165,4 +171,12 @@ getData()
}
}
}
.tra {
position: fixed;
top: 268px;
left: 56px;
width: 1808px;
height: 576px;
border-radius: 16px;
}
</style>

2
src/views/Traffic/Traffic.vue

@ -11,7 +11,7 @@
/>
<Transition appear enter-active-class="animate__animated animate__fadeIn">
<PictureText v-if="isCurrent" :ac-list="mallIntro" :qr-list="[]" />
<img v-else class="tra" :src="traImg ? traImg : require('@/assets/images/empty_big.svg')" alt="" />
<img v-else class="tra" :src="traImg ? traImg : require('@/assets/images/empty_big_tra.svg')" alt="" />
</Transition>
</template>

Loading…
Cancel
Save