Commit b575a951 authored by frtabu's avatar frtabu

Merge branch 'websrv' of https://gitlab.eurecom.fr/oai/openairinterface5g into websrv

parents c239d99f fc3319c9
......@@ -10,7 +10,7 @@
],
"parserOptions": {
"project": [
"openairinterface5g/common/utils/websrv/frontend/tsconfig.json"
"./tsconfig.json"
],
"createDefaultProgram": true
},
......
<h1 mat-dialog-title>Status</h1>
<!-- <div *ngIf="infos$ | async as infos"> -->
<div *ngIf="infos$ | async as infos">
<p> config_file: {{ infos.display_status.config_file }}</p>
<p> executable_function: {{ infos.display_status.executable_function }}</p>
<h1 mat-dialog-title>Status</h1>
<p> config_file: {{ infos.display_status.config_file }}</p>
<p> executable_function: {{ infos.display_status.executable_function }}</p>
<mat-form-field>
<mat-label>Command</mat-label>
<mat-select [formControl]="selectedCmd!.value" [value]="selectedCmd!.value">
<mat-option *ngFor="let control of infos.cmdsFA.controls" [value]="control.value">{{ control.value }}</mat-option>
</mat-select>
</mat-form-field>
</div>
\ No newline at end of file
<h1 mat-dialog-title>Commands</h1>
<mat-form-field>
<mat-label>Command</mat-label>
<mat-select [formControl]="selectedCmd?.value" [value]="selectedCmd?.value">
<mat-option *ngFor="let control of infos.cmdsFA.controls" [value]="control.value">{{ control.value }}
</mat-option>
</mat-select>
</mat-form-field>
\ No newline at end of file
......@@ -2,10 +2,8 @@
/* eslint-disable no-shadow */
/* eslint-disable eqeqeq */
/* eslint-disable @typescript-eslint/naming-convention */
import { Component } from '@angular/core';
import { Component, OnInit } from '@angular/core';
import { FormControl } from '@angular/forms';
import { Observable } from 'rxjs';
import { map, tap } from 'rxjs/operators';
import { CommandsApi } from 'src/app/api/commands.api';
import { InfosCtrl } from 'src/app/controls/infos.control';
import { LoadingService } from 'src/app/services/loading.service';
......@@ -18,16 +16,33 @@ import { LoadingService } from 'src/app/services/loading.service';
})
export class CommandsComponent {
infos$: Observable<InfosCtrl>
// infos$: Observable<InfosCtrl>
infos: InfosCtrl
selectedCmd?: FormControl
constructor(
public commandsApi: CommandsApi,
public loadingService: LoadingService,
) {
this.infos$ = this.commandsApi.readInfos$().pipe(
map((doc) => new InfosCtrl(doc)),
);
}
// this.infos$ = this.commandsApi.readInfos$().pipe(
// map((doc) => new InfosCtrl(doc)),
// );
this.infos = new InfosCtrl({
display_status: {
config_file: '../../../ci-scripts/conf_files/gnb.band78.sa.fr1.106PRB.usrpn310.conf',
executable_function: "gnb"
},
menu_cmds: [
"telnet",
"softmodem",
"loader",
"measur",
"rfsimu"
]
})
// console.log(JSON.stringify(this.infos, null, 2))
}
}
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