Package org.fenixedu.academic.domain

Examples of org.fenixedu.academic.domain.ExecutionSemester


        } else if (showOccupation instanceof InfoLessonInstanceAggregation) {

            final InfoLessonInstanceAggregation aggregation = (InfoLessonInstanceAggregation) showOccupation;
            final Shift shift = aggregation.getShift();
            final ExecutionCourse executionCourse = shift.getExecutionCourse();
            final ExecutionSemester executionSemester = executionCourse.getExecutionPeriod();

            strBuffer.append(shift.getShiftTypesCodePrettyPrint()).append(" ");
            final Space allocatableSpace = aggregation.getAllocatableSpace();
            if (allocatableSpace != null) {
                strBuffer.append("<a href='").append(context).append("/publico/");
                strBuffer.append("siteViewer.do?method=roomViewer&amp;roomName=");
                strBuffer.append(allocatableSpace.getName()).append("&amp;objectCode=");
                strBuffer.append(executionSemester.getExternalId());
                strBuffer.append("&amp;executionPeriodOID=");
                strBuffer.append(executionSemester.getExternalId()).append("'>");
                strBuffer.append(allocatableSpace.getName()).append("</a>");
            }

        } else if (showOccupation instanceof InfoExam) {
            InfoExam infoExam = (InfoExam) showOccupation;
View Full Code Here


        return tables;
    }

    private SheetData<IEctsConversionTable> exportEnrolmentByCompetenceCourseTemplate(EctsTableFilter filter) {
        final ExecutionYear year = (ExecutionYear) ExecutionYear.getExecutionInterval(filter.getExecutionInterval());
        final ExecutionSemester querySemester = year.getFirstExecutionPeriod();
        SheetData<IEctsConversionTable> builder =
                new SheetData<IEctsConversionTable>(processEnrolmentByCompetenceCourseStatus(filter)) {
                    @Override
                    protected void makeLine(IEctsConversionTable table) {
                        CompetenceCourse competence = (CompetenceCourse) table.getTargetEntity();
View Full Code Here

        return builder;
    }

    @Atomic
    private void importEnrolmentByCompetenceCourseTables(AcademicInterval executionInterval, String file) {
        ExecutionSemester querySemester = ExecutionYear.readByAcademicInterval(executionInterval).getFirstExecutionPeriod();
        for (String line : file.split("\n")) {
            if (!line.startsWith(BundleUtil.getString(Bundle.GEP, "label.externalId"))) {
                String[] parts = fillArray(line.split(SEPARATOR), 17);
                CompetenceCourse competence = FenixFramework.getDomainObject(parts[0]);
                // if
View Full Code Here

        List infoLessonList = null;

        Collection<Shift> shiftList = domainClass.getAssociatedShiftsSet();
        infoLessonList = new ArrayList();

        ExecutionSemester executionSemester = domainClass.getExecutionPeriod();
        InfoExecutionPeriod infoExecutionPeriod = InfoExecutionPeriod.newInfoFromDomain(executionSemester);

        for (Object element : shiftList) {
            Shift shift = (Shift) element;
            infoLessonList.addAll(InfoLessonInstanceAggregation.getAggregations(shift));
View Full Code Here

    private List<Enrolment> searchStudentByCriteria(final ExecutionYear executionYear, final CurricularCourse curricularCourse,
            final Integer semester) {
        final List<Enrolment> result = new ArrayList<Enrolment>();

        final ExecutionSemester executionSemester = executionYear.getExecutionSemesterFor(semester);
        for (final Enrolment enrolment : curricularCourse.getEnrolmentsByExecutionPeriod(executionSemester)) {
            result.add(enrolment);
        }
        Collections.sort(result, new BeanComparator("studentCurricularPlan.registration.number"));
View Full Code Here

    private int countEnrolments(final CurricularCourse curricularCourse, final ExecutionInterval interval) {
        int c = 0;
        for (final CurriculumModule curriculumModule : curricularCourse.getCurriculumModulesSet()) {
            if (curriculumModule.isEnrolment()) {
                final Enrolment enrolment = (Enrolment) curriculumModule;
                final ExecutionSemester executionSemester = enrolment.getExecutionPeriod();
                if (interval == executionSemester || interval == executionSemester.getExecutionYear()) {
                    c++;
                }
            }
        }
        return c;
View Full Code Here

        InfoExecutionPeriod infoExecutionPeriod =
                (InfoExecutionPeriod) request.getAttribute(PresentationConstants.EXECUTION_PERIOD);
        request.setAttribute(PresentationConstants.EXECUTION_PERIOD, infoExecutionPeriod);
        request.setAttribute(PresentationConstants.EXECUTION_PERIOD_OID, infoExecutionPeriod.getExternalId().toString());

        final ExecutionSemester executionSemester = FenixFramework.getDomainObject(infoExecutionPeriod.getExternalId());
        ExecutionDegree executionDegree = degreeCurricularPlan.getExecutionDegreeByYear(executionSemester.getExecutionYear());
        if (executionDegree != null) {
            // infoExecutionDegree
            InfoExecutionDegree infoExecutionDegree = InfoExecutionDegree.newInfoFromDomain(executionDegree);
            RequestUtils.setExecutionDegreeToRequest(request, infoExecutionDegree);
View Full Code Here

        spreadsheet.setHeader("Affiliacao Corientador");
        spreadsheet.setHeader("Distribuicao Creditos Corientador");

        for (final Thesis thesis : getRootDomainObject().getThesesSet()) {
            final Enrolment enrolment = thesis.getEnrolment();
            final ExecutionSemester executionPeriod = enrolment.getExecutionPeriod();
            if (executionPeriod.getExecutionYear() == executionYear) {
                final ThesisPresentationState thesisPresentationState =
                        ThesisPresentationState.getThesisPresentationState(thesis);;

                final Degree degree = enrolment.getStudentCurricularPlan().getDegree();
                final DegreeType degreeType = degree.getDegreeType();
View Full Code Here

        spreadsheet.setHeader("ciclo de estudos");
        spreadsheet.setHeader("regime");
        spreadsheet.setHeader("número inscricoes");
        spreadsheet.setHeader("número aprovacoes");

        final ExecutionSemester firstExecutionSemester =
                ExecutionYear.readExecutionYearByName("2003/2004").getFirstExecutionPeriod();
        final ExecutionSemester lastExecutionSemester = getExecutionYear().getLastExecutionPeriod();
        for (final Degree degree : Degree.readNotEmptyDegrees()) {
            if (checkDegreeType(getDegreeType(), degree)) {
                if (isActive(degree)) {
                    for (final Registration registration : degree.getRegistrationsSet()) {
                        if (registration.isRegistered(getExecutionYear())) {
                            final EnrolmentAndAprovalCounterMap map =
                                    new EnrolmentAndAprovalCounterMap(firstExecutionSemester, lastExecutionSemester, registration);
                            for (final Entry<ExecutionSemester, EnrolmentAndAprovalCounter> entry : map.entrySet()) {
                                final ExecutionSemester executionSemester = entry.getKey();
                                final EnrolmentAndAprovalCounter enrolmentAndAprovalCounter = entry.getValue();

                                final Row row = spreadsheet.addRow();
                                row.setCell(registration.getNumber().toString());
                                row.setCell(executionSemester.getExecutionYear().getYear());
                                row.setCell(executionSemester.getSemester().toString());
                                setDegreeCells(row, degree);
                                final StringBuilder stringBuilder = new StringBuilder();
                                for (final StudentStatuteBean studentStatuteBean : registration.getStudent().getStatutes(
                                        executionSemester)) {
                                    if (stringBuilder.length() > 0) {
                                        stringBuilder.append(", ");
                                    }
                                    stringBuilder.append(studentStatuteBean.getStudentStatute().getStatuteType());
                                }
                                row.setCell(stringBuilder.toString());
                                CycleType cycleType = registration.getCycleType(executionSemester.getExecutionYear());
                                row.setCell(cycleType != null ? cycleType.getDescription() : "");
                                row.setCell(registration.getRegimeType(executionSemester.getExecutionYear()).getLocalizedName());
                                row.setCell(Integer.toString(enrolmentAndAprovalCounter.getEnrolments()));
                                row.setCell(Integer.toString(enrolmentAndAprovalCounter.getAprovals()));
                            }
                        }
                    }
View Full Code Here

    }

    private static InfoSiteRoomTimeTable run(RoomKey roomKey, Calendar someDay, String executionPeriodID) throws Exception {
        final Calendar day = new DateTime(someDay.getTimeInMillis()).withField(DateTimeFieldType.dayOfWeek(), 1).toCalendar(null);
        final ExecutionSemester executionSemester = FenixFramework.getDomainObject(executionPeriodID);
        Space room = SpaceUtils.findAllocatableSpaceForEducationByName(roomKey.getNomeSala());
        return RoomSiteComponentBuilder.getInfoSiteRoomTimeTable(day, room,
                executionSemester != null ? executionSemester : ExecutionSemester.readActualExecutionSemester());
    }
View Full Code Here

TOP

Related Classes of org.fenixedu.academic.domain.ExecutionSemester

Copyright © 2018 www.massapicom. 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.