You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 14, 2018. It is now read-only.
In one of my projects I have a registered IDisplayMetadataProvider that examines the attributes on a model's properties and sets values in ModelMetadata.AdditionalValues as necessary. I find that if:
the model property in question is a Nullable<T> AND
the default value of the property is a value other than null
then the customizations to ModelMetadata are lost by the time the view is rendered.
In one of my projects I have a registered
IDisplayMetadataProvider
that examines the attributes on a model's properties and sets values inModelMetadata.AdditionalValues
as necessary. I find that if:Nullable<T>
ANDthen the customizations to ModelMetadata are lost by the time the view is rendered.
A minimal project to reproduce the issue is here: https://github.com/emisaacson/MetadataProviderExample
I find with this change I get the expected result (
AdditionalValues
is populated when rendering the view): dev...emisaacson:vd-type-checkingThe text was updated successfully, but these errors were encountered: