In Umbraco v6 Contour you could pass any custom viewmodel to the view that rendered your fieldtype whereas now it appears you must pass a FieldViewModel. In Forms.cshtml the line
Does anyone know how/if you can pass a custom viewmodel under v7 or are you restricted to adding individual string properties (or passing as a json string) to AdditionalSettings and handling those at "either end" of the forms process to wrap and unwrap my custom object?
I'm in the process of converting an existing v6 site which contains custom Contour field types (in this case an address search/lookup control to our in-house address database).
Viewmodel in Umbraco Forms custom fields
In Umbraco v6 Contour you could pass any custom viewmodel to the view that rendered your fieldtype whereas now it appears you must pass a FieldViewModel. In Forms.cshtml the line
blows if this is not the case. The same line in v6 reads
Does anyone know how/if you can pass a custom viewmodel under v7 or are you restricted to adding individual string properties (or passing as a json string) to AdditionalSettings and handling those at "either end" of the forms process to wrap and unwrap my custom object?
I'm in the process of converting an existing v6 site which contains custom Contour field types (in this case an address search/lookup control to our in-house address database).
is working on a reply...