forked from Yara724/api
feat(depreciation): apply Fanavaran tables and age eligibility
Use the supplied part, severity and age codes for depreciation. Exclude vehicles older than ten from calculated and manual amounts, preserve historical assessments, and send zero depreciation to Fanavaran for ineligible vehicles.
This commit is contained in:
@@ -276,6 +276,27 @@ export const ClaimFileRatingSchema =
|
||||
|
||||
@Schema({ _id: false })
|
||||
export class ClaimPriceDrop {
|
||||
@Prop({ type: Boolean })
|
||||
eligible?: boolean;
|
||||
|
||||
@Prop({ type: String })
|
||||
exclusionReason?: string;
|
||||
|
||||
@Prop({ type: Boolean })
|
||||
manualOverride?: boolean;
|
||||
|
||||
@Prop({ type: String })
|
||||
calculationVersion?: string;
|
||||
|
||||
@Prop({ type: Number })
|
||||
vehicleAge?: number;
|
||||
|
||||
@Prop({ type: Number })
|
||||
fanavaranAgeId?: number;
|
||||
|
||||
@Prop({ type: Number })
|
||||
accidentYear?: number;
|
||||
|
||||
@Prop({ type: Number })
|
||||
total?: number;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user