Allow users to clear the bulk inserting state flag on the UI

Created on 23 January 2025, about 1 month ago

This is a follow-up from πŸ“Œ Add the ability to bulk insert to EntityUsage service Active . There we added the ability to do bulk inserts, and use that when regenerating all usages in batch. In order to signal the batch process is bulk inserting, we use a state flag:

      if ($bulk_mode) {
        \Drupal::state()->set('entity_usage.bulk_inserting.' . $entity_type_id, TRUE);
      }

which we clear when the batch finishes. However, in cases where the batch process could be interrupted for any reason, this state flag could get stuck as active, when there is no real bulk inserting happening.

Let's create a secondary button on the Batch Update form ( /admin/config/entity-usage/batch-update ) that will just reset this flag to FALSE when clicked.

πŸ“Œ Task
Status

Active

Version

2.0

Component

Code

Created by

πŸ‡ͺπŸ‡ΈSpain marcoscano Barcelona, Spain

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024