This repository was archived by the owner on Jan 29, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ <h5 *ngIf="info && info.length > 0 && info !== 'team'" class='name center'>
62
62
< div class ="col-sm-6 promote typeahead ">
63
63
< mat-form-field appearance ="fill " style ="width: 100%; background-color: white; ">
64
64
< mat-label > Search for company</ mat-label >
65
- < mat-select name ="searchCompany " id ="searchCompany " name =" searchCompany " [(ngModel)] ="searchedCompany ">
65
+ < mat-select name ="searchCompany " id ="searchCompany " [(ngModel)] ="searchedCompany ">
66
66
< input (keyup) ="onKey($event.target.value) " style ="width: 100%; ">
67
67
< mat-option *ngFor ="let comp of selectedCompanies " [value] ="comp ">
68
68
{{ comp.name }}
Original file line number Diff line number Diff line change @@ -180,11 +180,11 @@ export class PromoteComponent implements OnInit {
180
180
}
181
181
182
182
onKey ( value ) {
183
- this . selectedCompanies = this . search ( value . name ) ;
183
+ this . selectedCompanies = this . search ( value ) ;
184
184
}
185
185
186
- search ( value : Company ) {
187
- let filter = value . name . toLowerCase ( ) ;
186
+ search ( value : string ) {
187
+ let filter = value . toLowerCase ( ) ;
188
188
return this . companies . filter ( comp => comp . name . toLowerCase ( ) . includes ( filter ) ) ;
189
189
}
190
190
}
You can’t perform that action at this time.
0 commit comments