In my model classes I have multiple properties that are 'protected internal set'. Once these properties are created they should not be able to be modified. Having said that I am having a hard time creating a model binder that will allow these properties to be set upon creation. What is the best way to proceed in order to be able to set these properties just once?
Unfortunately, this is not something you can do automatically. You'll have to create a unique model binder for each type, and then create the objects using constructor parameters.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With