Rev 33903 | Rev 34312 | Go to most recent revision | 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.enumuration.transaction.CreditRisk;import com.spice.profitmandi.dao.enumuration.transaction.LoanReferenceType;import com.spice.profitmandi.dao.model.CartResponse;import com.spice.profitmandi.dao.model.SDCreditResponseOut;import com.spice.profitmandi.dao.model.UserCart;import org.springframework.stereotype.Service;import java.math.BigDecimal;import java.time.LocalDate;import java.time.LocalDateTime;import java.util.List;import java.util.Map;@Servicepublic interface SDCreditService {void fundWallet(int fofoId) 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;int createSDDirectOrder(UserCart userCart, CartResponse cartValidationResponse)throws ProfitMandiBusinessException;BigDecimal getAvailableAmount(int fofoId);long 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);CreditRisk getCurrentRisk(SDCreditRequirement sdCreditRequirement, LocalDateTime firstBillingDate);boolean isDefaultPartner(int fofoId);void updateRisk();List<Loan> getDefaultLoan();List<Loan> getDefaultLoanWithoutLimit();List<Loan> getLoanALert();public List<Loan> getDueDateCrossLoan();public boolean isDefaultLoan(int loanId, LocalDate time);LoanSummary getLoanSummary();void checkLoans();void createLoanForBilling(int transactionId, double invoiceAmount, String invoiceNumber) throws ProfitMandiBusinessException;void settleBlockedLoan(int transactionId) throws ProfitMandiBusinessException;Loan getLimitFromTransactionId(int transactionId) throws ProfitMandiBusinessException;double settleLoan(Loan loan) throws ProfitMandiBusinessException;void resetHardLimit();}