机场选择列名数据绑定及查找定位数据过滤筛选
This commit is contained in:
@@ -5,6 +5,16 @@
|
||||
<div class="line-operator-left input-container mb-3 col-xlg-8 col-mlg-8 col-xl-8 col-lg-10">
|
||||
<select class="mr-4 form-control" [(ngModel)]="SEL_COL" name="" id="">
|
||||
<option value="">选择列名</option>
|
||||
<option value="airportCode">机场代码</option>
|
||||
<option value="airportNameChn">机场中文名</option>
|
||||
<option value="briefNameChn">中文简称</option>
|
||||
<option value="airportNameEng">机场英文名</option>
|
||||
<option value="briefNameEng">英文简称</option>
|
||||
<option value="airportCodeIata">IATA码</option>
|
||||
<option value="airportCodeCaa">CAA码</option>
|
||||
<option value="airportCodeIcao">ICAO码</option>
|
||||
<option value="airportGroupId">机场集团</option>
|
||||
<option value="cityId">所在城市</option>
|
||||
</select>
|
||||
<label class="radio-inline custom-radio nowrap mr-4">
|
||||
<input type="radio" [(ngModel)]="FLT_POS" [value]="1" name="filter-position">
|
||||
@@ -68,7 +78,8 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr *ngFor="let airport of render_data;let i = index">
|
||||
<tr *ngFor="let airport of render_data;let i = index" (click)="selectRow(airport)"
|
||||
[ngClass]="{'selected':row_state===airport}">
|
||||
<td>{{i+1}}</td>
|
||||
<td>{{airport.airportCode}}</td>
|
||||
<td>{{airport.airportNameChn}}</td>
|
||||
|
||||
@@ -49,6 +49,15 @@ ngOnInit() {
|
||||
}
|
||||
tableCont.addEventListener('scroll',scrollHandle);
|
||||
}
|
||||
|
||||
/**
|
||||
* 选中某行
|
||||
* @param i
|
||||
*/
|
||||
selectRow(i) {
|
||||
this.row_state = i;
|
||||
}
|
||||
|
||||
//输入框回车事件
|
||||
inputEnter() {
|
||||
if (this.FLT_POS === 1) {
|
||||
|
||||
Reference in New Issue
Block a user