IModelBuilderExtensions

Provides extension methods for Restier model configuration to handle EasyAF-specific entity properties. Includes methods to ignore tracking fields and audit fields in OData model generation.

Syntax

public static class IModelBuilderExtensions

Inheritance

Methods

IgnoreAuditFields<T>

public static EntitySetConfiguration<T> IgnoreAuditFields<T>(this EntitySetConfiguration<T> configuration) where T : EasyObservableObject
Configures the entity set to ignore audit trail fields in the OData model. Dynamically removes DateCreated, DateUpdated, CreatedById, and UpdatedById properties based on implemented interfaces.

Parameters

Returns

EntitySetConfiguration<T> The entity set configuration for method chaining.

IgnoreTrackingFields<T>

public static EntitySetConfiguration<T> IgnoreTrackingFields<T>(this EntitySetConfiguration<T> configuration) where T : DbObservableObject
Configures the entity set to ignore DbObservableObject tracking fields in the OData model. Excludes IsChanged, IsGraphChanged, ShouldTrackChanges, and OriginalValues from the model.

Parameters

Returns

EntitySetConfiguration<T> The entity set configuration for method chaining.