Kirsten
Kirsten

Reputation: 18160

New Property Not appearing in the module.win. model UI until the solution is exited and re-loaded

I am using Table-Per-Type inheritance in my XAF 24.1.6 Winforms Entity Framework application.

public class QuoteLineExt : JobExt {}

Public class JobExt : BaseJobExt {}

set up with

 protected override void OnModelCreating(ModelBuilder modelBuilder)
 {
  base.OnModelCreating(modelBuilder);
   
  modelBuilder.HasChangeTrackingStrategy(
      ChangeTrackingStrategy.ChangingAndChangedNotificationsWithOriginalValues);

        modelBuilder.Entity<BaseJobExt>()
            .HasDiscriminator<byte>(x => x.HeadType)
            .HasValue<QuoteLineExt>((byte)1)
            // etc
   }

When I add a new property to JobExt, then clean, build and update model. I can see the new property in Module Model.DesignedDiffs.xafml UI for JobExt.

However it does not appear in the Module.Win.xafml UI JobExt until I have exited visual studio and re-opened it.

Once I can see it in the JobExt OwnMembers section of the Module.Win Model Editor UI then I can also see it in QuoteLineExt section.

For example here is a property shown in the JobExt OwnMembers node of BOModel in the Module.Win project. New properties only seem to show here if I exit Visual Studio. Whereas they will show in the Module project without requiring me to close and re-open the solution.

enter image description here

New Property

Upvotes: 0

Views: 11

Answers (1)

Kirsten
Kirsten

Reputation: 18160

I havent been able to repeat this issue. I am unsure as to whether I had to exit visual studio when it happened or whether closing the solution was sufficient.

Upvotes: 0

Related Questions