Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1441 ariadna 1
// This file is part of Moodle - http://moodle.org/
2
//
3
// Moodle is free software: you can redistribute it and/or modify
4
// it under the terms of the GNU General Public License as published by
5
// the Free Software Foundation, either version 3 of the License, or
6
// (at your option) any later version.
7
//
8
// Moodle is distributed in the hope that it will be useful,
9
// but WITHOUT ANY WARRANTY; without even the implied warranty of
10
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11
// GNU General Public License for more details.
12
//
13
// You should have received a copy of the GNU General Public License
14
// along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
15
 
16
import {dispatchEvent} from 'core/event_dispatcher';
17
 
18
/**
19
 * Reactive events for qbank_managecategories
20
 *
21
 * @module qbank_managecategories/events
22
 *
23
 */
24
export const eventTypes = {
25
    /**
26
     * Event triggered when the activity reactive state is updated.
27
     *
28
     * @event qbankManagecategoriesStateUpdated
29
     * @type {CustomEvent}
30
     * @property {Array} nodes The list of parent nodes which were updated
31
     */
32
    qbankManagecategoriesStateUpdated: 'qbank_managecategories/stateUpdated',
33
};
34
 
35
/**
36
 * Trigger an event to indicate that the activity state is updated.
37
 *
38
 * @method notifyQbankManagecategoriesStateUpdated
39
 * @param {Object} detail the full state
40
 * @param {HTMLElement} container the custom event target (document if none provided)
41
 * @returns {CustomEvent}
42
 * @fires qbankManagecategoriesStateUpdated
43
 */
44
export const notifyQbankManagecategoriesStateUpdated = (detail, container) => {
45
    return dispatchEvent(eventTypes.qbankManagecategoriesStateUpdated, detail, container);
46
};