Rev 35878 | View as "text/plain" | Blame | Compare with Previous | Last modification | View Log | RSS feed
package com.spice.profitmandi.service.transaction;import com.spice.profitmandi.common.exception.ProfitMandiBusinessException;import com.spice.profitmandi.dao.entity.transaction.Loan;import com.spice.profitmandi.dao.entity.transaction.LoanSummary;import com.spice.profitmandi.dao.entity.transaction.SDCreditRequirement;import com.spice.profitmandi.dao.entity.transaction.StateWiseLoanSummary;import com.spice.profitmandi.dao.enumuration.transaction.CreditRisk;import com.spice.profitmandi.dao.enumuration.transaction.LoanReferenceType;import com.spice.profitmandi.dao.model.SDCreditResponseOut;import com.spice.profitmandi.dao.model.BulkCreditSummary;import com.spice.profitmandi.dao.model.CreditSummary;import java.math.BigDecimal;import java.time.LocalDate;import java.time.LocalDateTime;import java.util.List;import java.util.Map;public interface SDCreditService {void fundWallet(int fofoId) throws ProfitMandiBusinessException;void fundWallet(int fofoId, double amountToFund, String reasonToFund) throws ProfitMandiBusinessException;//This will create loan irrespective of sanctions and increases the overall ultizationLoan createLoan(int fofoId, double creditAmountRequired, int freeDays, String creditReason) throws ProfitMandiBusinessException;BlockLoanIdSanctionId createSDDirectOrder(int userId, double amountRequired, int freeCreditDays)throws ProfitMandiBusinessException;BigDecimal getAvailableAmount(int fofoId);BigDecimal getUtilizationAmount(int fofoId);void createLoanStatement(LoanReferenceType interest, BigDecimal interestAccrued, int fofoId, int loanId,String description, LocalDateTime businessDate);void addInterest(LocalDate from, LocalDate to, Loan loan, Map<LoanReferenceType, Double> loanStatusAmount);SDCreditResponseOut sdDirectService(int retailerId) throws ProfitMandiBusinessException;CreditRisk getCurrentRisk(SDCreditRequirement sdCreditRequirement, LocalDateTime firstBillingDate);boolean isDefaultPartner(int fofoId);void updateRisk();List<Loan> getDefaultLoans();public List<Loan> getDueDateCrossLoan();public List<Loan> getAllActiveLoan();public boolean isDefaultLoan(int loanId, LocalDate time);LoanSummary getLoanSummary();Map<String, StateWiseLoanSummary> getLoanSummaryStateWise() throws ProfitMandiBusinessException;void checkLoans();void createLoanForBilling(int transactionId, double invoiceAmount, String invoiceNumber) throws ProfitMandiBusinessException;void settleBlockedLoan(int transactionId, double amountToRelease) throws ProfitMandiBusinessException;void increaseBlockedLimit(int transactionId, int fofoId, double amount) throws ProfitMandiBusinessException;Loan getLimitFromTransactionId(int transactionId) throws ProfitMandiBusinessException;double settleLoan(Loan loan) throws ProfitMandiBusinessException;void resetHardLimit() throws ProfitMandiBusinessException;void releaseBlockedLimit(Loan blockedLoan, double limitToRelease) throws ProfitMandiBusinessException;CreditSummary getCreditSummary(int fofoId);CreditSummary getCreditSummaryForOrder(int fofoId, double orderAmount) throws ProfitMandiBusinessException;Map<Integer, BulkCreditSummary> getCreditSummaryBulk();double getAvailableFreshMoney(int fofoId) throws ProfitMandiBusinessException;}