FINERACT-1780: Introduce Lombok to workingdays module

This commit is contained in:
neal.lee
2023-04-11 09:02:55 +09:00
parent 185551c572
commit 1d6a95f7ef
3 changed files with 10 additions and 58 deletions
@@ -19,7 +19,11 @@
package org.apache.fineract.organisation.workingdays.data;
import java.time.LocalDate;
import lombok.Getter;
import lombok.Setter;
@Setter
@Getter
public class AdjustedDateDetailsDTO {
/**
@@ -48,28 +52,4 @@ public class AdjustedDateDetailsDTO {
this.changedActualRepaymentDate = changedActualRepaymentDate;
this.nextRepaymentPeriodDueDate = nextRepaymentPeriodDueDate;
}
public LocalDate getChangedScheduleDate() {
return this.changedScheduleDate;
}
public LocalDate getChangedActualRepaymentDate() {
return this.changedActualRepaymentDate;
}
public void setChangedScheduleDate(final LocalDate changedScheduleDate) {
this.changedScheduleDate = changedScheduleDate;
}
public void setChangedActualRepaymentDate(final LocalDate changedActualRepaymentDate) {
this.changedActualRepaymentDate = changedActualRepaymentDate;
}
public LocalDate getNextRepaymentPeriodDueDate() {
return this.nextRepaymentPeriodDueDate;
}
public void setNextRepaymentPeriodDueDate(final LocalDate nextRepaymentPeriodDueDate) {
this.nextRepaymentPeriodDueDate = nextRepaymentPeriodDueDate;
}
}
@@ -20,7 +20,9 @@ package org.apache.fineract.organisation.workingdays.domain;
import java.util.HashMap;
import java.util.Map;
import lombok.Getter;
@Getter
public enum RepaymentRescheduleType {
INVALID(0, "RepaymentRescheduleType.invalid"), SAME_DAY(1, "RepaymentRescheduleType.same.day"), MOVE_TO_NEXT_WORKING_DAY(2,
@@ -37,14 +39,6 @@ public enum RepaymentRescheduleType {
this.code = code;
}
public Integer getValue() {
return this.value;
}
public String getCode() {
return this.code;
}
public boolean isMoveToNextRepaymentDay() {
return this.value.equals(RepaymentRescheduleType.MOVE_TO_NEXT_REPAYMENT_MEETING_DAY.getValue());
}
@@ -23,10 +23,13 @@ import java.util.Map;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import lombok.Getter;
import lombok.Setter;
import org.apache.fineract.infrastructure.core.api.JsonCommand;
import org.apache.fineract.infrastructure.core.domain.AbstractPersistableCustom;
import org.apache.fineract.organisation.workingdays.api.WorkingDaysApiConstants;
@Getter
@Entity
@Table(name = "m_working_days")
public class WorkingDays extends AbstractPersistableCustom {
@@ -34,6 +37,7 @@ public class WorkingDays extends AbstractPersistableCustom {
@Column(name = "recurrence", length = 100, nullable = true)
private String recurrence;
@Setter
@Column(name = "repayment_rescheduling_enum", nullable = false)
private Integer repaymentReschedulingType;
@@ -55,32 +59,6 @@ public class WorkingDays extends AbstractPersistableCustom {
this.extendTermForRepaymentsOnHolidays = extendTermForRepaymentsOnHolidays;
}
/**
* @return the recurrence
*/
public String getRecurrence() {
return this.recurrence;
}
/**
* @return the repaymentReschedulingType
*/
public Integer getRepaymentReschedulingType() {
return this.repaymentReschedulingType;
}
public void setRepaymentReschedulingType(Integer repaymentReschedulingType) {
this.repaymentReschedulingType = repaymentReschedulingType;
}
public Boolean getExtendTermForDailyRepayments() {
return this.extendTermForDailyRepayments;
}
public Boolean getExtendTermForRepaymentsOnHolidays() {
return this.extendTermForRepaymentsOnHolidays;
}
public Map<String, Object> update(final JsonCommand command) {
final Map<String, Object> actualChanges = new LinkedHashMap<>(7);