I am trying to add a new field type, which is a copy of a textfield, so that I can add special validation. The field is for a Member email address and I want to check that the email address is not currently in use.
The form renders OK in the Form editor, however clicking the "OK" button does not close the side panel. Also, rendering the form on the website causes an error.
So, have I missed something or done something wrong? Is there any more information on how to add field types anywhere?
Also ... I have added 2 new field types (both very similar to the above / a copy of a textfield) but for both of them, the "OK" button does not work when editing the field details in the Form Editor. The changes seem to work if I save the entire form, but "OK" does not close the side panel.
Am I missing something from the field definition (class)?
Add a new field type
I am trying to add a new field type, which is a copy of a textfield, so that I can add special validation. The field is for a Member email address and I want to check that the email address is not currently in use.
I started with this documentation page - http://our.umbraco.org/documentation/products/umbracoforms/Developer/Extending/Adding-a-Fieldtype but I am not sure that it is complete and/or correct?
I have this class for the new field type:
And I have this for the FieldType (view) definition:
I also had to add a new file in "App_Plugins\UmbracoForms\Backoffice\Common\FieldTypes" called MemberLogonEmail.html
The form renders OK in the Form editor, however clicking the "OK" button does not close the side panel. Also, rendering the form on the website causes an error.
So, have I missed something or done something wrong? Is there any more information on how to add field types anywhere?
Any exceptions ? do you see any errors in the browser js log - what is the error you see when the form is not rendering?
I get this on the page:
Error loading Partial View script (file: ~/Views/MacroPartials/InsertUmbracoForm.cshtml)
The error log is (large!):
This is the issue:
Is it a convention to have "Fieldtype." at the beginning and why is it "memberemail" rather than "memberlogonemail" which is the class name?
Also ... I have added 2 new field types (both very similar to the above / a copy of a textfield) but for both of them, the "OK" button does not work when editing the field details in the Form Editor. The changes seem to work if I save the entire form, but "OK" does not close the side panel.
Am I missing something from the field definition (class)?
is working on a reply...