Aaltuj / VxFormGenerator

The library contains a component, that nests itself into the Blazor EditForm instead of a wrapper around the EditForm. The component is able to generate a form based on a POCO or a ExpandoObject. Because of this architecture the library provides the developer flexibility and direct usage of the EditForm.
MIT License
119 stars 36 forks source link

DynamicForm.razor show nothing #36

Closed brandonchiang closed 1 year ago

brandonchiang commented 1 year ago

After run this project, in /dynamic-form, I didn't see any Form Element. Then I check the source, found 2 TODO: EXPANDO SWITCH. One is in

public class VxFormDefinition : Attribute
{
    internal static VxFormDefinition CreateFromModel(object model, VxFormLayoutOptions options)
    {}
}

and the other is in

public class VxFormGroup
{
        internal static void Add(string fieldIdentifier, VxFormGroup group, object modelInstance, VxFormLayoutOptions options)
        {
        }
}

but I don't know to deal with the FormGroup since you sample data

    protected override void OnInitialized()
    {
        var dict = (IDictionary<String, Object>)Model;
        dict.Add("Name", "add");
        dict.Add("Note", "This is a note");
        dict.Add("Date", DateTime.Now);
        dict.Add("Amount", 1);
        dict.Add("Color", new VxFormGenerator.Models.VxColor("#fff"));
    }

is not given group field.

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.