Generate extra special fields - namely the security token field (if required).

@return FieldList
966497
public function getExtraFields()
    {
        $extraFields = new FieldList();

        $token = $this->getSecurityToken();
        if ($token) {
            $tokenField = $token->updateFieldSet($this->fields);
            if ($tokenField) {
                $tokenField->setForm($this);
            }
        }
        $this->securityTokenAdded = true;

        // add the "real" HTTP method if necessary (for PUT, DELETE and HEAD)
        if (strtoupper($this->FormMethod()) != $this->FormHttpMethod()) {
            $methodField = new HiddenField('_method', '', $this->FormHttpMethod());
            $methodField->setForm($this);
            $extraFields->push($methodField);
        }

        return $extraFields;
    }
437774
public function buildFields()
    {
        if ($this->domainConfiguration->isMultiDomainHost()) {
            $this->addField('domain', 'redirect.adminlist.header.domain', true);
        }
        $this->addField('origin', 'redirect.adminlist.header.origin', true);
        $this->addField('target', 'redirect.adminlist.header.target', true);
        $this->addField('permanent', 'redirect.adminlist.header.permanent', true);
        $this->addField('note', 'redirect.adminlist.header.note', true);
    }
867019
public static function getExtraFields(){
        return array_map(function($field){
            $extra = [
                'id' => $field['id'],
                'label' => $field['label'],
                'filterable' => array_key_exists('filterable', $field) ? $field['filterable'] : false,
            ];
            if (array_key_exists('columnPosition', $field)) {
                $extra['columnPosition'] = $field['columnPosition'];
            }
            return $extra;
        }, self::_getUserExtraFields());
    }
1184712
protected function generatePostFields () : string
	{
		$fieldsString = '';
		foreach($this->fields as $key => $value) $fieldsString .= $key.'='.$value.'&';
		return rtrim($fieldsString, '&');
	}
37898
protected function getFieldValues() {
        if (!$this->_fieldValues) {
            $this->_fieldValues = new FieldValueList(
                $this->version,
                $this->solution['assistantSid'],
                $this->solution['sid']
            );
        }

        return $this->_fieldValues;
    }
56672
public function get_form_fields() {
        if (empty($this->type)) {
            return '';
        }

        $result  = '<input type="hidden" name="gpr_type" value="'.$this->type.'" />';

        if (!empty($this->plugin)) {
            $result .= '<input type="hidden" name="gpr_plugin" value="'.$this->plugin.'" />';
        }

        if (!empty($this->courseid)) {
            $result .= '<input type="hidden" name="gpr_courseid" value="'.$this->courseid.'" />';
        }

        if (!empty($this->userid)) {
            $result .= '<input type="hidden" name="gpr_userid" value="'.$this->userid.'" />';
        }

        if (!empty($this->groupid)) {
            $result .= '<input type="hidden" name="gpr_groupid" value="'.$this->groupid.'" />';
        }

        if (!empty($this->page)) {
            $result .= '<input type="hidden" name="gpr_page" value="'.$this->page.'" />';
        }
        return $result;
    }
117257
public function getFields()
    {
        $fields = array_keys($this->fillable);
        if (!empty($fields) && is_integer($fields[0]))
            // only alias provided
            $fields = array_values($this->fillable);

        return array_merge($fields, $this->appends, array_keys($this->attributes));
    }
1289530
public function getCMSFields() {
        $fields=new FieldList(
                            new TabSet('Root',
                                    new Tab('Main', _t('KapostObject.MAIN', '_Main'),
                                        new ReadonlyField('Created', $this->fieldLabel('Created')),
                                        new ReadonlyField('KapostChangeTypeNice', $this->fieldLabel('KapostChangeType')),
                                        new ReadonlyField('KapostAuthor', $this->fieldLabel('KapostAuthor')),
                                        new ReadonlyField('ToPublishNice', $this->fieldLabel('ToPublish')),
                                        new ReadonlyField('ClassNameNice', _t('KapostObject.CONTENT_TYPE', '_Content Type')),
                                        new ReadonlyField('Title', $this->fieldLabel('Title')),
                                        HtmlEditorField_Readonly::create('ContentNice', $this->fieldLabel('Content'), $this->sanitizeHTML($this->Content))
                                    )
                                )
                        );
        
        
        //Allow extensions to adjust the fields
        $this->extend('updateCMSFields', $fields);
        
        return $fields;
    }
1005375
public function getFields()
	{
		$list	= array();
		foreach( $this->fields as $name => $fields )
				if( count( $fields ) )
					foreach( $fields as $field )
						$list[]	= $field;
		return $list;
	}
1164776
public function getFields() {
        if($this->cachedFields == null) {
            $this->cachedFields = $this->createFields();
        }

        return $this->cachedFields;
    }
