add member avec role ok account récupère les membre en focntion de la team
This commit is contained in:
parent
7784870446
commit
466a146174
6 changed files with 56 additions and 18 deletions
|
|
@ -7,6 +7,7 @@ import {
|
|||
} from '@angular/forms';
|
||||
import { Router } from '@angular/router';
|
||||
import { Team } from 'src/app/models/team';
|
||||
import { MembreService } from 'src/app/services/membre.service';
|
||||
import { TeamService } from 'src/app/services/team.service';
|
||||
|
||||
@Component({
|
||||
|
|
@ -18,6 +19,7 @@ export class PageCreationTeamComponent implements OnInit {
|
|||
public teamForm: FormGroup;
|
||||
constructor(
|
||||
private teamService: TeamService,
|
||||
private membreService: MembreService,
|
||||
private router: Router,
|
||||
private fb: FormBuilder
|
||||
) {
|
||||
|
|
@ -39,9 +41,6 @@ export class PageCreationTeamComponent implements OnInit {
|
|||
const team: Team = {
|
||||
nom : nameValue,
|
||||
};
|
||||
|
||||
|
||||
|
||||
if (team.nom !== '' ) {
|
||||
this.teamService.addTeam(team).subscribe((resp) => {
|
||||
this.router.navigate(['compte']);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue