Skip to content

Commit

Permalink
πŸ› Bug(owner): add tenant salary to property mapper (#744)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattboll authored Apr 17, 2024
1 parent 758a156 commit fc6c8e9
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package fr.dossierfacile.api.dossierfacileapiowner.property;

import fr.dossierfacile.common.entity.ApartmentSharing;
import fr.dossierfacile.common.entity.Property;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.springframework.stereotype.Component;

@Component
Expand All @@ -10,4 +12,7 @@ public abstract class PropertyMapper {

public abstract PropertyModel toPropertyModel(Property property);

@Mapping( target="totalSalary", expression="java(apartmentSharing.totalSalary())" )
@Mapping( target="totalGuarantorSalary", expression="java(apartmentSharing.totalGuarantorSalary())" )
public abstract ApartmentSharingModel apartmentSharingToApartmentSharingModel(ApartmentSharing apartmentSharing);
}

0 comments on commit fc6c8e9

Please sign in to comment.