| Line 4270... |
Line 4270... |
| 4270 |
}
|
4270 |
}
|
| 4271 |
}
|
4271 |
}
|
| 4272 |
if (!filteredRows.isEmpty()) {
|
4272 |
if (!filteredRows.isEmpty()) {
|
| 4273 |
String[] email = new String[]{storeGuyEntry.getKey(),"neeraj.gupta@smartdukaan.com"};
|
4273 |
String[] email = new String[]{storeGuyEntry.getKey(),"neeraj.gupta@smartdukaan.com"};
|
| 4274 |
String messageText = this.getMessageForDueDateExtend(filteredRows);
|
4274 |
String messageText = this.getMessageForDueDateExtend(filteredRows);
|
| 4275 |
this.sendMailOfHtmlFormat(gmailRelaySender, email, messageText, null, subject);
|
4275 |
this.sendMailOfHtmlFormat(googleMailSender, email, messageText, null, subject);
|
| 4276 |
|
4276 |
|
| 4277 |
}
|
4277 |
}
|
| 4278 |
|
4278 |
|
| 4279 |
}
|
4279 |
}
|
| 4280 |
String messageText = this.getMessageForDueDateExtend(defaultLoans);
|
4280 |
String messageText = this.getMessageForDueDateExtend(defaultLoans);
|
| 4281 |
this.sendMailOfHtmlFormat(gmailRelaySender, new String[]{"puneet.wahi@smartdukaan.com", "rahul.latwal@smartdukaan.com", "dilbag.singh@smartdukaan.com"}, messageText, null, subject);
|
4281 |
this.sendMailOfHtmlFormat(googleMailSender, new String[]{"puneet.wahi@smartdukaan.com", "rahul.latwal@smartdukaan.com", "dilbag.singh@smartdukaan.com"}, messageText, null, subject);
|
| 4282 |
|
4282 |
|
| 4283 |
for (Loan defaultLoan : defaultLoans) {
|
4283 |
for (Loan defaultLoan : defaultLoans) {
|
| 4284 |
double principal = defaultLoan.getPendingAmount().doubleValue();
|
4284 |
double principal = defaultLoan.getPendingAmount().doubleValue();
|
| 4285 |
double interest = defaultLoan.getInterestAccrued().doubleValue() - defaultLoan.getInterestPaid().doubleValue();
|
4285 |
double interest = defaultLoan.getInterestAccrued().doubleValue() - defaultLoan.getInterestPaid().doubleValue();
|
| 4286 |
double total = principal + interest;
|
4286 |
double total = principal + interest;
|
| Line 4670... |
Line 4670... |
| 4670 |
}
|
4670 |
}
|
| 4671 |
|
4671 |
|
| 4672 |
sb.append("</tbody></table></body></html>");
|
4672 |
sb.append("</tbody></table></body></html>");
|
| 4673 |
String subject = "Customer Info - Hygiene Alert";
|
4673 |
String subject = "Customer Info - Hygiene Alert";
|
| 4674 |
|
4674 |
|
| 4675 |
this.sendMailOfHtmlFormat(gmailRelaySender, new String[]{customRetailer.getEmail()}, sb.toString(), null, subject);
|
4675 |
this.sendMailOfHtmlFormat(googleMailSender, new String[]{customRetailer.getEmail()}, sb.toString(), null, subject);
|
| 4676 |
|
4676 |
|
| 4677 |
}
|
4677 |
}
|
| 4678 |
|
4678 |
|
| 4679 |
}
|
4679 |
}
|
| 4680 |
|
4680 |
|
| Line 4957... |
Line 4957... |
| 4957 |
sb.append("<p>Pls note your agreed monthly target is Rs." + purchaseTarget + " and your achievement till date is Rs." + purchase + "</p>");
|
4957 |
sb.append("<p>Pls note your agreed monthly target is Rs." + purchaseTarget + " and your achievement till date is Rs." + purchase + "</p>");
|
| 4958 |
sb.append("<p>Pls note that your balance target is Rs." + balanceTarget + "</p>\n");
|
4958 |
sb.append("<p>Pls note that your balance target is Rs." + balanceTarget + "</p>\n");
|
| 4959 |
sb.append(
|
4959 |
sb.append(
|
| 4960 |
"<p>We wish you all the best and we are confident that this focused approach towards our outlet sales will help us take our outlet to the best SmartDukaan in your city.\n" + "</p>\n");
|
4960 |
"<p>We wish you all the best and we are confident that this focused approach towards our outlet sales will help us take our outlet to the best SmartDukaan in your city.\n" + "</p>\n");
|
| 4961 |
|
4961 |
|
| 4962 |
this.sendMailOfHtmlFormat(gmailRelaySender, new String[]{customRetailer.getEmail()}, sb.toString(), null, subject);
|
4962 |
this.sendMailOfHtmlFormat(googleMailSender, new String[]{customRetailer.getEmail()}, sb.toString(), null, subject);
|
| 4963 |
}
|
4963 |
}
|
| 4964 |
|
4964 |
|
| 4965 |
}
|
4965 |
}
|
| 4966 |
|
4966 |
|
| 4967 |
}
|
4967 |
}
|
| Line 5011... |
Line 5011... |
| 5011 |
List<String> sendTo = Arrays.asList("kamini.sharma@smartdukaan.com", "niranjan.kala@smartdukaan.com",
|
5011 |
List<String> sendTo = Arrays.asList("kamini.sharma@smartdukaan.com", "niranjan.kala@smartdukaan.com",
|
| 5012 |
"mohit.gulati@smartdukaan.com", "vinay.p@smartdukaan.com", "shivam.gupta@smartdukaan.com");
|
5012 |
"mohit.gulati@smartdukaan.com", "vinay.p@smartdukaan.com", "shivam.gupta@smartdukaan.com");
|
| 5013 |
|
5013 |
|
| 5014 |
|
5014 |
|
| 5015 |
String[] email = sendTo.toArray(new String[sendTo.size()]);
|
5015 |
String[] email = sendTo.toArray(new String[sendTo.size()]);
|
| 5016 |
this.sendMailOfHtmlFormat(gmailRelaySender, email, sb.toString(), null, subject);
|
5016 |
this.sendMailOfHtmlFormat(googleMailSender, email, sb.toString(), null, subject);
|
| 5017 |
|
5017 |
|
| 5018 |
}
|
5018 |
}
|
| 5019 |
|
5019 |
|
| 5020 |
public void findTodayPocoBillingItems() throws MessagingException, ProfitMandiBusinessException, IOException {
|
5020 |
public void findTodayPocoBillingItems() throws MessagingException, ProfitMandiBusinessException, IOException {
|
| 5021 |
LocalDateTime endDate = LocalDate.now().atStartOfDay().plusDays(1);
|
5021 |
LocalDateTime endDate = LocalDate.now().atStartOfDay().plusDays(1);
|
| Line 5049... |
Line 5049... |
| 5049 |
|
5049 |
|
| 5050 |
}
|
5050 |
}
|
| 5051 |
List<String> sendTo = Arrays.asList("uday.singh@smartdukaan.com", "kuldeep.kumar@smartdukaan.com", "nishant.ohri@smartdukaan.com", "ritesh.chauhan1@smartdukaan.com");
|
5051 |
List<String> sendTo = Arrays.asList("uday.singh@smartdukaan.com", "kuldeep.kumar@smartdukaan.com", "nishant.ohri@smartdukaan.com", "ritesh.chauhan1@smartdukaan.com");
|
| 5052 |
|
5052 |
|
| 5053 |
String[] email = sendTo.toArray(new String[sendTo.size()]);
|
5053 |
String[] email = sendTo.toArray(new String[sendTo.size()]);
|
| 5054 |
this.sendMailOfHtmlFormat(gmailRelaySender, email, sb.toString(), null, subject);
|
5054 |
this.sendMailOfHtmlFormat(googleMailSender, email, sb.toString(), null, subject);
|
| 5055 |
|
5055 |
|
| 5056 |
}
|
5056 |
}
|
| 5057 |
|
5057 |
|
| 5058 |
|
5058 |
|
| 5059 |
public void monthlyTargetForInternalTeam() throws MessagingException, ProfitMandiBusinessException, IOException {
|
5059 |
public void monthlyTargetForInternalTeam() throws MessagingException, ProfitMandiBusinessException, IOException {
|
| Line 5253... |
Line 5253... |
| 5253 |
whatsAppCount++;
|
5253 |
whatsAppCount++;
|
| 5254 |
}
|
5254 |
}
|
| 5255 |
|
5255 |
|
| 5256 |
String emailMessage = getEmailMessageForDefaultLoan(defaultLoan, principal, interest, total, user.getName());
|
5256 |
String emailMessage = getEmailMessageForDefaultLoan(defaultLoan, principal, interest, total, user.getName());
|
| 5257 |
String[] email = {user.getEmailId()};
|
5257 |
String[] email = {user.getEmailId()};
|
| 5258 |
sendMailOfHtmlFormat(gmailRelaySender, email, emailMessage, null, "Loan Alert - SmartDukaan");
|
5258 |
sendMailOfHtmlFormat(googleMailSender, email, emailMessage, null, "Loan Alert - SmartDukaan");
|
| 5259 |
}
|
5259 |
}
|
| 5260 |
}
|
5260 |
}
|
| 5261 |
|
5261 |
|
| 5262 |
private String getEmailMessageForDefaultLoan(Loan loan, double principal, double interest, double total, String name) {
|
5262 |
private String getEmailMessageForDefaultLoan(Loan loan, double principal, double interest, double total, String name) {
|
| 5263 |
String formattedTotal = FormattingUtils.formatDecimal(total);
|
5263 |
String formattedTotal = FormattingUtils.formatDecimal(total);
|