Ajout du piège dans le formulaire
d'ajout de sauts
This commit is contained in:
@@ -27,10 +27,11 @@
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Choose the used Rig</mat-label>
|
||||
<mat-select [(ngModel)]="selectedRig" name="selectedRig">
|
||||
<mat-option value="8">Option 1</mat-option>
|
||||
<mat-option value="9">Option 3</mat-option>
|
||||
<mat-label>Choose the used gear</mat-label>
|
||||
<mat-select [(ngModel)]="selectedGear" name="selectedGear">
|
||||
<mat-option *ngFor="let gear of listOfGear" [value]="gear.id">
|
||||
{{gear.name}}
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import { JumpTypeResp } from "../../models/jumpType";
|
||||
import { AircraftResp } from "../../models/aircraft";
|
||||
import { DropZoneResp } from "../../models/dropzone";
|
||||
import { DateService } from "../../services/date.service";
|
||||
import { GearResp } from "../../models/gear";
|
||||
|
||||
@Component({
|
||||
selector: "app-new-jump",
|
||||
@@ -19,13 +20,14 @@ export class NewJumpComponent implements OnInit {
|
||||
defaultDeployAltitude: number;
|
||||
countOfJumps: number;
|
||||
selectedDz: number;
|
||||
selectedRig: number;
|
||||
selectedGear: number;
|
||||
selectedAircraft: number;
|
||||
selectedJumpType: number;
|
||||
withCutaway: boolean;
|
||||
listOfJumpType: Array<JumpTypeResp>;
|
||||
listOfAircraft: Array<AircraftResp>;
|
||||
listOfDropZone: Array<DropZoneResp>;
|
||||
listOfGear: Array<GearResp>;
|
||||
|
||||
constructor(
|
||||
private serviceComm: ServiceComm,
|
||||
@@ -53,7 +55,7 @@ export class NewJumpComponent implements OnInit {
|
||||
this.selectedJumpType,
|
||||
this.selectedAircraft,
|
||||
this.selectedDz,
|
||||
this.selectedRig,
|
||||
this.selectedGear,
|
||||
this.withCutaway,
|
||||
this.beginDate,
|
||||
this.endDate,
|
||||
@@ -68,6 +70,7 @@ export class NewJumpComponent implements OnInit {
|
||||
this.listOfJumpType = data;
|
||||
this.getListOfAircrafts();
|
||||
this.getListOfDropZones();
|
||||
this.getListOfGears();
|
||||
});
|
||||
}
|
||||
|
||||
@@ -83,10 +86,9 @@ export class NewJumpComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
|
||||
// private getListOfGears() {
|
||||
// this.serviceApiGet.getListOfGears()
|
||||
// .subscribe(data => {
|
||||
// this.listOfGear = data;
|
||||
// });
|
||||
// }
|
||||
private getListOfGears() {
|
||||
this.serviceApiGet.getListOfGears().subscribe(data => {
|
||||
this.listOfGear = data;
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ export class AircraftReq {
|
||||
}
|
||||
|
||||
public id: number;
|
||||
public name: number;
|
||||
public name: string;
|
||||
}
|
||||
|
||||
export class AircraftResp {
|
||||
@@ -13,5 +13,5 @@ export class AircraftResp {
|
||||
}
|
||||
|
||||
public id: number;
|
||||
public name: number;
|
||||
public name: string;
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ export class GearReq {
|
||||
}
|
||||
|
||||
public id: number;
|
||||
public name: number;
|
||||
public name: string;
|
||||
}
|
||||
|
||||
export class GearResp {
|
||||
@@ -13,5 +13,5 @@ export class GearResp {
|
||||
}
|
||||
|
||||
public id: number;
|
||||
public name: number;
|
||||
public name: string;
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ export class JumpTypeReq {
|
||||
}
|
||||
|
||||
public id: number;
|
||||
public name: number;
|
||||
public name: string;
|
||||
}
|
||||
|
||||
export class JumpTypeResp {
|
||||
@@ -13,5 +13,5 @@ export class JumpTypeResp {
|
||||
}
|
||||
|
||||
public id: number;
|
||||
public name: number;
|
||||
public name: string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user