Welcome to mirror list, hosted at ThFree Co, Russian Federation.

issuable_init_bulk_update_sidebar.js « bulk_update_sidebar « issuable « javascripts « assets « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 179c2b83c6ca39770ec2d43537e03f29ed48c291 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import issuableBulkUpdateActions from './issuable_bulk_update_actions';
import IssuableBulkUpdateSidebar from './issuable_bulk_update_sidebar';

export default {
  bulkUpdateSidebar: null,

  init(prefixId) {
    const bulkUpdateEl = document.querySelector('.issues-bulk-update');
    const alreadyInitialized = Boolean(this.bulkUpdateSidebar);

    if (bulkUpdateEl && !alreadyInitialized) {
      issuableBulkUpdateActions.init({ prefixId });

      this.bulkUpdateSidebar = new IssuableBulkUpdateSidebar();
    }

    return this.bulkUpdateSidebar;
  },
};