解决非小程序运行环境,不能调用wx.login()生成code
参考:
https://www.cnblogs.com/du-jun/p/12720945.html
https://www.cnblogs.com/1zero1/p/13470610.html
1.先调用接口
https://mp.weixin.qq.com/debug/cgi-bin/webdebugger/refreshticket?os=darwin&clientversion=1062402040
生成newticket
2.调用接口
https://servicewechat.com/wxa-dev-logic/jslogin
获取生产的code
3.调用小程序登录接口登录,获取响应中的token