Subversion Repositories SmartDukaan

Rev

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

Rev 29430 Rev 29432
Line 226... Line 226...
226
		} else {
226
		} else {
227
			if (co.getBillingTimestamp() != null) {
227
			if (co.getBillingTimestamp() != null) {
228
				co.setExpectedShipping(co.getBillingTimestamp());
228
				co.setExpectedShipping(co.getBillingTimestamp());
229
 
229
 
230
				if (LocalDate.now().isAfter(co.getExpectedShipping().toLocalDate())) {
230
				if (LocalDate.now().isAfter(co.getExpectedShipping().toLocalDate())) {
231
					long noOfDaysBetween = ChronoUnit.DAYS.between(LocalDate.now().atStartOfDay(),
231
					long noOfDaysBetween = ChronoUnit.DAYS.between(
232
							co.getExpectedShipping());
232
							co.getExpectedShipping(),LocalDate.now().atStartOfDay());
233
 
233
 
234
					co.setExpectedShipping(co.getBillingTimestamp().plusDays(noOfDaysBetween));
234
					co.setExpectedShipping(co.getBillingTimestamp().plusDays(noOfDaysBetween));
235
				}
235
				}
236
			}
236
			}
237
			tm.setExpectedShipping(co.getExpectedShipping());
237
			tm.setExpectedShipping(co.getExpectedShipping());