diff --git a/pages/goods/payment/orderPayment.vue b/pages/goods/payment/orderPayment.vue index 655d712..17d70eb 100644 --- a/pages/goods/payment/orderPayment.vue +++ b/pages/goods/payment/orderPayment.vue @@ -81,6 +81,7 @@ import uniTh from "@/uni_modules/uni-table/components/uni-th/uni-th" import uniTd from "@/uni_modules/uni-table/components/uni-td/uni-td" import uniPagination from "@/uni_modules/uni-pagination/components/uni-pagination/uni-pagination" import whpop from '../../login/components/WhPopup' +import { checkLogin } from '@/core/app' export default { name: "payment", @@ -145,6 +146,13 @@ export default { } } }, + onShow() { + // 判断是否已登录 + if(!checkLogin()){ + this.$toast('登录失效了,请重新登录系统') + setTimeout(this.jumpLogin,2000) + } + }, onLoad(options) { this.selectedIndexs = [] this.batchcode = options.batchcode @@ -152,6 +160,9 @@ export default { this.getTableList() }, methods: { + jumpLogin() { + this.$navTo('pages/login/index') + }, // 切换支付类型 changePayType(val) { this.payType = val diff --git a/pages/goods/payment/verifyPayment.vue b/pages/goods/payment/verifyPayment.vue index 700b783..c5240f6 100644 --- a/pages/goods/payment/verifyPayment.vue +++ b/pages/goods/payment/verifyPayment.vue @@ -45,6 +45,7 @@ import uniTh from "@/uni_modules/uni-table/components/uni-th/uni-th" import uniTd from "@/uni_modules/uni-table/components/uni-td/uni-td" import uniPagination from "@/uni_modules/uni-pagination/components/uni-pagination/uni-pagination" + import { checkLogin } from '@/core/app' export default { name: "payment", @@ -79,11 +80,21 @@ pay_image: '', // 显示图片 } }, + onShow() { + // 判断是否已登录 + if(!checkLogin()){ + this.$toast('登录失效了,请重新登录系统') + setTimeout(this.jumpLogin,2000) + } + }, onLoad() { this.selectedIndexs = [] this.getTableList() }, methods: { + jumpLogin() { + this.$navTo('pages/login/index') + }, // 切换支付类型 changePayType(val) { this.payType = val