首页 > 微信 > 详细

关于单页面微信支付目录配置问题

时间:2019-07-05 22:13:59      阅读:253      评论:0      收藏:0      [点我收藏+]

1.1 解决android支付问题 在支付界面改变url

技术分享图片

1.2 初始化的时候改变首页url  这个解决ios的支付问题

技术分享图片

angular解决方案

constructor(private httpService: HttpService, private router: Router, private location: Location, private activatedRoute: ActivatedRoute ) { 
    // 替换url但不触发刷新,解决支付目录的问题
    this.router.events
      .subscribe((e: any) => {
        if (e instanceof NavigationEnd) {
          if (window.location.href.indexOf(?#) < 0) {
            const productId = localStorage.getItem("productId");
            window.history.pushState(null, null, `?#/index?id=${productId}`);
          };
        }
      })
  }

 

关于单页面微信支付目录配置问题

原文:https://www.cnblogs.com/ymh2013/p/11140782.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!