예제 #1
0
  /**
   * {@inheritdoc}
   */
  public function submitForm(array &$form, FormStateInterface $form_state) {
    $config = $this->configFactory->getEditable('commerce_cart.settings');
    $config->set('cart_page.view',  $form_state->getValue('view'));
    $config->save();

    parent::submitForm($form, $form_state);
  }
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $config = $this->config('configform_example.settings');
     $config->set('email_address', $form_state->getValue('email'));
     $config->save();
     return parent::submitForm($form, $form_state);
 }
예제 #3
0
 /**
  * Implements \Drupal\Core\Form\FormInterface::submitForm().
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $config = $this->configFactory()->getEditable('meetup_pull.settings');
     $config->set('api_key', $form_state->getValue('api_key'))->save();
     $config->set('group_name', $form_state->getValue('group_name'))->save();
     parent::submitForm($form, $form_state);
 }
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     parent::submitForm($form, $form_state);
     // $config = $this->config('idmygadget.settings');
     // $config->set('idmygadget_', $form_state->getValue('idmygadget_'));
     // $config->save();
 }
예제 #5
0
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     parent::submitForm($form, $form_state);
     // normalize line endings to \n
     $selectors = preg_replace('/[\\r\\n]+/', "\n", $form_state->getValue('exclude_hover_selectors'));
     $this->config('pinterest_hover.settings')->set('load_pinterest_js', $form_state->getValue('load_pinterest_js'))->set('exclude_hover_selectors', $selectors)->save();
 }
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state) {
   $this->config('dropdown_language.setting')
     ->set('wrapper', $form_state->getValue('wrapper'))
     ->save();
   parent::submitForm($form, $form_state);
   Cache::invalidateTags(['rendered']);
 }
예제 #7
0
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     // Remove unnecessary values.
     form_state_values_clean($form_state);
     $this->config('faq.settings')->set('use_categories', $form_state['values']['faq_use_categories'])->set('category_display', $form_state['values']['faq_category_display'])->set('category_listing', $form_state['values']['faq_category_listing'])->set('category_hide_qa_accordion', $form_state['values']['faq_category_hide_qa_accordion'])->set('count', $form_state['values']['faq_count'])->set('answer_category_name', $form_state['values']['faq_answer_category_name'])->set('group_questions_top', $form_state['values']['faq_group_questions_top'])->set('hide_child_terms', $form_state['values']['faq_hide_child_terms'])->set('show_term_page_children', $form_state['values']['faq_show_term_page_children'])->set('omit_vocabulary', $form_state['values']['faq_omit_vocabulary'])->save();
     parent::submitForm($form, $form_state);
 }
예제 #8
0
 /**
  * Implements \Drupal\Core\Form\FormInterface::submitForm().
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $values = $form_state->getValues();
     $config = $this->config('google_analytics_lite.settings');
     $config->set('trackingId', $values['trackingId'])->save();
     parent::submitForm($form, $form_state);
 }
예제 #9
0
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state) {
   parent::submitForm($form, $form_state);
   $this->config('logouttab.settings')
     ->set('url', $form_state->getValue('url'))
     ->set('weight', $form_state->getValue('weight'))
     ->save();
 }
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $config = $this->config('tweets.settings');
     $config->set('twitter_secret_key', $form_state->getValue('twitter_secret_key'))->set('twitter_api_key', $form_state->getValue('twitter_api_key'))->set('twitter_access_api_key', $form_state->getValue('twitter_access_api_key'))->set('twitter_access_secret_key', $form_state->getValue('twitter_access_secret_key'))->set('twitter_username', $form_state->getValue('twitter_username'))->set('max_tweets', $form_state->getValue('max_tweets'));
     $config->save();
     parent::submitForm($form, $form_state);
 }
 /**
  * Submit callback.
  *
  * Implements the form logic.
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $this->config('happy_alexandrie.library_config')->set('opening_hours', $form_state->getValue('opening_hours'))->save();
     // Call the parent implementation to inherit from what has been done in it.
     // In our case, display the confirmation message.
     parent::submitForm($form, $form_state);
 }
예제 #12
0
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $config = $this->config('spectrum.settings');
     $config->set('sendgrid_api_key', $form_state->getValue('sendgrid_api_key'));
     $config->save();
     parent::submitForm($form, $form_state);
 }
예제 #13
0
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     parent::submitForm($form, $form_state);
     $config = $this->config('hugs.settings');
     $config->set('default_count', $form_state->getValue('default_count'));
     $config->save();
 }
예제 #14
0
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     // Remove unnecessary values.
     form_state_values_clean($form_state);
     $this->config('faq.settings')->set('title', $form_state['values']['faq_title'])->set('description', $form_state['values']['faq_description'])->set('custom_breadcrumbs', $form_state['values']['faq_custom_breadcrumbs'])->save();
     parent::submitForm($form, $form_state);
 }
예제 #15
0
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     // Remove unnecessary values.
     form_state_values_clean($form_state);
     $this->config('faq.settings')->set('display', $form_state['values']['faq_display'])->set('question_listing', $form_state['values']['faq_question_listing'])->set('qa_mark', $form_state['values']['faq_qa_mark'])->set('question_label', $form_state['values']['faq_question_label'])->set('answer_label', $form_state['values']['faq_answer_label'])->set('question_length', $form_state['values']['faq_question_length'])->set('question_long_form', $form_state['values']['faq_question_long_form'])->set('hide_qa_accordion', $form_state['values']['faq_hide_qa_accordion'])->set('show_expand_all', $form_state['values']['faq_show_expand_all'])->set('use_teaser', $form_state['values']['faq_use_teaser'])->set('back_to_top', $form_state['values']['faq_back_to_top'])->set('disable_node_links', $form_state['values']['faq_disable_node_links'])->set('default_sorting', $form_state['values']['faq_default_sorting'])->save();
     parent::submitForm($form, $form_state);
 }
예제 #16
0
 /**
  * @inheritDoc
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     // Get form variable values.
     $config = $this->config(self::SETTINGS);
     $config->set('window_target', $form_state->getValue('window_target'));
     parent::submitForm($form, $form_state);
 }
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $config = $this->configFactory->getEditable('autofloat.settings');
     $config->set('start', $form_state->getValue('autofloat_start'))->set('css', $form_state->getValue('autofloat_css'))->set('span', $form_state->getValue('autofloat_span'))->set('div', $form_state->getValue('autofloat_div'));
     $config->save();
     drupal_flush_all_caches();
     parent::submitForm($form, $form_state);
 }
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $config = $this->config('flexslider.settings');
     $config->set('flexslider_debug', $form_state->getValue('flexslider_debug'))->save();
     // Invalidate the library discovery cache to update new assets.
     \Drupal::service('library.discovery')->clearCachedDefinitions();
     parent::submitForm($form, $form_state);
 }
예제 #19
0
  /**
   * {@inheritdoc}
   */
  public function submitForm(array &$form, FormStateInterface $form_state) {
    parent::submitForm($form, $form_state);

    $this->config('anonymous_login.settings')
      ->set('paths', $form_state->getValue('paths'))
      ->set('message', $form_state->getValue('message'))
      ->save();
  }
