修改导表错误

This commit is contained in:
2024-04-08 11:02:35 +08:00
parent c14d5be4ac
commit e98d80eea6
3 changed files with 10 additions and 10 deletions
@@ -61,7 +61,7 @@ namespace IRaCIS.Core.Infrastructure.Extention
object propertyValue = property.GetValue(obj);
// 如果属性的类型是枚举,将其值保留为整数
if (property.PropertyType.IsEnum)
if (property.PropertyType.IsEnum || Nullable.GetUnderlyingType(property.PropertyType)?.IsEnum == true)
{
dictionary.Add(propertyName, (int)propertyValue);
}