N. Davis
N. Davis

Reputation: 21

Is there an option to use a different attribute for IsChanged using Fody PropertyChanged?

I am working on an Entity Framework / WPF project which has hundreds of tables in the database. Many of the tables include a field named IsChanged. I am using a model base class and PropertyChanged.Fody to handle the injection of INotifyPropertyChanged for all the models.

Will the Fody / EF naming conflict for IsChanged cause any issues, and if it will, is there a way to instruct Fody to use a differently named property for the same purpose?

Upvotes: 1

Views: 329

Answers (1)

N. Davis
N. Davis

Reputation: 21

To sum up, what I had hoped to do was find some option that would tell Fody.PropertyChanged to use a field other than IsChanged for the same purpose. For instance, to use a field named IsDataChanged rather than IsChanged. This was because the database administrator had designed the entire database so that each table has a field named IsChanged that he wanted to use for his own purposes which are different than what is needed in the application.

To skirt the issue, the database administrator renamed his fields to IsDataChanged. By doing this, he has a field to use as he needs which will not be automatically maintained by either Entity Framework or Fody.PropertyChanged.

Upvotes: 1

Related Questions