<div class= "Common-line-div" >
<div class= "Main-line-div" >
<span class= "Left" >
Guarantee method
</span>
<span class= "Common-right-input right" id= "promise" ></span>
</div>
</div>
Data () {
return {
Leasestyle:[{id: ' 1 ', Value: ' Guarantee '}, {id: ' 2 ', Value: ' Credit '}, {id: ' 3 ', Value: ' Collateral '}, {ID: ' 4 ', Value: ' Pledge '}],
}
}
Getcreditdetails () {
this. $ajax ({
URL: "/api/credit/detail/" + this. $route. Query.businessidchange
},res = {
if (Res.code = = 1) {
When the data is retrieved because the ID value of the object is saved, the filter is filtered to the array object to be rendered when rendering.
Finally, the value of that object is output to the page.
var _value = this.leaseData.filter (item = (Item.id = = Res.data.leaseStyle));
$ ("#repayment"). HTML (_value[0].value);
}else{
this. $alert ("Error!");
}
});
Project Practice on Fitler