예제 #20
0
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $this->rulesUiHandler->getForm()->submitForm($form['conditions'], $form_state);
     $this->config('rules_test_ui_embed.settings')->set('css.0.file', $form_state->getValue('css_file'))->save();
     // Also remove the temporarily stored component, it has been persisted now.
     $this->rulesUiHandler->clearTemporaryStorage();
     parent::submitForm($form, $form_state);
 }
 /**
  * Clears the caches.
  */
 public function submitResetDefaults(array &$form, FormStateInterface $form_state)
 {
     $config = $this->config('globalredirect.settings');
     // Get config factory
     $settingsDefault = $this->getDefaultSettings();
     $config->set('deslash', $settingsDefault['deslash'])->set('nonclean_to_clean', $settingsDefault['nonclean_to_clean'])->set('access_check', $settingsDefault['access_check'])->set('normalize_aliases', $settingsDefault['normalize_aliases'])->set('canonical', $settingsDefault['canonical'])->set('content_location_header', $settingsDefault['content_location_header'])->set('term_path_handler', $settingsDefault['term_path_handler'])->set('frontpage_redirect', $settingsDefault['frontpage_redirect'])->set('ignore_admin_path', $settingsDefault['ignore_admin_path'])->save();
     parent::submitForm($form, $form_state);
 }
