From 5efbcf0fd8d73c7698ec19ac5ed7a96673d85c1a Mon Sep 17 00:00:00 2001 From: marcos Date: Sat, 6 Jan 2018 15:08:34 -0300 Subject: [PATCH] Add editor button to PWD --- www/assets/app.js | 10 ++++++++- www/default/index.html | 50 +++++++++++++++++++++++------------------- 2 files changed, 36 insertions(+), 24 deletions(-) diff --git a/www/assets/app.js b/www/assets/app.js index 7b1d770..a63a4ff 100644 --- a/www/assets/app.js +++ b/www/assets/app.js @@ -440,7 +440,15 @@ }).finally(function() { updateDeleteInstanceBtnState(false); }); - } + }; + + $scope.openEditor = function(instance) { + console.log(instance); + var w = window.screen.availWidth * 45 / 100; + var h = window.screen.availHeight * 45 / 100; + $window.open('/sessions/' + instance.session_id + '/instances/'+instance.name+'/editor', 'editor', + 'width='+w+',height='+h+',resizable,scrollbars=yes,status=1'); + }; $scope.loadPlaygroundConf(); $scope.getSession($scope.sessionId); diff --git a/www/default/index.html b/www/default/index.html index edac4fe..7ce6556 100644 --- a/www/default/index.html +++ b/www/default/index.html @@ -119,7 +119,10 @@ SSH Copy! - + + insert_drive_file Editor + +
@@ -180,29 +183,30 @@ -
-
- -
-
-
- {{errorMessage}} -
-
- - - - - - {{template.title}} - - -
+
+
+ +
+
+
+ {{errorMessage}} +
+
+ + + + + + {{template.title}} + + +
-
-
-
-
+ + + + +