mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-27 09:06:15 +01:00
fix: #11773, fix create token button
This commit is contained in:
@@ -13,6 +13,8 @@ define('admin/settings/api', ['settings', 'clipboard', 'bootbox', 'benchpress',
|
|||||||
const copyEls = document.querySelectorAll('[data-component="acp/tokens"] [data-action="copy"]');
|
const copyEls = document.querySelectorAll('[data-component="acp/tokens"] [data-action="copy"]');
|
||||||
new clipboard(copyEls);
|
new clipboard(copyEls);
|
||||||
|
|
||||||
|
$('[data-action="create"]').on('click', handleTokenCreation);
|
||||||
|
|
||||||
handleActions();
|
handleActions();
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -28,10 +30,6 @@ define('admin/settings/api', ['settings', 'clipboard', 'bootbox', 'benchpress',
|
|||||||
const action = subselector.getAttribute('data-action');
|
const action = subselector.getAttribute('data-action');
|
||||||
|
|
||||||
switch (action) {
|
switch (action) {
|
||||||
case 'create':
|
|
||||||
handleTokenCreation();
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 'edit':
|
case 'edit':
|
||||||
handleTokenUpdate(subselector);
|
handleTokenUpdate(subselector);
|
||||||
break;
|
break;
|
||||||
|
|||||||
Reference in New Issue
Block a user