예제 #22
0
  /**
   * {@inheritdoc}
   */
  public function submitForm(array &$form, FormStateInterface $form_state) {
    $values = $form_state->getValues();
    $this->config('subpathauto.settings')
      ->set('depth', $values['depth'])
      ->save();

    parent::submitForm($form, $form_state);
  }
예제 #23
0
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $config = $this->config('intranet_petitions.settings');
     $config->set('intranet_petitions_expired_days', $form_state->getValue('intranet_petitions_expired_days'));
     $config->set('intranet_petitions_likes_level', $form_state->getValue('intranet_petitions_likes_level'));
     $config->save();
     parent::submitForm($form, $form_state);
 }
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $sitemap = new Simplesitemap();
     $settings = $sitemap->get_settings();
     $settings['max_links'] = $form_state->getValue('max_links');
     $sitemap->save_settings($settings);
     parent::submitForm($form, $form_state);
 }
예제 #25
0
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, array &$form_state)
 {
     $this->config('system.image')->set('toolkit', $form_state['values']['image_toolkit'])->save();
     // Call the form submit handler for each of the toolkits.
     foreach ($this->availableToolkits as $toolkit) {
         $toolkit->settingsFormSubmit($form, $form_state);
     }
     parent::submitForm($form, $form_state);
 }
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     parent::submitForm($form, $form_state);
     if ($form_state->getValues('verify-email')['contrasena_verifyemail'] != '') {
         $this->config('gestiondenuncias.configuration')->set('contrasena_verifyemail', $form_state->getValues('verify-email')['contrasena_verifyemail']);
     }
     $this->config('gestiondenuncias.configuration')->set('validar_email', $form_state->getValue('activar_validar_email'))->set('nombre_ususario_verifyemail', $form_state->getValues('verify-email')['nombre_ususario_verifyemail'])->set('verificar_via_recaptcha', $form_state->getValue('verificar_via_recaptcha'))->set('private_key_recaptcha', $form_state->getValues('datos-recaptcha')['private_key_recaptcha'])->set('public_key_recaptcha', $form_state->getValues('datos-recaptcha')['public_key_recaptcha'])->set('entorno_prueba_recaptcha', $form_state->getValues('datos-recaptcha')['entorno_prueba_recaptcha'])->set('enviar_email_supervisores', $form_state->getValue('enviar-email-supervisores'))->set('fecha_prueba_cron', $form_state->getValue('fecha-prueba-cron'))->set('usar_fecha_prueba_cron', $form_state->getValue('usar-fecha-prueba-cron'))->save();
     drupal_set_message("Es recomendable Vaciar todas las cachés");
 }
예제 #27
0
  /**
   * {@inheritdoc}
   */
  public function submitForm(array &$form, FormStateInterface $form_state) {
    parent::submitForm($form, $form_state);

    $this->config('form_example.config_config')
      ->set('first_name', $form_state->getValue('first_name'))
      ->set('last_name', $form_state->getValue('last_name'))
      ->set('dob', $form_state->getValue('dob'))
      ->save();
  }
예제 #28
0
 /**
  * {@inheritdoc}.
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $config = $this->config('sociallinks.settings');
     $config->set('sociallinks.facebook_link', $form_state->getValue('facebook_link'));
     $config->set('sociallinks.linkedin_link', $form_state->getValue('linkedin_link'));
     $config->set('sociallinks.twitter_link', $form_state->getValue('twitter_link'));
     $config->save();
     return parent::submitForm($form, $form_state);
 }
예제 #29
0
 /**
  * {@inheritdoc}
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     $auto_import = array();
     foreach ($form_state->getValues()['auto_import'] as $file) {
         $auto_import[] = array('filename' => $file, 'hash' => '');
     }
     $this->config(static::CONFIGNAME)->set('auto_import', $auto_import)->set('auto_export', $form_state->getValues()['auto_export'])->save();
     parent::submitForm($form, $form_state);
 }
예제 #30
0
 /**
  * @inheritDoc
  */
 public function submitForm(array &$form, FormStateInterface $form_state)
 {
     // Get form variable values.
     $config = $this->config(self::SETTINGS);
     $config->set('url', $form_state->getValue('url'));
     $config->set('database_connection_key', $form_state->getValue('database_connection_key'));
     $config->save(TRUE);
     parent::submitForm($form, $form_state);
 }