小编Lak*_*h22的帖子

使用Flutter将对象添加到Cloud Firestore

我想在Flutter应用中向Google Cloud Firestore添加对象,如下所示:

消防站图像

我已经做了一个Reply类:

class Reply {
Reply(this.replyName, this.replyText, this.replyVotes);
  final String replyName;
  final String replyText;
  final String replyVotes;

  String getName() {
    return replyName;
  }

  String getText() {
    return replyText;
  }

  String getVotes() {
    return replyVotes;
  }
}
Run Code Online (Sandbox Code Playgroud)

如何将Reply对象添加到Cloud Firestore?

编辑: 只是为了澄清,我想创建一个具有Object其中包含字段的数据类型的字段:Reply Object Image

dart firebase flutter google-cloud-firestore

7
推荐指数
2
解决办法
6647
查看次数

标签 统计

dart ×1

firebase ×1

flutter ×1

google-cloud-firestore ×1