MRCollective / ChameleonForms

Shape-shifting your forms experience in ASP.NET Core MVC
MIT License
254 stars 56 forks source link

Changing the default name of the control #154

Closed mahyarmot closed 5 years ago

mahyarmot commented 7 years ago

In case of having a complex and nested Dto which is going the build an expression like this @s.FieldFor(m => m.CreateOreditManifestDto.ManifestDto.BoxAgentID) we have a problem in serializing the object using jQuery and map it to our entities. Due to the generated name of the control "CreateOreditManifestDto.ManifestDto.BoxAgentID" , the mapping does not apply to our json object. I wonder to know if there is an option to override the default naming convention, something like .Id("foo") extension method, or how can I manipulate the IHtmlString in Feild Method of our template