Ajout des noms des dz ... dans la liste
des sauts
This commit is contained in:
BIN
Back/skydiveLogs-api/Data/JumpsDb-log.db
Normal file
BIN
Back/skydiveLogs-api/Data/JumpsDb-log.db
Normal file
Binary file not shown.
@@ -9,17 +9,21 @@
|
|||||||
<td mat-cell *matCellDef="let element">{{element.jumpDate | date: 'yyyy-MM-dd'}} </td>
|
<td mat-cell *matCellDef="let element">{{element.jumpDate | date: 'yyyy-MM-dd'}} </td>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
|
||||||
<ng-container matColumnDef="jumpTypeId">
|
<ng-container matColumnDef="jumpType">
|
||||||
<th mat-header-cell *matHeaderCellDef>Jump Type</th>
|
<th mat-header-cell *matHeaderCellDef>Jump Type</th>
|
||||||
<td mat-cell *matCellDef="let element">{{element.jumpTypeId}}</td>
|
<td mat-cell *matCellDef="let element">{{element.jumpType.name}}</td>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<ng-container matColumnDef="aircraftId">
|
<ng-container matColumnDef="aircraft">
|
||||||
<th mat-header-cell *matHeaderCellDef>Aircraft</th>
|
<th mat-header-cell *matHeaderCellDef>Aircraft</th>
|
||||||
<td mat-cell *matCellDef="let element">{{element.aircraftId}}</td>
|
<td mat-cell *matCellDef="let element">{{element.aircraft.name}}</td>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<ng-container matColumnDef="dropZoneId">
|
<ng-container matColumnDef="dropZone">
|
||||||
<th mat-header-cell *matHeaderCellDef>Drop Zone</th>
|
<th mat-header-cell *matHeaderCellDef>Drop Zone</th>
|
||||||
<td mat-cell *matCellDef="let element">{{element.dropZoneId}}</td>
|
<td mat-cell *matCellDef="let element">{{element.dropZone.name}}</td>
|
||||||
|
</ng-container>
|
||||||
|
<ng-container matColumnDef="gear">
|
||||||
|
<th mat-header-cell *matHeaderCellDef>Gear</th>
|
||||||
|
<td mat-cell *matCellDef="let element">{{element.gear.name}}</td>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
|
||||||
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
|
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
|
||||||
|
|||||||
@@ -1,25 +1,26 @@
|
|||||||
import { Component, OnInit, ViewChild } from '@angular/core';
|
import { Component, OnInit, ViewChild } from "@angular/core";
|
||||||
import { MatPaginator } from '@angular/material/paginator';
|
import { MatPaginator } from "@angular/material/paginator";
|
||||||
import { MatTableDataSource } from '@angular/material/table';
|
import { MatTableDataSource } from "@angular/material/table";
|
||||||
|
|
||||||
import { Observable } from 'rxjs';
|
import { Observable } from "rxjs";
|
||||||
import { JumpResp } from '../../models/jump';
|
import { JumpResp } from "../../models/jump";
|
||||||
import { ServiceApiGet } from '../../services/service-api-get.service';
|
import { ServiceApiGet } from "../../services/service-api-get.service";
|
||||||
import { ServiceComm } from '../../services/service-comm.service';
|
import { ServiceComm } from "../../services/service-comm.service";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-list-of-jumps',
|
selector: "app-list-of-jumps",
|
||||||
templateUrl: './list-of-jumps.component.html',
|
templateUrl: "./list-of-jumps.component.html",
|
||||||
styleUrls: ['./list-of-jumps.component.css']
|
styleUrls: ["./list-of-jumps.component.css"]
|
||||||
})
|
})
|
||||||
export class ListOfJumpsComponent implements OnInit {
|
export class ListOfJumpsComponent implements OnInit {
|
||||||
public listOfJumps: Observable<Array<JumpResp>>;
|
public listOfJumps: Observable<Array<JumpResp>>;
|
||||||
public displayedColumns: Array<string> = [
|
public displayedColumns: Array<string> = [
|
||||||
'id',
|
"id",
|
||||||
'jumpDate',
|
"jumpDate",
|
||||||
'jumpTypeId',
|
"jumpType",
|
||||||
'aircraftId',
|
"aircraft",
|
||||||
'dropZoneId'
|
"dropZone",
|
||||||
|
"gear"
|
||||||
];
|
];
|
||||||
public dataSourceTable;
|
public dataSourceTable;
|
||||||
public resultsLength = 0;
|
public resultsLength = 0;
|
||||||
@@ -28,10 +29,10 @@ export class ListOfJumpsComponent implements OnInit {
|
|||||||
constructor(
|
constructor(
|
||||||
private serviceApi: ServiceApiGet,
|
private serviceApi: ServiceApiGet,
|
||||||
private serviceComm: ServiceComm
|
private serviceComm: ServiceComm
|
||||||
) { }
|
) {}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
this.serviceComm.updatedComponentTitle('List of jumps');
|
this.serviceComm.updatedComponentTitle("List of jumps");
|
||||||
this.getListOfJumps();
|
this.getListOfJumps();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,8 @@
|
|||||||
|
import { GearResp } from "./gear";
|
||||||
|
import { DropZoneResp } from "./dropzone";
|
||||||
|
import { AircraftResp } from "./aircraft";
|
||||||
|
import { JumpTypeResp } from "./jumpType";
|
||||||
|
|
||||||
export class JumpReq {
|
export class JumpReq {
|
||||||
constructor(data: any) {
|
constructor(data: any) {
|
||||||
Object.assign(this, data);
|
Object.assign(this, data);
|
||||||
@@ -21,10 +26,10 @@ export class JumpResp {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public id: number;
|
public id: number;
|
||||||
public jumpTypeId: number;
|
public jumpType: JumpTypeResp;
|
||||||
public aircraftId: number;
|
public aircraft: AircraftResp;
|
||||||
public dropZoneId: number;
|
public dropZone: DropZoneResp;
|
||||||
public gearId: number;
|
public gear: GearResp;
|
||||||
public exitAltitude: number;
|
public exitAltitude: number;
|
||||||
public deployAltitude: number;
|
public deployAltitude: number;
|
||||||
public withCutaway: boolean;
|
public withCutaway: boolean;
|
||||||
|
|||||||
Reference in New Issue
Block a user