Commit 629733c4 authored by zheng liu's avatar zheng liu

Merged in dev (pull request #76)

revert: base still need here
parents 775834f1 95deb288
...@@ -29,7 +29,6 @@ export class ElementGuacamoleComponent implements OnInit { ...@@ -29,7 +29,6 @@ export class ElementGuacamoleComponent implements OnInit {
ngOnInit() { ngOnInit() {
// /guacamole/api/tokens will redirect to http://guacamole/api/tokens // /guacamole/api/tokens will redirect to http://guacamole/api/tokens
const base = window.btoa(this.host.id + '\0' + 'c' + '\0' + 'jumpserver');
if (this.token) { if (this.token) {
this.userid = this._localStorage.get('user'); this.userid = this._localStorage.get('user');
this._http.get_guacamole_token(this.userid).subscribe( this._http.get_guacamole_token(this.userid).subscribe(
...@@ -46,6 +45,7 @@ export class ElementGuacamoleComponent implements OnInit { ...@@ -46,6 +45,7 @@ export class ElementGuacamoleComponent implements OnInit {
); );
}); });
} else { } else {
const base = window.btoa(this.host.id + '\0' + 'c' + '\0' + 'jumpserver');
if (environment.production) { if (environment.production) {
if (DataStore.guacamole_token) { if (DataStore.guacamole_token) {
this._http.guacamole_add_asset(User.id, this.host.id, this.userid).subscribe( this._http.guacamole_add_asset(User.id, this.host.id, this.userid).subscribe(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment