mirror of
https://github.com/jupyterhub/jupyterhub.git
synced 2025-10-15 05:53:00 +00:00
move static resources to share/jupyterhub
from share/jupyter/hub to be consistent with use of etc/jupyterhub etc.
This commit is contained in:
19
share/jupyterhub/static/js/token.js
Normal file
19
share/jupyterhub/static/js/token.js
Normal file
@@ -0,0 +1,19 @@
|
||||
// Copyright (c) Jupyter Development Team.
|
||||
// Distributed under the terms of the Modified BSD License.
|
||||
|
||||
require(["jquery", "jhapi"], function ($, JHAPI) {
|
||||
"use strict";
|
||||
|
||||
var base_url = window.jhdata.base_url;
|
||||
var user = window.jhdata.user;
|
||||
var api = new JHAPI(base_url);
|
||||
|
||||
$("#request-token").click(function () {
|
||||
api.request_token({
|
||||
success: function (reply) {
|
||||
$("#token-result").text(reply.token);
|
||||
$("#token-area").show();
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
Reference in New Issue
Block a user