u
This commit is contained in:
parent
173e28618d
commit
abd64f9b2b
2
index.js
2
index.js
@ -403,7 +403,7 @@ export default {
|
||||
showToast({ tool, type, image, title, duration = 2000, ...rest }) {
|
||||
const pageNow = this?.$store ? this // 对于组件内定义的 i18nText,要使用 this 来获得组建内的 i18nText,而不是 getCurrentPages[...] 去访问全局页面的 i18nText。
|
||||
: getCurrentPages()[getCurrentPages().length - 1]
|
||||
if (tool === 'uni' || !(pageNow.$refs && pageNow.$refs.toast)) {
|
||||
if (tool === 'uni' || ! pageNow?.$refs?.toast) {
|
||||
// #ifdef APP-PLUS
|
||||
uni.showToast({ icon: 'none', title, duration, ...rest })
|
||||
// #endif
|
||||
|
Loading…
Reference in New Issue
Block a user