mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-20 10:38:09 +08:00
Update mongodb
This commit is contained in:
@@ -472,7 +472,16 @@ namespace SqlSugar.MongoDb
|
||||
}
|
||||
return dic;
|
||||
}
|
||||
|
||||
internal static BsonValue GetBsonValue(bool isMember, BsonValue field,bool isId)
|
||||
{
|
||||
if (!isMember && isId)
|
||||
{
|
||||
return ObjectId.Parse(field?.ToString());
|
||||
}
|
||||
if (isMember) return field.ToString();
|
||||
else
|
||||
return field;
|
||||
}
|
||||
internal static BsonValue GetBsonValue(bool isMember, BsonValue field)
|
||||
{
|
||||
if (isMember) return "$" + field;
|
||||
|
Reference in New Issue
Block a user