Account created on 2 February 2022, over 2 years ago
#

Merge Requests

More

Recent comments

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

Finally, the pipeline is green, but the changes should be well-checked

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ made their first commit to this issue’s fork.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ made their first commit to this issue’s fork.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ changed the visibility of the branch 3437346-migrate-to-gitlab to active.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ changed the visibility of the branch 3437346-migrate-to-gitlab to hidden.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ made their first commit to this issue’s fork.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

I tested the changes from the MR and they do resolve the issue I've faced, thanks guys. Cheers!

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ changed the visibility of the branch 3321802-change-readme-file to active.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ changed the visibility of the branch 3321802-change-readme-file to hidden.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ made their first commit to this issue’s fork.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

Created a merge request for the 3.0 branch.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ made their first commit to this issue’s fork.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

#2 works for me with Drupal 10.2.2 and Gin 8.x-3.0-rc7. Thanks.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

I've changed the variable name from $term_storage to $taxonomy_term_storage in 

//   'field_my_custom_field' is not empty.
$query = $term_storage->getQuery()

as the variable, that stores the storage, is named $taxonomy_term_storage above.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

Hi, @mvogel! Here are my steps to reproduce the issue:

  • Fresh install D10 with enabled devel_generate and ajax_loader;
  • Generated 50 articles and created a View that shows title, image and my custom ajaxified field (code below);
  • Added an ugly padding to the throbber, so it can be easily seen;
  • Tested the field with the response on the page. Works only for 1 time per submit in my case.

The link with testing - https://www.loom.com/share/6d713b4f717943098ba9b4fe73b463d4

The code I use for my custom field:

/**
 * Ajax Loader test field.
 *
 * @ingroup views_field_handlers
 *
 * @ViewsField("ajax_loader_test")
 */
class AjaxLoaderTest extends FieldPluginBase {

  use UncacheableFieldHandlerTrait;

  public function query() {
    // Leave empty.
  }

  public function getValue(ResultRow $row, $field = NULL) {
    return '<!--form-item-' . $this->options['id'] . '--' . $row->index . '-->';
  }

  public function viewsForm(array &$form, FormStateInterface $form_state) {
    $form[$this->options['id']]['#tree'] = TRUE;

    $wrapper_id = $this->view->current_display . 'ajax-loader-field';
    $form['#attached']['library'][] = 'core/jquery.form';
    $form['#attached']['library'][] = 'core/drupal.ajax';
    $form['#prefix'] = "<div id='$wrapper_id'>";
    $form['#suffix'] = "</div>";
    unset($form['actions']['submit']);

    foreach ($this->view->result as $row_index => $row) {
      $form[$this->options['id']][$row_index] = [
        '#type' => 'submit',
        '#value' => $this->t('Click Me!'),
        '#name' => 'ajax-loader-field' . $row_index,
        '#row_index' => $row_index,
        '#entity' => $this->getEntity($row),
        '#attributes' => [
          'class' => [
            'button--ajax-loader-field',
            'use-ajax-submit',
          ],
        ],
        '#ajax' => [
          'callback' => [get_called_class(), 'ajaxCallback'],
          'wrapper' => $wrapper_id,
          'url' => Url::fromUserInput($form['#action']),
          'options' => [
            'query' => [
              FormBuilderInterface::AJAX_FORM_REQUEST => TRUE,
            ],
          ],
        ],
      ];
    }
  }

  public static function ajaxCallback(array $form, FormStateInterface $form_state) {
    $response = new AjaxResponse();
    $response->addCommand(new MessageCommand('Response!'));
    return $response;
  }
}
πŸ‡ΊπŸ‡¦Ukraine EvilArgest

Thanks for the reply!

I haven't noticed any errors in the console since the update. I believe that the progressIsSet function prevents Ajax from firing more than 1 time for a single element.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

The new release had broken the behavior of the throbber for me.

I have an Ajaxified Views block, and every single result row has my custom Views field. This field has a submit element, that uses an Ajax callback. So, when I submit the row field for the first time, I can see that Ajax is working and the status message appears afterward. But when I click the submit for the second time, the Ajax Throbber does not appear and the status message simply shows after the callback was processed.

However, the Views block I was describing above also has Facets with exposed filters, but it had worked as a charm before the new release. There were no issues with the Ajax loader not being removed when it was supposed to be.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

Sorry, I did not name the previous patch appropriately, so here is one with the correct name

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ made their first commit to this issue’s fork.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ made their first commit to this issue’s fork.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

I created a fix to this module in terms of GCW23 in Lutsk. Changed core version requirement from 9.5 to 9.4.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

EvilArgest β†’ made their first commit to this issue’s fork.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

I created a fix to this module in terms of GCW23 in Lutsk. I merged the patch that grants functionality of checking access of links to user.

πŸ‡ΊπŸ‡¦Ukraine EvilArgest

I created a fix to this module in terms of GCW23 in Lutsk. In some case, user can get a notice that function strpos() is deprecated, so I added a function is_string() in hook_preprocess_container to prevent this.

Production build 0.69.0 2024