mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-22 05:56:45 +08:00
增加loading
This commit is contained in:
@@ -67,7 +67,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { NoticeBar, Field, Radio, Popup, RadioGroup } from 'vant'
|
import { NoticeBar, Field, Radio, Popup, RadioGroup, Toast } from 'vant'
|
||||||
import icon from '@/assets/images/jilu@3x.png'
|
import icon from '@/assets/images/jilu@3x.png'
|
||||||
import { getShopList, saveShareTrack } from '@/api/ebiz/product-store/product-store'
|
import { getShopList, saveShareTrack } from '@/api/ebiz/product-store/product-store'
|
||||||
|
|
||||||
@@ -130,7 +130,11 @@ export default {
|
|||||||
if (this.$route.query.sectionName) {
|
if (this.$route.query.sectionName) {
|
||||||
this.sectionName = this.$route.query.sectionName
|
this.sectionName = this.$route.query.sectionName
|
||||||
}
|
}
|
||||||
document.title = `${this.sectionName}简介`
|
if (this.sectionName !== '一站购齐') {
|
||||||
|
document.title = `${this.sectionName}简介`
|
||||||
|
} else {
|
||||||
|
document.title = this.sectionName
|
||||||
|
}
|
||||||
},
|
},
|
||||||
async mounted() {
|
async mounted() {
|
||||||
if (this.isWeixin) {
|
if (this.isWeixin) {
|
||||||
@@ -162,7 +166,25 @@ export default {
|
|||||||
if (!res) return
|
if (!res) return
|
||||||
if (res.result == '0') {
|
if (res.result == '0') {
|
||||||
if (res.content.redirect) {
|
if (res.content.redirect) {
|
||||||
this.redirectUrl = res.content.linkUrl
|
const toast = Toast.loading({
|
||||||
|
duration: 0, // 持续展示 toast
|
||||||
|
forbidClick: true,
|
||||||
|
icon: 'info-o',
|
||||||
|
message: '3秒后将跳转第三方平台'
|
||||||
|
})
|
||||||
|
|
||||||
|
let second = 3
|
||||||
|
const timer = setInterval(() => {
|
||||||
|
second--
|
||||||
|
if (second) {
|
||||||
|
toast.message = `${second}秒后将跳转第三方平台`
|
||||||
|
} else {
|
||||||
|
clearInterval(timer)
|
||||||
|
// 手动清除 Toast
|
||||||
|
Toast.clear()
|
||||||
|
this.redirectUrl = res.content.linkUrl
|
||||||
|
}
|
||||||
|
}, 1000)
|
||||||
} else {
|
} else {
|
||||||
if (res.content.rightBtnShow && !this.isWeixin) {
|
if (res.content.rightBtnShow && !this.isWeixin) {
|
||||||
// eslint-disable-next-line no-undef
|
// eslint-disable-next-line no-undef
|
||||||
|
|||||||
Reference in New Issue
Block a user