证书在有效期内,但是依旧出现这个错误
你好,小程序体验版提示request:fail -2:net::ERR_FAIL,什么问题呢?本地开发者工具一切正常,体验版获取API接口提示【request:fail -2:net::ERR_FAILED】,无法获取任何API数据,是什么问题呢
2021-04-24最后改成数组传进去就没有错误提示了,但是同时带来新的错误 代码: [代码]uplaodFile(files) {[代码][代码] [代码][代码]var[代码] [代码]that = [代码][代码]this[代码][代码];[代码][代码] [代码][代码]console.log([代码][代码]'upload files'[代码][代码], files)[代码][代码] [代码][代码]// 文件上传的函数,返回一个promise[代码][代码] [代码][代码]return[代码] [代码]new[代码] [代码]Promise((resolve, reject) => {[代码][代码] [代码][代码]setTimeout(() => {[代码][代码] [代码][代码]// reject('some error')[代码][代码] [代码][代码]var[代码] [代码]object = {};[代码][代码] [代码][代码]object[[代码][代码]'urls'[代码][代码]] = files.tempFilePaths[0][代码] [代码] [代码][代码]resolve({[代码][代码] [代码][代码]urls: [object][代码][代码] [代码][代码]});[代码][代码] [代码][代码]}, 1000)[代码][代码] [代码][代码]})[代码][代码]},[代码] 错误提示: [图片] 应该是个bug,很大的bug
WeUI Uploader 组件属性upload 里的Promise回调传的参数究竟是?copy https://developers.weixin.qq.com/miniprogram/dev/extended/weui/uploader.html 这里的代码 [代码]uplaodFile(files) {[代码][代码] [代码][代码]console.log([代码][代码]'upload files'[代码][代码], files)[代码][代码] [代码][代码]// 文件上传的函数,返回一个promise[代码][代码] [代码][代码]return[代码] [代码]new[代码] [代码]Promise((resolve, reject) => {[代码][代码] [代码][代码]setTimeout(() => {[代码][代码] [代码][代码]reject([代码][代码]'some error'[代码][代码])[代码][代码] [代码][代码]}, 1000)[代码][代码] [代码][代码]})[代码][代码] [代码][代码]},[代码]改成: [代码]uplaodFile(files) {[代码][代码] [代码][代码]console.log([代码][代码]'upload files'[代码][代码], files)[代码][代码] [代码][代码]// 文件上传的函数,返回一个promise[代码][代码] [代码][代码]return[代码] [代码]new[代码] [代码]Promise((resolve, reject) => {[代码][代码] [代码][代码]setTimeout(() => {[代码][代码] [代码][代码]var[代码] [代码]object = {};[代码][代码] [代码][代码]object[[代码][代码]'urls'[代码][代码]] = [files.tempFilePaths[0]][代码] [代码] [代码][代码]resolve({[代码][代码] [代码][代码]urls: [代码][代码]object[代码][代码] [代码][代码]});[代码][代码] [代码][代码]}, 1000)[代码][代码] [代码][代码]})[代码][代码] [代码][代码]},[代码] 文档提示的就是这样写,没错啊 [图片] 然后得到的错误是: [图片] "TypeError: json.urls.forEach is not a function at http://127.0.0.1:15186/appservice/libs/weui-miniprogram/uploader/uploader.js:237:51" 不知掉那里出错了。痛苦啊
2019-12-05问题是在编辑的时候就支持,换到真机调试的时候就不行了,这个好尴尬啊
map组件 markers ->iconPath 设置为.svg不显示map组件 markers ->iconPath 设置为.svg不显示:显示的是地图默认红色标记,
2019-12-03