离子vue firebase存储在电容器iOS上getDownloadurl
我有一个使用Ionic 6 Vue 3创建的博客/帖子。 在帖子创建中,我们可以附加一个英制或附件文件 通过使用getDownloadurl函数调用收集项目
const url =等待GetDownloadurl(Ref(ref(recore,fileName))
这些存储在Firebase Collection上,可以使用Web轻松返回帖子中, 使用CAP SYNC iOS部署的所有日志记录之前,请通过iOS进行相同的例程 提取到自己的功能
async GetDownloadUrl(fileName, ContentId, type) {
console.log('attempting ',fileName,ContentId,type)
const url = await getDownloadURL(ref(storage, fileName))
console.log('Generated GET signed URL:');
console.log(url);
console.log('id',ContentId, 'and type ', type)
}
Web返回之后(调用子函数,然后稍后获取响应我获得异步/等待)将在我获得iOS iOS
attempting post/qv2Be2fBGcOzfSpW5jic/AugConnect22.png qv2Be2fBGcOzfSpW5jic HeroImg
main.js?ead5:187 Generated GET signed URL:
main.js?ead5:188 https://firebasestorage.googleapis.com/v0/b/dgsa-test.appspot.com/o/post%2Fo2QVuFVIIYIxlFn68c9y%2Fattachment%2FDaily%20Action%20Sheet.pdf?alt=media&token=xxxxxx-xxxx-xxxx-xxxx-xxxxxxxx
main.js?ead5:189 id o2QVuFVIIYIxlFn68c9y and type Attach
iOS返回上的URL后,将使用下载URL更新本地集合
⚡️ [log] - attempting post/pxpA2TaXas1uuAVrgFDq/attachment/understanding_muscle_protein_dynamics_technical_co.pdf pxpA2TaXas1uuAVrgFDq Attach
⚡️ [log] - attempting post/qL8sByCPSzRZtaEqTz2d/attachment/A-Virtual-Calendar-May_Jun_July-Expo.pdf qL8sByCPSzRZtaEqTz2d Attach
⚡️ [log] - attempting post/qv2Be2fBGcOzfSpW5jic/AugConnect22.png qv2Be2fBGcOzfSpW5jic HeroImg```
Any ideas or suggestions appreciated
I have a blog/post that is being created using Ionic 6 Vue 3.
On the post creation we can attach a HeroImage or Attachment File
These are stored on the Firebase Collection and can be returned easily on the post using the Web by Calling the Collection item using the GetDownloadURL function
const url = await getDownloadURL(ref(storage, fileName))
When I call the same routine via IOS having deployed using Cap Sync IOS all the logging I do before this is invoked but nothing is returned in the IOS logs
Having extracted to it's own function
async GetDownloadUrl(fileName, ContentId, type) {
console.log('attempting ',fileName,ContentId,type)
const url = await getDownloadURL(ref(storage, fileName))
console.log('Generated GET signed URL:');
console.log(url);
console.log('id',ContentId, 'and type ', type)
}
Web Returns (invokes the child function then gets the response later I get async/await) will update the local collection with download URLs once I get the URLs to resolve on IOS
attempting post/qv2Be2fBGcOzfSpW5jic/AugConnect22.png qv2Be2fBGcOzfSpW5jic HeroImg
main.js?ead5:187 Generated GET signed URL:
main.js?ead5:188 https://firebasestorage.googleapis.com/v0/b/dgsa-test.appspot.com/o/post%2Fo2QVuFVIIYIxlFn68c9y%2Fattachment%2FDaily%20Action%20Sheet.pdf?alt=media&token=xxxxxx-xxxx-xxxx-xxxx-xxxxxxxx
main.js?ead5:189 id o2QVuFVIIYIxlFn68c9y and type Attach
IOS Returns
⚡️ [log] - attempting post/pxpA2TaXas1uuAVrgFDq/attachment/understanding_muscle_protein_dynamics_technical_co.pdf pxpA2TaXas1uuAVrgFDq Attach
⚡️ [log] - attempting post/qL8sByCPSzRZtaEqTz2d/attachment/A-Virtual-Calendar-May_Jun_July-Expo.pdf qL8sByCPSzRZtaEqTz2d Attach
⚡️ [log] - attempting post/qv2Be2fBGcOzfSpW5jic/AugConnect22.png qv2Be2fBGcOzfSpW5jic HeroImg```
Any ideas or suggestions appreciated
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论