-
Notifications
You must be signed in to change notification settings - Fork 13
/
doget.html
31 lines (29 loc) · 1.28 KB
/
doget.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<head>
<link rel="stylesheet" href="https://ssl.gstatic.com/docs/script/css/add-ons1.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.js"></script>
<style>
h1 {position: relative; padding: 10px; background: #1e90ff; color: white; font-size: 1.5em;}
#overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; margin: auto; display: none; width: 100%; height:100%; text-align: center; z-index: 100; background: rgba(104,158,255,0.8);}
.waitmsg { font-size: 20px; color: #eee; padding-top: 300px; vertical-align: middle; font-weight: bold;}
</style>
</head>
<body>
<div id="overlay"><p class="waitmsg">Just a moment.</p></div>
<h1>Retrieving access token and refresh token was succeeded!</h1>
<p id="msg"></p>
<pre id="done"></pre>
<h3 id="end"></h3>
</body>
<script>
$(function() {
$("#overlay").fadeIn();
google.script.run.withSuccessHandler(done).doGet(["doget", <?= JSON.stringify(data) ?>]);
});
function done(){
$("#overlay").fadeOut('fast').queue(function() {
$('#msg').text("You can use OnedriveApp. Your access token and refresh token are as follows. These were saved to your PropertiesService.");
$('#done').text(<?= JSON.stringify(data, null, " ") ?>);
$('#end').text("Please close this window.");
});
}
</script>