add support for textarea ddatafield

master
Marek Isalski 5 years ago
parent 0841e97501
commit a76dcdf922

@ -98,6 +98,14 @@ function fulcrm_collection_to_form( $prefix, $collection_data, $d = array() ) {
'#default_value' => fulcrm_collection_get_d_value( $d, $field_data[ 'key' ] ),
);
break;
case 'textarea':
$fieldset[ $prefix . '/fulcrm/' . $field_data[ 'key' ] ] = array( '#type' => 'textarea',
'#title' => $field_data[ 'name' ],
'#description' => $field_data[ 'description' ],
'#required' => $field_data[ 'required' ],
'#default_value' => fulcrm_collection_get_d_value( $d, $field_data[ 'key' ] ),
);
break;
default:
drupal_set_message( t('Cannot handle ":type" collection structure.', array( ':type' => $field_data[ 'type' ] )), 'error' );
break;

Loading…
Cancel
Save