Attribute bug

Discussion of open issues, suggestions and bugs regarding Entity Developer - ORM modeling and code generation tool
Post Reply
johnwest80
Posts: 27
Joined: Thu 09 Jun 2011 22:32

Attribute bug

Post by johnwest80 » Thu 18 Aug 2011 14:35

I added the DataAnnotations Display attribute to a property in the model, then removed it. However, the generated code still has seems to think it's there, based on the generated code below.

[System.ComponentModel.DataAnnotations.Display(Name = @"Improvement Factors Group")]

I think this is a bug. If I remove the attribute from the model, it shouldn't show in generated code any longer.

Thanks.
Last edited by johnwest80 on Thu 18 Aug 2011 14:38, edited 1 time in total.

johnwest80
Posts: 27
Joined: Thu 09 Jun 2011 22:32

Post by johnwest80 » Thu 18 Aug 2011 14:37

I went and looked at the edmx xml, and it is in fact still there.

While I'm commenting on attributes, can you also change it so that only the properties of the attributes I change from default are shown in the xml? Right now, even though I only set the name property on the Display attribute, all the properties are generated in the xml file.

StanislavK
Devart Team
Posts: 1710
Joined: Thu 03 Dec 2009 10:48

Post by StanislavK » Tue 23 Aug 2011 14:43

The first issue may occur, e.g., if you've saved the model but did not regenerate the code. If this is not the case, could you please send us a model with which you are getting this problem?

Besides, thank you for your suggestion on saving attribute properties. We will consider implementing it and will inform you about the results.

StanislavK
Devart Team
Posts: 1710
Joined: Thu 03 Dec 2009 10:48

Post by StanislavK » Fri 07 Oct 2011 09:40

We have implemented filtering attribute properties with default values in the model file. This change is available in the latest 4.1.55 build of Entity Developer (and in the new builds of data providers as well). The new build of Entity Developer can be downloaded from
http://www.devart.com/entitydeveloper/download.html
(the trial and free versions only) or from Registered Users' Area (for users with active subscription only).

For more information about the fixes and improvements available in the new build, please refer to
http://www.devart.com/forums/viewtopic.php?t=22169

Post Reply