You are here

public function WSDataService::wscallConfigurationsReplacements in Web Service Data 2.0.x

Same name and namespace in other branches
  1. 8 src/WSDataService.php \Drupal\wsdata\WSDataService::wscallConfigurationsReplacements()

Ajax call back for the replacement pattern.

File

src/WSDataService.php, line 190

Class

WSDataService
Service for processing WSData requests.

Namespace

Drupal\wsdata

Code

public function wscallConfigurationsReplacements(array &$form, FormStateInterface $form_state) {
  if (isset($form['replacements'])) {
    return $form['replacements'];
  }
  elseif (isset($form['settings']['replacements'])) {
    return $form['settings']['replacements'];
  }
  else {
    return $form;
  }
}