753459
public function getCMSPageFields()
    {
        $fields = parent::getCMSPageFields();
        $fields->removeByName('Title');
        $fields->addFields(
            array(
                HtmlEditorField::create(
                    'Content',
                    _t('MainBlock.CONTENT', 'Content')
                )
            )
        );
        $this->extend('updateCMSPageFields', $fields);
        return $fields;
    }
1063272
public function tokenMailFields()
    {
        if ($this->token) {
            $locale = $this->respondent->getLanguage();
            $survey = $this->token->getSurvey();
            // Count todo
            $tSelect = $this->loader->getTracker()->getTokenSelect(array(
                'all'   => 'COUNT(*)',
                'track' => $this->db->quoteInto(
                        'SUM(CASE WHEN gto_id_respondent_track = ? THEN 1 ELSE 0 END)',
                        $this->token->getRespondentTrackId())
                ));
            $tSelect->andSurveys(array())
                ->forRespondent($this->token->getRespondentId(), $this->organizationId)
                ->forGroupId($survey->getGroupId())
                ->onlyValid();
            $todo = $tSelect->fetchRow();

            // Set the basic fields

            $result['round']                   = $this->token->getRoundDescription();

            $organizationLoginUrl = $this->organization->getLoginUrl();

            $result['site_ask_url']            = $organizationLoginUrl . '/ask/';
            // Url's
            $url      = $organizationLoginUrl . '/ask/forward/' . \MUtil_Model::REQUEST_ID . '/';
            $url      .= $this->token->getTokenId();
            $urlInput = $result['site_ask_url'] . 'index/' . \MUtil_Model::REQUEST_ID . '/' . $this->token->getTokenId();

            $result['survey']           = $survey->getName();

            $result['todo_all']         = sprintf($this->translate->plural('%d survey', '%d surveys', $todo['all'], $locale), $todo['all']);
            $result['todo_all_count']   = $todo['all'];
            $result['todo_track']       = sprintf($this->translate->plural('%d survey', '%d surveys', $todo['track'], $locale), $todo['track']);
            $result['todo_track_count'] = $todo['track'];

            $result['token']            = strtoupper($this->token->getTokenId());
            $result['token_from']       = \MUtil_Date::format($this->token->getValidFrom(), \Zend_Date::DATE_LONG, 'yyyy-MM-dd', $locale);

            $result['token_link']       = '[url=' . $url . ']' . $survey->getName() . '[/url]';

            $result['token_until']      = \MUtil_Date::format($this->token->getValidUntil(), \Zend_Date::DATE_LONG, 'yyyy-MM-dd', $locale);
            $result['token_url']        = $url;
            $result['token_url_input']  = $urlInput;

            $result['track']            = $this->token->getTrackName();

            // Add the code fields
            $codes  = $this->token->getRespondentTrack()->getCodeFields();
            foreach ($codes as $code => $data) {
                $key = 'track.' . $code;
                if (is_array($data)) {
                    $data = implode(' ', $data);
                }
                $result[$key] = $data;
            }

            if ($this->token->hasRelation()) {
                $allFields = $this->getMailFields(false);
                // Set about to patient name
                $result['relation_about'] = $allFields['name'];
                $result['relation_about_first_name'] = $allFields['first_name'];
                $result['relation_about_full_name'] = $allFields['full_name'];
                $result['relation_about_greeting'] = $allFields['greeting'];
                $result['relation_about_last_name'] = $allFields['last_name'];
                $result['relation_field_name'] = $this->token->getRelationFieldName();

                if ($relation = $this->token->getRelation()) {
                    // Now update all respondent fields to be of the relation
                    $result['name']       = $relation->getName();
                    $result['first_name'] = $relation->getFirstName();
                    $result['last_name']  = $relation->getLastName();
                    $result['full_name']  = $relation->getHello($locale);
                    $result['greeting']   = $relation->getGreeting($locale);
                    $result['to']         = $relation->getEmail();
                } else {
                    $result['name']       = $this->translate->getAdapter()->_('Undefined relation');
                    $result['first_name'] = '';
                    $result['last_name']  = '';
                    $result['full_name']  = '';
                    $result['greeting']   = '';
                    $result['to']         = '';
                }
            } else {
                $result['relation_about'] = $this->translate->getAdapter()->_('yourself', $this->token->getRespondentLanguage());
                $result['relation_about_first_name'] = '';
                $result['relation_about_full_name'] = '';
                $result['relation_about_greeting'] = '';
                $result['relation_about_last_name'] = '';
                $result['relation_field_name'] = '';
            }

        } else {
            $result['round']                     = '';
            $result['site_ask_url']              = '';
            $result['survey']                    = '';
            $result['todo_all']                  = '';
            $result['todo_all_count']            = '';
            $result['todo_track']                = '';
            $result['todo_track_count']          = '';
            $result['token']                     = '';
            $result['token_from']                = '';
            $result['token_link']                = '';
            $result['token_until']               = '';
            $result['token_url']                 = '';
            $result['token_url_input']           = '';
            $result['track']                     = '';
            $result['relation_about']            = $this->translate->getAdapter()->_('yourself');
            $result['relation_about_first_name'] = '';
            $result['relation_about_full_name']  = '';
            $result['relation_about_greeting']   = '';
            $result['relation_about_last_name']  = '';
            $result['relation_field_name']       = '';
        }

        return $result;
    }
