OAuth and something

This commit is contained in:
Cutls 2019-06-25 23:16:12 +09:00
parent 0f2c5de161
commit fa2d5f8492
3 changed files with 2 additions and 21 deletions

View File

@ -304,7 +304,7 @@ function login(url) {
return; return;
} }
if ($('#linux:checked').val() == "on") { if ($('#linux:checked').val() == "on") {
var red = "https://thedesk.top/hello.html" var red = "urn:ietf:wg:oauth:2.0:oob"
} else { } else {
var red = 'thedesk://manager'; var red = 'thedesk://manager';
} }
@ -508,7 +508,7 @@ function code(code) {
httpreq.responseType = "json"; httpreq.responseType = "json";
httpreq.send(JSON.stringify({ httpreq.send(JSON.stringify({
grant_type: "authorization_code", grant_type: "authorization_code",
redirect_uri: "https://thedesk.top/hello.html", redirect_uri: "urn:ietf:wg:oauth:2.0:oob",
client_id: id, client_id: id,
client_secret: secret, client_secret: secret,
code: code code: code

View File

@ -64,9 +64,6 @@ ipc.on('platform', function (event, args) {
localStorage.setItem("bit", args[1]) localStorage.setItem("bit", args[1])
localStorage.setItem("about", JSON.stringify([args[2], args[3], args[4]])) localStorage.setItem("about", JSON.stringify([args[2], args[3], args[4]]))
}) })
ipc.on('winstore', function (event, arg) {
localStorage.setItem("winstore", arg)
})
ipc.on('reload', function (event, arg) { ipc.on('reload', function (event, arg) {
location.reload(); location.reload();

View File

@ -51,22 +51,6 @@ function system(mainWindow, dir, lang, dirname) {
fs.writeFileSync(lang_path, arg); fs.writeFileSync(lang_path, arg);
e.sender.webContents.send('langres', ""); e.sender.webContents.send('langres', "");
}) })
//ストアから入れたかダイアログ
ipc.on('dialogStore', function (e, args) {
dialog.showMessageBox(args, function (arg) {
if (arg == 1) {
e.sender.webContents.send('winstore', "winstore");
} else {
e.sender.webContents.send('winstore', "localinstall");
}
});
})
//CWのダイアログ
ipc.on('dialogCW', function (e, args) {
dialog.showMessageBox(args, function (arg) {
e.sender.webContents.send('dialogCWRender', arg);
});
})
//クライアントのダイアログ //クライアントのダイアログ
ipc.on('dialogClient', function (e, args) { ipc.on('dialogClient', function (e, args) {
dialog.showMessageBox(args, function (arg) { dialog.showMessageBox(args, function (arg) {