function getFieldConfiguration()
 {
     $fields = parent::getFieldConfiguration();
     // eventually replace hard-coded "Fields"?
     $baseName = "Fields[{$this->ID}]";
     $listName = $this->getSetting('ListTitle') ? $this->getSetting('ListTitle') : '';
     // get a list of data lists to select from
     $allLists = DataObject::get('DataList');
     $options = array('Please create a DataList!' => '(No DataLists available)');
     if ($allLists) {
         /* @var $allLists DataObjectSet */
         $options = $allLists->map('Title', 'Title');
     }
     $extraFields = new FieldSet(new DropDownField($baseName . "[CustomSettings][ListTitle]", _t('EditableDataListField.DATALIST_TITLE', 'List Title'), $options, $listName));
     $fields->merge($extraFields);
     return $fields;
 }
 function getFieldConfiguration()
 {
     $fields = parent::getFieldConfiguration();
     // eventually replace hard-coded "Fields"?
     $baseName = "Fields[{$this->ID}]";
     $listName = $this->getSetting('SourceList') ? $this->getSetting('SourceList') : '';
     // select another form field that has the titles of the lists to use for this list when displayed
     // The assumption being made here is that each entry in the source list has a corresponding data list
     // defined for it, which we use later on.
     $options = array();
     if ($this->Parent()) {
         $sourceList = $this->Parent()->Fields();
         if ($sourceList) {
             $options = $sourceList->map('Name', 'Title');
         }
     }
     $extraFields = new FieldSet(new DropDownField($baseName . "[CustomSettings][SourceList]", _t('EditableDependentDataListField.SOURCE_LIST_TITLE', 'Source List'), $options, $listName));
     $fields->merge($extraFields);
     return $fields;
 }