Flat Forms: DynamicEditFormBase - ProCodersPtyLtd/MasterDetailsDataEntry GitHub Wiki

Class DynamicEditFormBase

Namespace:

using Platz.SqlForms;

Declaration:

public abstract class DynamicEditFormBase : IDynamicEditForm

Base class for DynamicEditFormBase<T> generic class

Define - protected virtual method

protected virtual void Define(DynamicFormBuilder builder)`

This method should be implemented in a Dynamic Form class that is inherited from DynamicEditFormBase<T>. The method accepts only one parameter DynamicFormBuilder builder. The following example shows how to use it:

        protected override void Define(DynamicFormBuilder builder)
        {
            builder.Entity<Course>(e =>
            {
                e.Property(p => p.CourseID).IsPrimaryKey().IsUnique(); 

                e.Property(p => p.Title).IsRequired();

                ...
            });
        }

Class DynamicEditFormBase<T>

Namespace:

using Platz.SqlForms;

Declaration:

public abstract class DynamicEditFormBase<T> : DynamicEditFormBase where T : DbContext

Base class to create a Dynamic Form definition.

Parameters:

DynamicEditFormBase accepts T template parameter, it should be a class that based on Entity Framework DbContext

Class DynamicFormBuilder

This class is only extension of FormBuilder and currently doesn't provide any additional functionality

Next Page: FormBuilder

⚠️ **GitHub.com Fallback** ⚠️