restructure deposit related files under saving packages.

This commit is contained in:
Keith Woodlock
2012-08-15 12:11:02 +01:00
parent 349e3f4a4e
commit 10c6f9c509
22 changed files with 33 additions and 44 deletions
@@ -17,23 +17,14 @@ import java.util.Map;
import java.util.Set;
import javax.sql.DataSource;
import javax.ws.rs.WebApplicationException;
import javax.ws.rs.core.Response;
import javax.ws.rs.core.StreamingOutput;
import javax.ws.rs.core.Response.Status;
import org.apache.commons.lang.StringUtils;
import org.codehaus.jettison.json.JSONArray;
import org.codehaus.jettison.json.JSONException;
import org.codehaus.jettison.json.JSONObject;
import org.joda.time.DateTime;
import org.joda.time.LocalDate;
import org.mifosng.platform.api.data.AdditionalFieldsSetData;
import org.mifosng.platform.api.data.GenericResultsetData;
import org.mifosng.platform.api.data.ResultsetColumnHeader;
import org.mifosng.platform.api.data.ResultsetDataRow;
import org.mifosng.platform.api.infrastructure.JodaDateTimeAdapter;
import org.mifosng.platform.api.infrastructure.JodaLocalDateAdapter;
import org.mifosng.platform.exceptions.AdditionalFieldsNotFoundException;
import org.mifosng.platform.exceptions.PlatformDataIntegrityException;
import org.mifosng.platform.exceptions.ReportNotFoundException;
@@ -56,9 +47,6 @@ import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
@Service
public class ReadExtraDataAndReportingServiceImpl implements
ReadExtraDataAndReportingService {
@@ -27,10 +27,10 @@ import org.mifosng.platform.api.data.EnumOptionData;
import org.mifosng.platform.api.infrastructure.ApiDataConversionService;
import org.mifosng.platform.api.infrastructure.ApiParameterHelper;
import org.mifosng.platform.currency.service.CurrencyReadPlatformService;
import org.mifosng.platform.deposit.domain.SavingsDepositEnumerations;
import org.mifosng.platform.loan.domain.PeriodFrequencyType;
import org.mifosng.platform.savingproduct.service.DepositAccountReadPlatformService;
import org.mifosng.platform.savingproduct.service.DepositAccountWritePlatformService;
import org.mifosng.platform.saving.service.DepositAccountReadPlatformService;
import org.mifosng.platform.saving.service.DepositAccountWritePlatformService;
import org.mifosng.platform.savingproduct.service.SavingsDepositEnumerations;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -27,10 +27,10 @@ import org.mifosng.platform.api.data.EnumOptionData;
import org.mifosng.platform.api.infrastructure.ApiDataConversionService;
import org.mifosng.platform.api.infrastructure.ApiParameterHelper;
import org.mifosng.platform.currency.service.CurrencyReadPlatformService;
import org.mifosng.platform.deposit.domain.SavingsDepositEnumerations;
import org.mifosng.platform.depositproduct.service.DepositProductReadPlatformService;
import org.mifosng.platform.depositproduct.service.DepositProductWritePlatformService;
import org.mifosng.platform.loan.domain.PeriodFrequencyType;
import org.mifosng.platform.savingproduct.service.DepositProductReadPlatformService;
import org.mifosng.platform.savingproduct.service.DepositProductWritePlatformService;
import org.mifosng.platform.savingproduct.service.SavingsDepositEnumerations;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
@@ -20,9 +20,9 @@ import org.mifosng.platform.api.commands.DepositAccountCommand;
import org.mifosng.platform.client.domain.Client;
import org.mifosng.platform.currency.domain.MonetaryCurrency;
import org.mifosng.platform.currency.domain.Money;
import org.mifosng.platform.deposit.domain.DepositProduct;
import org.mifosng.platform.infrastructure.AbstractAuditableCustom;
import org.mifosng.platform.loan.domain.PeriodFrequencyType;
import org.mifosng.platform.savingproduct.domain.DepositProduct;
import org.mifosng.platform.user.domain.AppUser;
@Entity
@@ -1,4 +1,4 @@
package org.mifosng.platform.savingproduct.service;
package org.mifosng.platform.saving.service;
import java.math.BigDecimal;
@@ -6,12 +6,12 @@ import org.mifosng.platform.api.commands.DepositAccountCommand;
import org.mifosng.platform.client.domain.Client;
import org.mifosng.platform.client.domain.ClientRepository;
import org.mifosng.platform.currency.domain.Money;
import org.mifosng.platform.deposit.domain.DepositProduct;
import org.mifosng.platform.deposit.domain.DepositProductRepository;
import org.mifosng.platform.exceptions.ClientNotFoundException;
import org.mifosng.platform.exceptions.DepositProductNotFoundException;
import org.mifosng.platform.loan.domain.PeriodFrequencyType;
import org.mifosng.platform.saving.domain.DepositAccount;
import org.mifosng.platform.savingproduct.domain.DepositProduct;
import org.mifosng.platform.savingproduct.domain.DepositProductRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -76,6 +76,8 @@ public class DepositAccountAssembler {
}
// end of details allowed to be overriden from product
// fixed-term interest calculator
DepositAccount account = DepositAccount.openNew(client, product, command.getExternalId(),
deposit,
maturityInterestRate,
@@ -1,4 +1,4 @@
package org.mifosng.platform.savingproduct.service;
package org.mifosng.platform.saving.service;
import java.util.ArrayList;
import java.util.List;
@@ -1,4 +1,4 @@
package org.mifosng.platform.savingproduct.service;
package org.mifosng.platform.saving.service;
import java.util.Collection;
@@ -1,4 +1,4 @@
package org.mifosng.platform.savingproduct.service;
package org.mifosng.platform.saving.service;
import java.math.BigDecimal;
import java.sql.ResultSet;
@@ -10,10 +10,10 @@ import org.joda.time.LocalDate;
import org.mifosng.platform.api.data.CurrencyData;
import org.mifosng.platform.api.data.DepositAccountData;
import org.mifosng.platform.api.data.EnumOptionData;
import org.mifosng.platform.deposit.domain.SavingsDepositEnumerations;
import org.mifosng.platform.exceptions.LoanProductNotFoundException;
import org.mifosng.platform.infrastructure.JdbcSupport;
import org.mifosng.platform.infrastructure.TenantAwareRoutingDataSource;
import org.mifosng.platform.savingproduct.service.SavingsDepositEnumerations;
import org.mifosng.platform.security.PlatformSecurityContext;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.dao.EmptyResultDataAccessException;
@@ -1,4 +1,4 @@
package org.mifosng.platform.savingproduct.service;
package org.mifosng.platform.saving.service;
import org.mifosng.platform.api.commands.DepositAccountCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
@@ -1,4 +1,4 @@
package org.mifosng.platform.savingproduct.service;
package org.mifosng.platform.saving.service;
import org.mifosng.platform.api.commands.DepositAccountCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
@@ -1,4 +1,4 @@
package org.mifosng.platform.deposit.domain;
package org.mifosng.platform.savingproduct.domain;
import java.math.BigDecimal;
@@ -1,4 +1,4 @@
package org.mifosng.platform.deposit.domain;
package org.mifosng.platform.savingproduct.domain;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
@@ -1,4 +1,4 @@
package org.mifosng.platform.saving.domain;
package org.mifosng.platform.savingproduct.domain;
import java.math.BigDecimal;
@@ -1,4 +1,4 @@
package org.mifosng.platform.saving.domain;
package org.mifosng.platform.savingproduct.domain;
import java.math.BigDecimal;
@@ -1,4 +1,4 @@
package org.mifosng.platform.saving.domain;
package org.mifosng.platform.savingproduct.domain;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
@@ -1,4 +1,4 @@
package org.mifosng.platform.depositproduct.service;
package org.mifosng.platform.savingproduct.service;
import java.util.ArrayList;
import java.util.List;
@@ -1,4 +1,4 @@
package org.mifosng.platform.depositproduct.service;
package org.mifosng.platform.savingproduct.service;
import java.util.Collection;
@@ -1,4 +1,4 @@
package org.mifosng.platform.depositproduct.service;
package org.mifosng.platform.savingproduct.service;
import java.math.BigDecimal;
import java.sql.ResultSet;
@@ -11,7 +11,6 @@ import org.mifosng.platform.api.data.CurrencyData;
import org.mifosng.platform.api.data.DepositProductData;
import org.mifosng.platform.api.data.DepositProductLookup;
import org.mifosng.platform.api.data.EnumOptionData;
import org.mifosng.platform.deposit.domain.SavingsDepositEnumerations;
import org.mifosng.platform.infrastructure.JdbcSupport;
import org.mifosng.platform.infrastructure.TenantAwareRoutingDataSource;
import org.mifosng.platform.loan.domain.PeriodFrequencyType;
@@ -1,4 +1,4 @@
package org.mifosng.platform.depositproduct.service;
package org.mifosng.platform.savingproduct.service;
import org.mifosng.platform.api.commands.DepositProductCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
@@ -1,13 +1,13 @@
package org.mifosng.platform.depositproduct.service;
package org.mifosng.platform.savingproduct.service;
import org.mifosng.platform.api.commands.DepositProductCommand;
import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.currency.domain.MonetaryCurrency;
import org.mifosng.platform.deposit.domain.DepositProduct;
import org.mifosng.platform.deposit.domain.DepositProductRepository;
import org.mifosng.platform.exceptions.DepositProductNotFoundException;
import org.mifosng.platform.exceptions.PlatformDataIntegrityException;
import org.mifosng.platform.loan.domain.PeriodFrequencyType;
import org.mifosng.platform.savingproduct.domain.DepositProduct;
import org.mifosng.platform.savingproduct.domain.DepositProductRepository;
import org.mifosng.platform.security.PlatformSecurityContext;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -5,8 +5,8 @@ import org.mifosng.platform.api.data.EntityIdentifier;
import org.mifosng.platform.currency.domain.MonetaryCurrency;
import org.mifosng.platform.exceptions.ProductNotFoundException;
import org.mifosng.platform.exceptions.SavingProductNotFoundException;
import org.mifosng.platform.saving.domain.SavingProduct;
import org.mifosng.platform.saving.domain.SavingProductRepository;
import org.mifosng.platform.savingproduct.domain.SavingProduct;
import org.mifosng.platform.savingproduct.domain.SavingProductRepository;
import org.mifosng.platform.security.PlatformSecurityContext;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -1,4 +1,4 @@
package org.mifosng.platform.deposit.domain;
package org.mifosng.platform.savingproduct.service;
import org.mifosng.platform.api.data.EnumOptionData;
import org.mifosng.platform.loan.domain.PeriodFrequencyType;