除用户名外,所有内容都存储在数据库中,但我不确定为什么,这是代码
nuser= (FirebaseAuth.getInstance().getCurrentUser().getDisplayName()).toString();
userListView.setOnItemClickListener(new AdapterView.OnItemClickListener()
{
@Override
public void onItemClick (AdapterView<?> adapterView, View view,int i, long l)
{
HashMap<String, String> dataMap = new HashMap<>();
dataMap.put("fromWhom",nuser);
dataMap.put("imageIdentifier", imageIdentifier);
dataMap.put("imageLink", uploadedImageLink);
dataMap.put("des", edit_description.getText().toString());
FirebaseDatabase.getInstance()
.getReference().child("app_users")
.child(UIDs.get(i)).child("received_posts")
.push().setValue(dataMap);
}
});