tidy up by moving mifosng-data files back into platform project.

This commit is contained in:
Keith Woodlock
2012-05-30 16:50:45 +01:00
parent 6a0f4b3f6f
commit bdb549253c
66 changed files with 76 additions and 96 deletions
@@ -4,7 +4,7 @@ import java.math.BigDecimal;
import java.util.List;
import org.apache.commons.lang.StringUtils;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.data.ApiParameterError;
import org.springframework.util.ObjectUtils;
public class DataValidatorBuilder {
@@ -23,11 +23,11 @@ import org.codehaus.jettison.json.JSONArray;
import org.codehaus.jettison.json.JSONException;
import org.codehaus.jettison.json.JSONObject;
import org.mifosng.data.AdditionalFieldsSet;
import org.mifosng.data.ApiParameterError;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.data.reports.GenericResultset;
import org.mifosng.platform.InvalidSqlException;
import org.mifosng.platform.ReadExtraDataAndReportingService;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.api.infrastructure.ApiJSONFormattingService;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
import org.slf4j.Logger;
@@ -18,11 +18,11 @@ import javax.ws.rs.core.UriInfo;
import org.joda.time.LocalDate;
import org.mifosng.data.ClientLoanAccountSummaryCollectionData;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.data.NoteData;
import org.mifosng.platform.api.commands.ClientCommand;
import org.mifosng.platform.api.commands.NoteCommand;
import org.mifosng.platform.api.data.ClientData;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.api.data.NoteData;
import org.mifosng.platform.api.data.OfficeLookup;
import org.mifosng.platform.api.infrastructure.ApiDataConversionService;
import org.mifosng.platform.api.infrastructure.ApiJSONFormattingService;
@@ -10,8 +10,8 @@ import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import javax.ws.rs.core.UriInfo;
import org.mifosng.data.ConfigurationData;
import org.mifosng.platform.api.commands.OrganisationCurrencyCommand;
import org.mifosng.platform.api.data.ConfigurationData;
import org.mifosng.platform.api.infrastructure.ApiJSONFormattingService;
import org.mifosng.platform.configuration.service.ConfigurationReadPlatformService;
import org.mifosng.platform.configuration.service.ConfigurationWritePlatformService;
@@ -16,8 +16,8 @@ import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import javax.ws.rs.core.UriInfo;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.LoanProductCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.api.data.LoanProductData;
import org.mifosng.platform.api.infrastructure.ApiDataConversionService;
import org.mifosng.platform.api.infrastructure.ApiJSONFormattingService;
@@ -18,7 +18,6 @@ import javax.ws.rs.core.UriInfo;
import org.apache.commons.lang.StringUtils;
import org.joda.time.LocalDate;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.data.LoanAccountData;
import org.mifosng.data.LoanRepaymentData;
import org.mifosng.data.LoanSchedule;
@@ -28,7 +27,8 @@ import org.mifosng.platform.api.commands.LoanStateTransitionCommand;
import org.mifosng.platform.api.commands.LoanTransactionCommand;
import org.mifosng.platform.api.commands.SubmitLoanApplicationCommand;
import org.mifosng.platform.api.commands.UndoStateTransitionCommand;
import org.mifosng.platform.api.data.NewLoanWorkflowStepOneData;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.api.data.NewLoanData;
import org.mifosng.platform.api.infrastructure.ApiDataConversionService;
import org.mifosng.platform.api.infrastructure.ApiJSONFormattingService;
import org.mifosng.platform.exceptions.UnrecognizedQueryParamException;
@@ -76,7 +76,7 @@ public class LoansApiResource {
@QueryParam("productId") final Long productId,
@Context UriInfo uriInfo) {
NewLoanWorkflowStepOneData workflowData = this.loanReadPlatformService
NewLoanData workflowData = this.loanReadPlatformService
.retrieveClientAndProductDetails(clientId, productId);
String selectedFields = "";
@@ -16,8 +16,8 @@ import javax.ws.rs.core.Response;
import javax.ws.rs.core.UriInfo;
import org.joda.time.LocalDate;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.OfficeCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.api.data.OfficeData;
import org.mifosng.platform.api.infrastructure.ApiDataConversionService;
import org.mifosng.platform.api.infrastructure.ApiJSONFormattingService;
@@ -15,8 +15,8 @@ import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import javax.ws.rs.core.UriInfo;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.RoleCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.api.data.PermissionData;
import org.mifosng.platform.api.data.RoleData;
import org.mifosng.platform.api.infrastructure.ApiJSONFormattingService;
@@ -15,9 +15,9 @@ import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import javax.ws.rs.core.UriInfo;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.UserCommand;
import org.mifosng.platform.api.data.AppUserData;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.api.infrastructure.ApiJSONFormattingService;
import org.mifosng.platform.user.service.AppUserReadPlatformService;
import org.mifosng.platform.user.service.AppUserWritePlatformService;
@@ -1,8 +1,6 @@
package org.mifosng.data;
package org.mifosng.platform.api.data;
import javax.xml.bind.annotation.XmlRootElement;
@XmlRootElement(name="messageArg")
public class ApiErrorMessageArg {
/**
@@ -1,16 +1,14 @@
package org.mifosng.data;
package org.mifosng.platform.api.data;
import java.util.ArrayList;
import java.util.List;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlElementWrapper;
import javax.xml.bind.annotation.XmlRootElement;
/**
*
*/
@XmlRootElement
public class ApiGlobalErrorResponse {
/**
@@ -1,11 +1,8 @@
package org.mifosng.data;
package org.mifosng.platform.api.data;
import java.util.ArrayList;
import java.util.List;
import javax.xml.bind.annotation.XmlRootElement;
@XmlRootElement(name="apiParameterError")
public class ApiParameterError {
/**
@@ -1,10 +1,11 @@
package org.mifosng.data;
package org.mifosng.platform.api.data;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import org.codehaus.jackson.map.annotate.JsonFilter;
import org.mifosng.data.CurrencyData;
@JsonFilter("myFilter")
public class ConfigurationData implements Serializable {
@@ -1,8 +1,6 @@
package org.mifosng.data;
package org.mifosng.platform.api.data;
import javax.xml.bind.annotation.XmlRootElement;
@XmlRootElement(name = "identifier")
public class EntityIdentifier {
private Long entityId;
@@ -1,4 +1,4 @@
package org.mifosng.data;
package org.mifosng.platform.api.data;
import java.io.Serializable;
@@ -8,7 +8,6 @@ import java.util.List;
import org.codehaus.jackson.map.annotate.JsonFilter;
import org.joda.time.DateTime;
import org.mifosng.data.CurrencyData;
import org.mifosng.data.EnumOptionData;
import org.mifosng.data.MoneyData;
@JsonFilter("myFilter")
@@ -4,17 +4,14 @@ import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import javax.xml.bind.annotation.XmlRootElement;
import org.codehaus.jackson.annotate.JsonIgnoreProperties;
import org.codehaus.jackson.map.annotate.JsonFilter;
import org.joda.time.LocalDate;
import org.mifosng.data.LoanSchedule;
@XmlRootElement(name = "newloanworkflow")
@JsonIgnoreProperties({ "organisationId", "organisationName" })
@JsonFilter("myFilter")
public class NewLoanWorkflowStepOneData implements Serializable {
public class NewLoanData implements Serializable {
private Long organisationId;
private String organisationName;
@@ -44,7 +41,7 @@ public class NewLoanWorkflowStepOneData implements Serializable {
private LoanProductData selectedProduct;
public NewLoanWorkflowStepOneData() {
public NewLoanData() {
//
}
@@ -1,11 +1,8 @@
package org.mifosng.data;
import javax.xml.bind.annotation.XmlRootElement;
package org.mifosng.platform.api.data;
import org.codehaus.jackson.map.annotate.JsonFilter;
import org.joda.time.DateTime;
@XmlRootElement(name = "note")
@JsonFilter("myFilter")
public class NoteData {
@@ -2,9 +2,6 @@ package org.mifosng.platform.api.data;
import java.io.Serializable;
import javax.xml.bind.annotation.XmlRootElement;
@XmlRootElement(name = "officeLookup")
public class OfficeLookup implements Serializable {
private Long id;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.springframework.context.annotation.Scope;
import org.springframework.security.access.AccessDeniedException;
import org.springframework.stereotype.Component;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.springframework.context.annotation.Scope;
import org.springframework.security.authentication.BadCredentialsException;
import org.springframework.stereotype.Component;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.exceptions.NoAuthorizationException;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.exceptions.PlatformDataIntegrityException;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.exceptions.AbstractPlatformDomainRuleException;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.exceptions.PlatformInternalServerException;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.exceptions.AbstractPlatformResourceNotFoundException;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -5,7 +5,7 @@ import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.exceptions.UnAuthenticatedUserException;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -9,8 +9,8 @@ import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.codehaus.jackson.map.exc.UnrecognizedPropertyException;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiParameterError;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -9,8 +9,8 @@ import javax.ws.rs.ext.ExceptionMapper;
import javax.ws.rs.ext.Provider;
import org.codehaus.jackson.map.exc.UnrecognizedPropertyException;
import org.mifosng.data.ApiGlobalErrorResponse;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.data.ApiGlobalErrorResponse;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.UnrecognizedQueryParamException;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -10,7 +10,7 @@ import java.util.Locale;
import org.apache.commons.lang.StringUtils;
import org.joda.time.LocalDate;
import org.joda.time.format.DateTimeFormat;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
import org.springframework.context.i18n.LocaleContextHolder;
import org.springframework.stereotype.Service;
@@ -4,9 +4,9 @@ import java.util.ArrayList;
import java.util.List;
import org.apache.commons.lang.StringUtils;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.DataValidatorBuilder;
import org.mifosng.platform.api.commands.ClientCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class ClientCommandValidator {
@@ -3,8 +3,8 @@ package org.mifosng.platform.client.service;
import java.util.Collection;
import org.mifosng.data.ClientLoanAccountSummaryCollectionData;
import org.mifosng.data.NoteData;
import org.mifosng.platform.api.data.ClientData;
import org.mifosng.platform.api.data.NoteData;
public interface ClientReadPlatformService {
@@ -13,9 +13,9 @@ import org.joda.time.DateTime;
import org.joda.time.LocalDate;
import org.mifosng.data.ClientLoanAccountSummaryCollectionData;
import org.mifosng.data.ClientLoanAccountSummaryData;
import org.mifosng.data.NoteData;
import org.mifosng.platform.api.data.AppUserData;
import org.mifosng.platform.api.data.ClientData;
import org.mifosng.platform.api.data.NoteData;
import org.mifosng.platform.api.data.OfficeData;
import org.mifosng.platform.api.data.OfficeLookup;
import org.mifosng.platform.exceptions.ClientNotFoundException;
@@ -1,8 +1,8 @@
package org.mifosng.platform.client.service;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.ClientCommand;
import org.mifosng.platform.api.commands.NoteCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.springframework.security.access.prepost.PreAuthorize;
public interface ClientWritePlatformService {
@@ -5,9 +5,9 @@ import static org.mifosng.platform.Specifications.notesThatMatch;
import static org.mifosng.platform.Specifications.officesThatMatch;
import org.apache.commons.lang.StringUtils;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.ClientCommand;
import org.mifosng.platform.api.commands.NoteCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.client.domain.Client;
import org.mifosng.platform.client.domain.ClientRepository;
import org.mifosng.platform.client.domain.Note;
@@ -1,6 +1,6 @@
package org.mifosng.platform.configuration.service;
import org.mifosng.data.ConfigurationData;
import org.mifosng.platform.api.data.ConfigurationData;
public interface ConfigurationReadPlatformService {
@@ -3,8 +3,8 @@ package org.mifosng.platform.configuration.service;
import java.util.ArrayList;
import java.util.List;
import org.mifosng.data.ConfigurationData;
import org.mifosng.data.CurrencyData;
import org.mifosng.platform.api.data.ConfigurationData;
import org.mifosng.platform.currency.service.CurrencyReadPlatformService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -5,9 +5,9 @@ import java.util.HashSet;
import java.util.List;
import java.util.Set;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.DataValidatorBuilder;
import org.mifosng.platform.api.commands.OrganisationCurrencyCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.currency.domain.ApplicationCurrency;
import org.mifosng.platform.currency.domain.ApplicationCurrencyRepository;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
@@ -2,7 +2,7 @@ package org.mifosng.platform.exceptions;
import java.util.List;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.data.ApiParameterError;
public class PlatformApiDataValidationException extends RuntimeException {
@@ -9,7 +9,6 @@ import org.mifosng.data.CurrencyData;
import org.mifosng.data.DerivedLoanData;
import org.mifosng.data.LoanAccountSummaryData;
import org.mifosng.data.LoanRepaymentData;
import org.mifosng.data.LoanRepaymentDataComparator;
import org.mifosng.data.LoanRepaymentPeriodData;
import org.mifosng.data.LoanRepaymentScheduleData;
import org.mifosng.data.MoneyData;
@@ -1,4 +1,4 @@
package org.mifosng.data;
package org.mifosng.platform.loan.domain;
import java.util.Comparator;
@@ -4,8 +4,8 @@ import java.util.ArrayList;
import java.util.List;
import org.apache.commons.lang.StringUtils;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.commands.AdjustLoanTransactionCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class AdjustLoanTransactionCommandValidator {
@@ -3,9 +3,9 @@ package org.mifosng.platform.loan.service;
import java.util.ArrayList;
import java.util.List;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.DataValidatorBuilder;
import org.mifosng.platform.api.commands.CalculateLoanScheduleCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class CalculateLoanScheduleCommandValidator {
@@ -1,7 +1,6 @@
package org.mifosng.platform.loan.service;
import org.joda.time.LocalDate;
import org.mifosng.data.LoanPayoffReadModel;
import org.mifosng.data.LoanSchedule;
import org.mifosng.platform.api.commands.CalculateLoanScheduleCommand;
@@ -4,7 +4,6 @@ import java.math.BigDecimal;
import org.joda.time.LocalDate;
import org.mifosng.data.CurrencyData;
import org.mifosng.data.LoanPayoffReadModel;
import org.mifosng.data.LoanSchedule;
import org.mifosng.data.MoneyData;
import org.mifosng.platform.api.commands.CalculateLoanScheduleCommand;
@@ -1,11 +1,12 @@
package org.mifosng.data;
import javax.xml.bind.annotation.XmlRootElement;
package org.mifosng.platform.loan.service;
import org.joda.time.LocalDate;
import org.joda.time.format.DateTimeFormatter;
import org.mifosng.data.MoneyData;
@XmlRootElement
/**
*
*/
public class LoanPayoffReadModel {
private String reference;
@@ -2,13 +2,13 @@ package org.mifosng.platform.loan.service;
import org.mifosng.data.LoanAccountData;
import org.mifosng.data.LoanRepaymentData;
import org.mifosng.platform.api.data.NewLoanWorkflowStepOneData;
import org.mifosng.platform.api.data.NewLoanData;
public interface LoanReadPlatformService {
LoanAccountData retrieveLoanAccountDetails(Long loanId);
NewLoanWorkflowStepOneData retrieveClientAndProductDetails(Long clientId, Long productId);
NewLoanData retrieveClientAndProductDetails(Long clientId, Long productId);
LoanRepaymentData retrieveNewLoanRepaymentDetails(Long loanId);
@@ -14,7 +14,7 @@ import org.mifosng.data.LoanRepaymentData;
import org.mifosng.data.MoneyData;
import org.mifosng.platform.api.data.ClientData;
import org.mifosng.platform.api.data.LoanProductData;
import org.mifosng.platform.api.data.NewLoanWorkflowStepOneData;
import org.mifosng.platform.api.data.NewLoanData;
import org.mifosng.platform.client.service.ClientReadPlatformService;
import org.mifosng.platform.currency.domain.ApplicationCurrency;
import org.mifosng.platform.currency.domain.ApplicationCurrencyRepository;
@@ -168,11 +168,11 @@ public class LoanReadPlatformServiceImpl implements LoanReadPlatformService {
}
@Override
public NewLoanWorkflowStepOneData retrieveClientAndProductDetails(final Long clientId, final Long productId) {
public NewLoanData retrieveClientAndProductDetails(final Long clientId, final Long productId) {
AppUser currentUser = context.authenticatedUser();
NewLoanWorkflowStepOneData workflowData = new NewLoanWorkflowStepOneData();
NewLoanData workflowData = new NewLoanData();
workflowData.setOrganisationId(currentUser.getOrganisation().getId());
workflowData.setOrganisationName(currentUser.getOrganisation().getName());
@@ -3,9 +3,9 @@ package org.mifosng.platform.loan.service;
import java.util.ArrayList;
import java.util.List;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.DataValidatorBuilder;
import org.mifosng.platform.api.commands.LoanStateTransitionCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class LoanStateTransitionCommandValidator {
@@ -4,8 +4,8 @@ import java.util.ArrayList;
import java.util.List;
import org.apache.commons.lang.StringUtils;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.commands.LoanTransactionCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class LoanTransactionCommandValidator {
@@ -1,11 +1,11 @@
package org.mifosng.platform.loan.service;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.AdjustLoanTransactionCommand;
import org.mifosng.platform.api.commands.LoanStateTransitionCommand;
import org.mifosng.platform.api.commands.LoanTransactionCommand;
import org.mifosng.platform.api.commands.SubmitLoanApplicationCommand;
import org.mifosng.platform.api.commands.UndoStateTransitionCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.springframework.security.access.prepost.PreAuthorize;
public interface LoanWritePlatformService {
@@ -7,7 +7,6 @@ import java.util.List;
import org.apache.commons.lang.StringUtils;
import org.joda.time.LocalDate;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.data.LoanSchedule;
import org.mifosng.data.ScheduledLoanInstallment;
import org.mifosng.platform.api.commands.AdjustLoanTransactionCommand;
@@ -16,6 +15,7 @@ import org.mifosng.platform.api.commands.LoanStateTransitionCommand;
import org.mifosng.platform.api.commands.LoanTransactionCommand;
import org.mifosng.platform.api.commands.SubmitLoanApplicationCommand;
import org.mifosng.platform.api.commands.UndoStateTransitionCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.client.domain.Note;
import org.mifosng.platform.client.domain.NoteRepository;
import org.mifosng.platform.currency.domain.MonetaryCurrency;
@@ -3,9 +3,9 @@ package org.mifosng.platform.loan.service;
import java.util.ArrayList;
import java.util.List;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.commands.CalculateLoanScheduleCommand;
import org.mifosng.platform.api.commands.SubmitLoanApplicationCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class SubmitLoanApplicationCommandValidator {
@@ -2,7 +2,7 @@ package org.mifosng.platform.loanproduct.service;
import java.util.List;
import org.mifosng.data.EnumOptionData;
import org.mifosng.platform.api.data.EnumOptionData;
public interface LoanDropdownReadPlatformService {
@@ -9,7 +9,7 @@ import static org.mifosng.platform.loanproduct.service.LoanEnumerations.repaymen
import java.util.Arrays;
import java.util.List;
import org.mifosng.data.EnumOptionData;
import org.mifosng.platform.api.data.EnumOptionData;
import org.mifosng.platform.loan.domain.AmortizationMethod;
import org.mifosng.platform.loan.domain.InterestCalculationPeriodMethod;
import org.mifosng.platform.loan.domain.InterestMethod;
@@ -1,6 +1,6 @@
package org.mifosng.platform.loanproduct.service;
import org.mifosng.data.EnumOptionData;
import org.mifosng.platform.api.data.EnumOptionData;
import org.mifosng.platform.loan.domain.AmortizationMethod;
import org.mifosng.platform.loan.domain.InterestCalculationPeriodMethod;
import org.mifosng.platform.loan.domain.InterestMethod;
@@ -3,9 +3,9 @@ package org.mifosng.platform.loanproduct.service;
import java.util.ArrayList;
import java.util.List;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.DataValidatorBuilder;
import org.mifosng.platform.api.commands.LoanProductCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class LoanProductCommandValidator {
@@ -10,8 +10,8 @@ import javax.sql.DataSource;
import org.joda.time.DateTime;
import org.mifosng.data.CurrencyData;
import org.mifosng.data.EnumOptionData;
import org.mifosng.data.MoneyData;
import org.mifosng.platform.api.data.EnumOptionData;
import org.mifosng.platform.api.data.LoanProductData;
import org.mifosng.platform.currency.service.CurrencyReadPlatformService;
import org.mifosng.platform.exceptions.LoanProductNotFoundException;
@@ -1,7 +1,7 @@
package org.mifosng.platform.loanproduct.service;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.LoanProductCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.springframework.security.access.prepost.PreAuthorize;
public interface LoanProductWritePlatformService {
@@ -4,8 +4,8 @@ import static org.mifosng.platform.Specifications.productThatMatches;
import java.math.BigDecimal;
import org.mifosng.data.EntityIdentifier;
import org.mifosng.platform.api.commands.LoanProductCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.currency.domain.MonetaryCurrency;
import org.mifosng.platform.exceptions.LoanProductNotFoundException;
import org.mifosng.platform.loan.domain.AmortizationMethod;
@@ -3,9 +3,9 @@ package org.mifosng.platform.organisation.service;
import java.util.ArrayList;
import java.util.List;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.DataValidatorBuilder;
import org.mifosng.platform.api.commands.OfficeCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class OfficeCommandValidator {
@@ -15,9 +15,9 @@ import org.codehaus.jettison.json.JSONObject;
import org.joda.time.DateTime;
import org.joda.time.format.DateTimeFormatter;
import org.joda.time.format.ISODateTimeFormat;
import org.mifosng.data.LoanPayoffReadModel;
import org.mifosng.data.MoneyData;
import org.mifosng.platform.loan.service.CalculationPlatformService;
import org.mifosng.platform.loan.service.LoanPayoffReadModel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -8,8 +8,8 @@ import java.util.List;
import java.util.Set;
import org.apache.commons.lang.StringUtils;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.api.commands.UserCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.OfficeNotFoundException;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
import org.mifosng.platform.exceptions.PlatformDataIntegrityException;
@@ -3,9 +3,9 @@ package org.mifosng.platform.user.service;
import java.util.ArrayList;
import java.util.List;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.DataValidatorBuilder;
import org.mifosng.platform.api.commands.RoleCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class RoleCommandValidator {
@@ -3,9 +3,9 @@ package org.mifosng.platform.user.service;
import java.util.ArrayList;
import java.util.List;
import org.mifosng.data.ApiParameterError;
import org.mifosng.platform.DataValidatorBuilder;
import org.mifosng.platform.api.commands.UserCommand;
import org.mifosng.platform.api.data.ApiParameterError;
import org.mifosng.platform.exceptions.PlatformApiDataValidationException;
public class UserCommandValidator {