我想使用对象来组合管理员,但我不知道。这是架构和代码
yourView.didSelectCallback = { [weak self] in
guard let weakSelf = self else {return}
let vc = UIStoryboard.init(name: "ProductListing", bundle: Bundle.main).instantiateViewController(withIdentifier: "ProductListingViewController") as? ProductListingViewController
weakSelf.navigationController?.pushViewController(vc!, animated: true)}
}
保存功能:
UserSchema = new mongoose.Schema({
name: { type:String },
owner : {
Admin : mongoose.Schema.Types.ObjectId
}
});
当我检查名称已保存但owner.Admin未保存时。
答案 0 :(得分:0)
保存之前,您应标记为已修改的嵌套对象
.carousel {
scroll-snap-type: x mandatory;
}