Subversion Repositories SmartDukaan

Rev

Rev 33420 | Rev 33696 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 33420 Rev 33449
Line 36... Line 36...
36
import org.apache.poi.ss.usermodel.CreationHelper;
36
import org.apache.poi.ss.usermodel.CreationHelper;
37
import org.apache.poi.ss.usermodel.Sheet;
37
import org.apache.poi.ss.usermodel.Sheet;
38
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
38
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
39
import org.json.JSONObject;
39
import org.json.JSONObject;
40
import org.springframework.beans.factory.annotation.Autowired;
40
import org.springframework.beans.factory.annotation.Autowired;
41
import org.springframework.cglib.core.Local;
-
 
42
import org.springframework.core.io.InputStreamResource;
41
import org.springframework.core.io.InputStreamResource;
43
import org.springframework.http.HttpHeaders;
42
import org.springframework.http.HttpHeaders;
44
import org.springframework.http.HttpStatus;
43
import org.springframework.http.HttpStatus;
45
import org.springframework.http.ResponseEntity;
44
import org.springframework.http.ResponseEntity;
46
import org.springframework.mail.javamail.JavaMailSender;
45
import org.springframework.mail.javamail.JavaMailSender;
Line 204... Line 203...
204
        } catch (ProfitMandiBusinessException profitMandiBusinessException) {
203
        } catch (ProfitMandiBusinessException profitMandiBusinessException) {
205
            LOGGER.error("UserWallet not found : ", profitMandiBusinessException);
204
            LOGGER.error("UserWallet not found : ", profitMandiBusinessException);
206
        }
205
        }
207
        SDCreditRequirement sdCreditRequirement = sdCreditRequirementRepository.selectByFofoId(fofoId);
206
        SDCreditRequirement sdCreditRequirement = sdCreditRequirementRepository.selectByFofoId(fofoId);
208
        List<Loan> loans = loanRepository.selectActiveLoan(fofoId);
207
        List<Loan> loans = loanRepository.selectActiveLoan(fofoId);
-
 
208
        BigDecimal utilization = sdCreditRequirement.getUtilizedAmount();
209
        BigDecimal availableLimit = sdCreditRequirement.getAvailableLimit();
209
        BigDecimal availableLimit = sdCreditRequirement.getAvailableLimit();
210
        BigDecimal creditlimit = sdCreditRequirement.getLimit();
210
        BigDecimal creditlimit = sdCreditRequirement.getLimit();
211
        BigDecimal totalDue = new BigDecimal(0);
211
        BigDecimal totalDue = new BigDecimal(0);
212
        for (Loan loan : loans) {
212
        for (Loan loan : loans) {
213
            BigDecimal pendingAmount = loan.getPendingAmount();
213
            BigDecimal pendingAmount = loan.getPendingAmount();
Line 221... Line 221...
221
        model.addAttribute("start", offset + 1);
221
        model.addAttribute("start", offset + 1);
222
        model.addAttribute("size", countItems);
222
        model.addAttribute("size", countItems);
223
        model.addAttribute("isAdmin", isAdmin);
223
        model.addAttribute("isAdmin", isAdmin);
224
        model.addAttribute("loans", loans);
224
        model.addAttribute("loans", loans);
225
        model.addAttribute("totalDue", totalDue);
225
        model.addAttribute("totalDue", totalDue);
-
 
226
        model.addAttribute("utilization", utilization);
226
        model.addAttribute("availableLimit", availableLimit);
227
        model.addAttribute("availableLimit", availableLimit);
227
        model.addAttribute("creditlimit", creditlimit);
228
        model.addAttribute("creditlimit", creditlimit);
228
        model.addAttribute(ProfitMandiConstants.START_TIME, startTimeString);
229
        model.addAttribute(ProfitMandiConstants.START_TIME, startTimeString);
229
        model.addAttribute(ProfitMandiConstants.END_TIME, endTimeString);
230
        model.addAttribute(ProfitMandiConstants.END_TIME, endTimeString);
230
 
231