我有一個看起來像這樣的物件
{
name: 'abc',
value: BigNumber('125'),
other: {
otherValue: BigNumber('252'),
}
}
它的貓鼬模式是:
{
name: { type: String, required: true },,
value: { type: String, required: true },,
other: {
otherValue: { type: String, required: true },,
}
}
有沒有辦法在存盤物件之前自動決議value和otherValue字串(通過呼叫.toString()),或者唯一的方法是手動完成?
uj5u.com熱心網友回復:
Mongoose 允許
轉載請註明出處,本文鏈接:https://www.uj5u.com/yidong/414590.html
標籤:
下一篇:無法連接到資料庫。重試