860818
public function getCMSFields()
    {
        $commentField = $this->AllowHtml ? HTMLEditorField::class : TextareaField::class;
        $fields = new FieldList(
            $this
                ->obj('Created')
                ->scaffoldFormField($this->fieldLabel('Created'))
                ->performReadonlyTransformation(),
            TextField::create('Name', $this->fieldLabel('Name')),
            $commentField::create('Comment', $this->fieldLabel('Comment')),
            EmailField::create('Email', $this->fieldLabel('Email')),
            TextField::create('URL', $this->fieldLabel('URL')),
            FieldGroup::create(array(
                CheckboxField::create('Moderated', $this->fieldLabel('Moderated')),
                CheckboxField::create('IsSpam', $this->fieldLabel('IsSpam')),
            ))
                ->setTitle(_t(__CLASS__ . '.OPTIONS', 'Options'))
                ->setDescription(_t(
                    __CLASS__ . '.OPTION_DESCRIPTION',
                    'Unmoderated and spam comments will not be displayed until approved'
                ))
        );

        // Show member name if given
        if (($author = $this->Author()) && $author->exists()) {
            $fields->insertAfter(
                TextField::create('AuthorMember', $this->fieldLabel('Author'), $author->Title)
                    ->performReadonlyTransformation(),
                'Name'
            );
        }

        // Show parent comment if given
        if (($parent = $this->ParentComment()) && $parent->exists()) {
            $fields->push(new HeaderField(
                'ParentComment_Title',
                _t(__CLASS__ . '.ParentComment_Title', 'This comment is a reply to the below')
            ));
            // Created date
            // FIXME - the method setName in DatetimeField is not chainable, hence
            // the lack of chaining here
            $createdField = $parent
                ->obj('Created')
                ->scaffoldFormField($parent->fieldLabel('Created'));
            $createdField->setName('ParentComment_Created');
            $createdField->setValue($parent->Created);
            $createdField->performReadonlyTransformation();
            $fields->push($createdField);

            // Name (could be member or string value)
            $fields->push(
                $parent
                    ->obj('AuthorName')
                    ->scaffoldFormField($parent->fieldLabel('AuthorName'))
                    ->setName('ParentComment_AuthorName')
                    ->setValue($parent->getAuthorName())
                    ->performReadonlyTransformation()
            );

            // Comment body
            $fields->push(
                $parent
                    ->obj('EscapedComment')
                    ->scaffoldFormField($parent->fieldLabel(self::class))
                    ->setName('ParentComment_EscapedComment')
                    ->setValue($parent->Comment)
                    ->performReadonlyTransformation()
            );
        }

        $this->extend('updateCMSFields', $fields);
        return $fields;
    }
310001
public function getFields()
    {
        $query_fields = $this->query['fields'] ?? '';
        if ($query_fields === '') {
            return [];
        }

        $special = $this->getSpecialFields();
        foreach ($special as $key => $value) {
            $special[$key] = implode(',', $value);
        }

        $fields = array_filter(explode(',', str_replace(
            array_keys($special),
            $special,
            $query_fields
        )));

        $message = $this->hasFields($fields);
        if ($message !== true) {
            return $message;
        }
        return $fields;
    }
1085613
public function getFields()
    {
        $fields = FieldList::create();

        foreach ($this->fieldgroups as $group) {
            if (method_exists($this, 'get'.$group.'Fields')) {
                $fields->merge($this->{'get'.$group.'Fields'}());
            }
        }

        return $fields;
    }
324712
private function getOauthFields()
    {
        $this->oAuthFields = [
            'grant_type' => 'client_credentials',
            'scope' => $this->scope,
            'client_secret' => $this->mpClientSecret,
            'client_id' => $this->mpClientId,
        ];

        $this->fieldCount = count($this->oAuthFields);

        return $this->oAuthFields;
    }
365791
public function getFields()
    {
        $model = $this->getModelInstance();
        $fields = $model->getFillable();
        $filtered_fields = [];

        foreach ($fields as $f) {
            if ($f !== 'password' && $f !== 'Password') {
                $filtered_fields[] = $f;
            }
        }

        return $filtered_fields;
    }