@@ -0,0 +1,1426 @@
+package io.teiler.server.persistence.entities;%0A%0Aimport javax.persistence.DiscriminatorValue;%0Aimport javax.persistence.Entity;%0A%0Aimport io.teiler.server.dto.Compensation;%0Aimport io.teiler.server.dto.TransactionType;%0Aimport io.teiler.server.util.TimeUtil;%0A%0A/**%0A * Entity representing a Compensation-entry of the %3Ccode%3Etransaction%3C/code%3E-table.%0A * %0A * @author pbaechli%0A */%0A@Entity%0A@DiscriminatorValue(%22COMPENSATION%22)%0Apublic class CompensationEntity extends TransactionEntity %7B%0A%0A    public CompensationEntity() %7B /* intentionally empty */ %7D%0A%0A    public CompensationEntity(Compensation compensation) %7B%0A        super.setId(compensation.getId());%0A        super.setPayer(new PersonEntity(compensation.getPayer()));%0A        super.setUpdateTime(TimeUtil.convertToTimestamp(compensation.getUpdateTime()));%0A        super.setCreateTime(TimeUtil.convertToTimestamp(compensation.getCreateTime()));%0A        super.setTransactionType(TransactionType.EXPENSE);%0A    %7D%0A%0A    /**%0A     * Converts this %7B@link CompensationEntity%7D to a %7B@link Compensation%7D.%0A     * %0A     * @return %7B@link Compensation%7D%0A     */%0A    public Compensation toCompensation() %7B%0A        return new Compensation(getId(), getAmount(), getPayer().toPerson(),%0A                TimeUtil.convertToLocalDateTime(getUpdateTime()),%0A                TimeUtil.convertToLocalDateTime(getCreateTime()),%0A                getProfiteers().get(0).toProfiteer()); // TODO uber-hack incoming%0A    %7D%0A%0A%7D%0A

add compensation entity (#164)