左上角返回按钮,以及wx.navigateBack不生效

小程序 文章 2022-03-02 17:40 1488 0 全屏看文

AI助手支持GPT4.0

左上角返回按钮,以及wx.navigateBack不生效The back button in the upper left corner, and wx.navigateBack does not take effect

左上角返回按钮,以及wx.navigateBack不生效
框架类型 问题类型 API/组件名称 终端类型 微信版本 基础库版本
小程序 Bug wx.navigateTo 微信iOS客户端 8.0.18 2.19.4

当前页是个二级页面,调用        wx.navigateTo({        url: url,        success: () => {          this.closePopup();        }      });后,进入三级页面,然后返回二级页面后,再次点击左上角返回按钮或者调用wx.navigateBack()后不生效,无法返回一级页面。必现。 ios 15.3.1,以及mac端开发工具都会出现

Framework type problem type API / component name terminal type wechat version basic library version applet bug Wx Navigateto wechat IOS client 8.0.18 2.19.4 the current page is a secondary page, call Wx navigateTo({ url: url, success: () => { this.closePopup(); } }); After entering the third level page, and then returning to the second level page, click the return button in the upper left corner again or call Wx Navigateback() does not take effect and cannot return to the first level page. Must be present. IOS 15.3.1 and MAC side development tools will show code snippets Wx navigateTo({ url: url, success: () => { this.closePopup(); } });

回答:

社区技术运营专员-horanzhou:

请具体描述问题出现的流程,并提供能复现问题的简单代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)。

brave:

提供下可以复现问题的代码片段:https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html

MMMalik:

this.closePopup关闭了当前页面的一个弹窗,使用到了setData方法

-EOF-

AI助手支持GPT4.0