Examples of toDateTimeAtStartOfDay()


Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

        DateTime dateTime = result.get(dateTimeProperty);
        if (target == CUBRID) {
            // XXX Cubrid adds random milliseconds for some reason
            dateTime = dateTime.withMillisOfSecond(0);
        }
        assertEquals(localDate.toDateTimeAtStartOfDay(), dateTime);
    }

    @Test
    public void Complex1() {
        // related to #584795
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

            stateDate = getExecutionYear().getEndDateYearMonthDay().toLocalDate();
        }

        final RegistrationState state =
                RegistrationState.createRegistrationState(oldStudentCurricularPlan.getRegistration(), null,
                        stateDate.toDateTimeAtStartOfDay(), RegistrationStateType.CONCLUDED);
        state.setResponsiblePerson(null);
    }

    private void moveGratuityEventsInformation(final StudentCurricularPlan oldStudentCurricularPlan,
            final StudentCurricularPlan newStudentCurricularPlan) {
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

            LocalDate startLocalDate = new LocalDate(startDate.getYear(), startDate.getMonthOfYear(), startDate.getDayOfMonth());
            BigDecimal ectsForYear = bean.getEctsForYear();
            BigDecimal gratuityFactor = bean.getGratuityFactor();
            BigDecimal ectsFactor = bean.getEctsFactor();

            new StandaloneEnrolmentGratuityPR(startLocalDate.toDateTimeAtStartOfDay(), null, dcpSAT, ectsForYear, gratuityFactor,
                    ectsFactor);
        } else {
            throw new DomainException("StandaloneEnrolmentGratuityPR.DegreeCurricularPlanServiceAgreementTemplate.cannot.be.null");
        }
    }
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

        return false;
    }

    public DateTime getPaymentStartDate() {
        LocalDate date = new LocalDate(getYear().getYear(), getMonth().getNumberOfMonth(), 1);
        return date.toDateTimeAtStartOfDay();
    }

    public DateTime getPaymentLimitDateTime() {
        ResidenceYear residenceYear = getYear();
        LocalDate date =
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

    public DateTime getPaymentLimitDateTime() {
        ResidenceYear residenceYear = getYear();
        LocalDate date =
                new LocalDate(residenceYear.getYear(), getMonth().getNumberOfMonth(), getManagementUnit()
                        .getCurrentPaymentLimitDay());
        return date.toDateTimeAtStartOfDay();
    }

    public boolean isAbleToEditPaymentLimitDate() {
        return getEventsSet().size() == 0;
    }
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

                setCellValueForDate(cell, dateValue, dateCellStyle);
                return;
            }
            if(valueAsObj instanceof LocalDate) {
                LocalDate value = (LocalDate) valueAsObj;
                Date date = value.toDateTimeAtStartOfDay().toDate();
                setCellValueForDate(cell, date, dateCellStyle);
                return;
            }
            if(valueAsObj instanceof LocalDateTime) {
                LocalDateTime value = (LocalDateTime) valueAsObj;
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

    }

    public Date DateValueOfParameterNamed(final String parameterName) {
        final LocalDate localDate = this.fromApiJsonHelper.extractLocalDateNamed(parameterName, this.parsedCommand);
        if (localDate == null) { return null; }
        return localDate.toDateTimeAtStartOfDay().toDate();
    }

    public boolean isChangeInStringParameterNamed(final String parameterName, final String existingValue) {
        boolean isChanged = false;
        if (parameterExists(parameterName)) {
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

    }

    private void validateBusinessRulesForJournalEntries(final JournalEntryCommand command) {
        /** check if date of Journal entry is valid ***/
        final LocalDate entryLocalDate = command.getTransactionDate();
        final Date transactionDate = entryLocalDate.toDateTimeAtStartOfDay().toDate();
        // shouldn't be in the future
        final Date todaysDate = new Date();
        if (transactionDate.after(todaysDate)) { throw new JournalEntryInvalidException(GL_JOURNAL_ENTRY_INVALID_REASON.FUTURE_DATE,
                transactionDate, null, null); }
        // shouldn't be before an accounting closure
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

                setCellValueForDate(cell, dateValue, dateCellStyle);
                return;
            }
            if(valueAsObj instanceof LocalDate) {
                LocalDate value = (LocalDate) valueAsObj;
                Date date = value.toDateTimeAtStartOfDay().toDate();
                setCellValueForDate(cell, date, dateCellStyle);
                return;
            }
            if(valueAsObj instanceof LocalDateTime) {
                LocalDateTime value = (LocalDateTime) valueAsObj;
View Full Code Here

Examples of org.joda.time.LocalDate.toDateTimeAtStartOfDay()

    public void canSerializeLocalDate() {
        LocalDate localDate = new LocalDate();

        Object value = converter.toDbValue(localDate);

        assertThat((Long) value, is(localDate.toDateTimeAtStartOfDay().getMillis()));
    }

    @Test
    public void canDeserializeLocalDate() {
        LocalDate localDate = new LocalDate();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.