Package org.fenixedu.academic.domain.phd.candidacy

Examples of org.fenixedu.academic.domain.phd.candidacy.PhdProgramCandidacyProcessBean


        return mapping.findForward("editProcessAttributes");
    }

    public ActionForward editProcessAttributes(ActionMapping mapping, ActionForm form, HttpServletRequest request,
            HttpServletResponse response) {
        PhdProgramCandidacyProcessBean bean = getRenderedObject("processBean");
        ExecuteProcessActivity.run(getProcess(request),
                org.fenixedu.academic.domain.phd.candidacy.activities.EditProcessAttributes.class, bean);

        return viewIndividualProgramProcess(mapping, form, request, response);
    }
View Full Code Here


        return returnVal;
    }

    private PhdIndividualProgramProcess createCandidacyProcess(final User userView) {
        final PhdProgramCandidacyProcessBean candidacyBean = new PhdProgramCandidacyProcessBean();

        candidacyBean.setCandidacyDate(getProcessBean().getStartProcessDate());
        candidacyBean.setState(PhdProgramCandidacyProcessState.STAND_BY_WITH_COMPLETE_INFORMATION);
        candidacyBean.setPersonBean(getPhdMigrationIndividualPersonalData().getPersonBean());
        candidacyBean.setMigratedProcess(true);
        candidacyBean.setProgram(getProcessBean().getPhdProgram());
        candidacyBean.setThesisTitle(getProcessBean().getTitle());
        candidacyBean.setPhdStudentNumber(getPhdMigrationIndividualPersonalData().getNumber());
        candidacyBean.setCollaborationType(PhdIndividualProgramCollaborationType.NONE);
        candidacyBean.setExecutionYear(getExecutionYear());
        candidacyBean.setFocusArea((getProcessBean().getPhdProgram().getPhdProgramFocusAreasSet().size() == 1) ? getProcessBean()
                .getPhdProgram().getPhdProgramFocusAreasSet().iterator().next() : null);

        final PhdIndividualProgramProcess individualProcess =
                (PhdIndividualProgramProcess) CreateNewProcess.run(PhdIndividualProgramProcess.class, candidacyBean);
View Full Code Here

        }

        @Override
        protected PhdIndividualProgramProcess executeActivity(PhdIndividualProgramProcess noProcess, User userView, Object object) {

            final PhdProgramCandidacyProcessBean bean = (PhdProgramCandidacyProcessBean) object;
            final Person person = getOrCreatePerson(bean);
            final PhdIndividualProgramProcess createdProcess = new PhdIndividualProgramProcess(bean, person);
            for (PhdThesisSubjectOrderBean thesisSubjectBean : bean.getThesisSubjectBeans()) {
                new ThesisSubjectOrder(thesisSubjectBean.getThesisSubject(), createdProcess, thesisSubjectBean.getOrder());
            }

            Process.createNewProcess(userView, PhdProgramCandidacyProcess.class, new Object[] { bean, person, createdProcess });

            if (bean.hasCandidacyHashCode()) {
                new PublicPhdMissingCandidacyValidationAlert(createdProcess);
            }

            createdProcess.createState(PhdIndividualProgramProcessState.CANDIDACY, person, "");
View Full Code Here

            }

            @Override
            protected PhdIndividualProgramProcess executeActivity(PhdIndividualProgramProcess noProcess, User userView,
                    Object object) {
                final PhdProgramCandidacyProcessBean bean = (PhdProgramCandidacyProcessBean) object;

                if (bean.getPersonBean().hasPerson()) {
                    if (PhdProgramCandidacyProcess.hasOnlineApplicationForPeriod(bean.getPersonBean().getPerson(),
                            bean.getPhdCandidacyPeriod())) {
                        throw new DomainException("error.phd.public.candidacy.fill.personal.information.and.institution.id");
                    }
                }

                return super.executeActivity(noProcess, userView, object);
View Full Code Here

        }
    }

    @Override
    protected PhdProgramCandidacyProcess executeActivity(PhdProgramCandidacyProcess process, User userView, Object object) {
        PhdProgramCandidacyProcessBean bean = (PhdProgramCandidacyProcessBean) object;

        PhdCandidacyProcessState.createStateWithGivenStateDate(process, bean.getState(), userView.getPerson(), "", bean
                .getStateDate().toDateTimeAtStartOfDay());

        return process;
    }
View Full Code Here

        }
    }

    @Override
    protected PhdProgramCandidacyProcess executeActivity(PhdProgramCandidacyProcess process, User userView, Object object) {
        PhdProgramCandidacyProcessBean bean = (PhdProgramCandidacyProcessBean) object;

        process.setCandidacyDate(bean.getCandidacyDate());
        process.setWhenRatified(bean.getWhenRatified());
        return process;
    }
View Full Code Here

TOP

Related Classes of org.fenixedu.academic.domain.phd.candidacy.PhdProgramCandidacyProcessBean

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.