-
-
Notifications
You must be signed in to change notification settings - Fork 348
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
81 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
frontend-admin/src/app/org-selector/org-selector.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<div class="modal-header"> | ||
<h4 class="modal-title">Select organization</h4> | ||
<button type="button" class="btn-close" aria-label="Close" (click)="activeModal.dismiss('Cross click')"></button> | ||
</div> | ||
<div class="modal-body"> | ||
<ul> | ||
<li *ngFor="let org of organizations$ | async"> | ||
<button class="btn btn-link" (click)="selectOrganization(org)">{{org.name}}</button> | ||
</li> | ||
</ul> | ||
</div> | ||
<div class="modal-footer"> | ||
<button type="button" class="btn btn-outline-dark" (click)="activeModal.close('Close click')">Close</button> | ||
</div> |
Empty file.
25 changes: 25 additions & 0 deletions
25
frontend-admin/src/app/org-selector/org-selector.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { Component, OnInit } from '@angular/core'; | ||
import { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap'; | ||
import { Observable } from 'rxjs'; | ||
import { Organization } from '../model/organization'; | ||
|
||
@Component({ | ||
selector: 'app-org-selector', | ||
templateUrl: './org-selector.component.html', | ||
styleUrls: ['./org-selector.component.scss'] | ||
}) | ||
export class OrgSelectorComponent implements OnInit { | ||
|
||
public organizations$?: Observable<Organization[]>; | ||
public organizationId$?: Observable<string | null>; | ||
|
||
constructor(public activeModal: NgbActiveModal) { } | ||
|
||
ngOnInit(): void { | ||
} | ||
|
||
public selectOrganization(org: Organization): void { | ||
this.activeModal.close(org); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.