解决冲突
This commit is contained in:
@ -1299,4 +1299,28 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
}
|
||||
getInsurersPrice() {
|
||||
console.log(this.sf5.value.goodsValue)
|
||||
console.log(this.sf5.value.insuranceType)
|
||||
if (this.sf5.value.goodsValue >= 50000) {
|
||||
if(this.totalDistance <=0){
|
||||
this.service.msgSrv.warning('当前装卸货距离为0,无法计算保价费金额');
|
||||
return;
|
||||
}
|
||||
const params = {
|
||||
goodsValue: this.sf5.value.goodsValue,
|
||||
insuranceType: this.sf5.value.insuranceType,
|
||||
km: this.totalDistance
|
||||
};
|
||||
this.service.request(this.service.$api_getWholeInsuranceInfo, params).subscribe(res => {
|
||||
if (res) {
|
||||
this.sf5.setValue('/insurancePremium', res.insurancePremium);
|
||||
this.sf5.setValue('/insuranceRate', res.insuranceRate);
|
||||
} else {
|
||||
this.sf5.setValue('/insurancePremium', null);
|
||||
this.sf5.setValue('/insuranceRate', null);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user