This is an automated email from the ASF dual-hosted git repository. dgnatyshyn pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git
The following commit(s) were added to refs/heads/develop by this push: new c03a9c1 Added log for opening terminal(UI) c03a9c1 is described below commit c03a9c1a7f91a17e052bbc642c687c103ea91a2c Author: Dmytro_Gnatyshyn <di1...@ukr.net> AuthorDate: Tue Jul 7 17:45:41 2020 +0300 Added log for opening terminal(UI) --- .../src/app/resources/resources-grid/resources-grid.component.html | 2 +- .../src/app/resources/resources-grid/resources-grid.component.ts | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html index f7b6b34..2f9088c 100644 --- a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html +++ b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html @@ -208,7 +208,7 @@ <i class="material-icons">developer_board</i> <span>Manage libraries</span> </li> - <li *ngIf="element.status === 'running'"> + <li *ngIf="element.status === 'running'" (click)="logAction(element.name)"> <a target="_blank" [attr.href]="'/#/terminal/' + element.private_ip + '/' + element.endpoint" class="navigate"> <i class="material-icons">laptop</i> diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts index c67f019..a354c40 100644 --- a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts +++ b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts @@ -39,6 +39,7 @@ import { DICTIONARY } from '../../../dictionary/global.dictionary'; import {ProgressBarService} from '../../core/services/progress-bar.service'; import {ComputationModel} from '../computational/computational-resource.model'; import {NotebookModel} from '../exploratory/notebook.model'; +import {AuditService} from '../../core/services/audit.service'; export interface SharedEndpoint { edge_node_ip: string; @@ -123,6 +124,7 @@ export class ResourcesGridComponent implements OnInit { private dialog: MatDialog, private progressBarService: ProgressBarService, private projectService: ProjectService, + private auditService: AuditService, ) { } ngOnInit(): void { @@ -413,4 +415,8 @@ export class ResourcesGridComponent implements OnInit { .subscribe(() => { }, (error) => console.log('UPDATE USER PREFERENCES ERROR ', error)); } + + logAction(name) { + this.auditService.sendDataToAudit({resource_name: name, info: `Open terminal on notebook ${name}`, type: 'WEB_TERMINAL'}).subscribe(); + } } --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@dlab.apache.org For additional commands, e-mail: commits-h...@dlab.apache.org