【发布时间】:2020-03-13 19:06:33
【问题描述】:
我有以下返回数据的预输入
<input [(ngModel)]="model" [class.is-invalid]="searchFailed" [inputFormatter]="inputFormatBandListValue"
[ngbTypeahead]="search" [resultFormatter]="resultFormatBandListValue" class="form-control"
id="typeahead-http"
name="Search" placeholder="Search" type="text" value="search"/>
<!-- <small *ngIf="searching" class="form-text text-muted">searching...</small>-->
<img *ngIf="searching" alt="Loading Icon" src="assets/img/user/loading.gif">
<div>
<p>{{model | json}}</p>
</div>
<input class="form-control" id="manufyear" name="manufyear" type="text">
<input class="form-control" id="location" name="location" type="text">
json格式{"Vehicle Name": "TOYOTA PRADO","MANUFACTURED YEAR":"2010", "LOCATION":"TOKYO"}
如何绑定其他输入字段,以便当用户从自动完成输入中选择一个 vlue 时,其他字段会填充来自该选择的数据。我希望是清楚的家伙。
【问题讨论】: