Esri / geoform-template-js

GeoForm is a configurable template for form based data editing of a Feature Service.
http://esri.github.io/geoform-template-js/
Apache License 2.0
67 stars 83 forks source link

List of field attributes? #512

Closed gismcieri closed 8 years ago

gismcieri commented 8 years ago

Hi, Is there a list of field attributes available. The one i can't seem to find is required.

    "fields": {
    "BusinessLicenseTest_5614": [{
    "name": "OwnerName", // field ID
    "alias": "Owner Name", // label
    "fieldDescription": "", // help text
    "visible": true, // show this field?
    "typeField": false, // subtype field?
    "tooltip": "", // placeholder text
    "displayType": "text", // text, checkbox, radio, textarea, url, email
    "requiredFields": true 
  }

I have tried "required" = true, "requiredField": true and "requiredFields": true and none make the field required. The only way i can get a field required is by if the field is a dropdown and set typeField = true.

Am i missing something?

Thanks, Matt

driskull commented 8 years ago

Hey @gismcieri

Try setting nullable: false on the field.

gismcieri commented 8 years ago

That worked thanks!