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ACEgC,KAAMnU,aACNoU,UAAWhC,IAEb,CACE+B,KAAMnU,gBACNoU,UAAWna,GAEb,CACEka,KAAM,KACNuB,WAAY1V,qBAUb,IAAM2V,GAAoB,MAA3B,MAAOA,YAAoB,oCAApBA,EAAoB,EAApBA,EAAoB,sBAApBA,MAAoB,0BAHrBC,cAAsB1B,IACtB0B,QAECD,CAAoB,8BC3C1B,IAAME,GAAa,MAApB,MAAOA,YAAa,oCAAbA,EAAa,EAAbA,EAAa,sBAAbA,MAAa,0BAFdF,GAAsBG,KAAmBC,KAAcC,gBAA4BC,QAElFJ,CAAa","names":["FooterComponent","constructor","this","EventEmitter","validStep","onValidStep","emit","selectors","i0","ctx","FramingSubjectComponent","_class","stepsService","studentStore","globalStorageService","notificationService","DocumentType","Subscription","StepType","ngOnInit","getStudent","framingSubjectSubscription","add","select","studentReducer","subscribe","result","currentStudent","currentStudentStep","currentStep","confirmed","displayValidationMessage","currentStepStatus","EnumStepStatus","depositLimitDate","currentStepId","updateStepAsync","stepId","body","stepStatus","updateStudentCurrentStepAndDispatchToStore","success","core","GlobalStorageService","tslib_es6","AutoUnsubscribe","OralResultComponent","oral_result_component_class","Specialisation","Array","Project","getTranslations","oralResultSubscription","studentProject","thesis","project","examinationSubmitted","examination","code","getPCIMarks","getJuries","miniThesisMark","thesisMark","undefined","projectMark","jury3","supervisor","juries","push","description","fullName","lastName","firstName","coSupervisor","professionalSupervisors","length","find","pro","isReferent","downloadFile","documentUrl","documents","doc","documentTypeCode","downloadUrl","window","open","isValidated","title","subtitle","info","resultTitle","reportTitle","getStepRouteByID","specialization","stepID","getSteps","specializationSteps","STUDENT_STEPS","steps","dispatchTimelineActiveStep","timelineStore","activeStep","dispatch","ThesisTimelineActions","ThesisStepRoute","TimelineComponent","timeline_component_class","subscriptions","forkJoin","student","timeline","getTimeline","onStepperSelectionChanged","event","onStepChanged","selectedIndex","pipe","tap","studentTimelineReducer","setTimeout","ConventionStatus","ConventionAgreementButtonComponent","conventionService","matDialog","studentConvention","convention","updateButtonIcon","updateButtonTitleAndClass","matDialogConfig","getDialogConfig","changeToConventionView","status","openReplaceDialog","changeConventionView","buttonIcon","buttonTitle","buttonClass","dialogConfig","MatDialogConfig","width","disableClose","enterAnimationDuration","exitAnimationDuration","data","content","alignContent","cancelButton","name","className","validButton","DialogComponent","afterClosed","deleteForm","deleteConventionByIdAsync","conventionId","id","updateConventionAndDispatchToStore","error","NumbersOnlyDirective","el","onInputChange","initialValue","nativeElement","value","replace","stopPropagation","ConventionAgreementFormComponent","convention_agreement_form_component_class","formBuilder","countriesService","documentsService","group","Validators","titlesMaxLength","context","fieldsMaxLength","finality","function","email","phone","hrFullName","hrFunction","companyName","companyAddress1","companyAddress2","companyAddress3","companyZipCode","companyCountry","companyMeans","titleModule1","detailModule1","limitDateModule1","titleModule2","detailModule2","limitDateModule2","titleModule3","detailModule3","limitDateModule3","projectForm","professionalSupervisor","professionalForm","hr","hrForm","company","companyForm","module","moduleForm","loadStudentData","getCountryData","currentThesis","currentSpecialisation","specialisation","semesterStartDate","Date","studentSemester","startRegisterAt","currentStudentDocuments","getConventionDocuments","patchFormData","formObservable","loadExistingForm","patchProfessionalFormWithThesisInfo","initializeAutoSave","conventionNotSigned","filter","sortListByDate","signedConvention","getConventionByIdAsync","currentConvention","patchConventionAgreementForm","checkShowAdresses","checkDisableForm","patchValue","get","setValue","of","showAdresse2","showAdresse3","disableForm","disableAllFormControls","conventionAgreementForm","formGroup","disable","getAllFormControls","controls","Object","keys","forEach","key","control","FormGroup","formControl","valueChanges","autosaveInProgress","valid","debounceTime","saveForm","getAllCountriesAsync","countries","countryData","conventionStatus","conventionResult$","professionalRequest","toString","thesisId","conventionRequest","professional","updateConventionByIdAsync","createConventionAsync","validAndSaveForm","openDeleteDialog","reloadView","location","reload","toggleAdresse2","toggleAdresse3","goBackToCurrentStudentStep","returnToStudentFormRequested","downloadConvention","uploadSignedConvention","uploadedDocuments","documentUploading","projectCode","document","incrementNameVersion","request","FileToUpload","File","type","ThesisId","DocumentTypeCode","SpecialisationName","ProjectCode","createDocumentAsync","map","isArchived","updateThesisDocumentsAndDispatchToStore","documentsLength","index","lastIndexOf","extension","slice","deleteSignedConvention","deleteDocumentAsync","documentId","updatedDocuments","validSignedConvention","StudentStepsComponent","student_steps_component_class","stepTypesService","router","getThesisTimeline","getCurrentStudentStepTab","loading","semesters","s","isCurrent","projectId","redirectToStep","displayConventionButton","checkDisplayingConventionButton","getStepTypesBySpecialisation","currentStepTab","getAllStepTypesBySpecialisationIdAsync","specialisationId","onTimelineStepChanged","newActiveStep","route","navigate","displayConvention","StudentStepsService","getStudentAndActiveStep","combineLatest","studentConnected","readonly","factory","RegisterComponent","register_component_class","thesisService","studentStepsService","values","isValid","registrationFormSubscriptions","readonlyStep","currentStudentStepStatus","currentSemester","onRegistrationFormValuesChanges","registrationForm","getStepTypesByProject","validForm","termsAccepted","createOrUpdateThesis","getThesisRequest","requestResult$","updateThesisStep1Async","createThesisAsync","phoneNumber","trim","supervisorId","studentId","partnerId","withPartner","studentPartner","semesterId","validationInProgress","SingleDocUploadComponent","single_doc_upload_component_class","commentService","thesisTimelineStore","singleDocSubscription","getCurrentStepFromTimeline","getComments","displaySmallUploader","checkDisplayingSmallUploader","documentsByType","documentType","checkValidationDocuments","displayFooter","checkDisplayingFooter","commentsPost","stepNumber","commentType","comments","includes","enableValidButton","some","uploadDocuments","uploading","deleteDocument","findIndex","formJustSavedOrValidated","next","stepSubmitted","complete","LiteratureComponent","PlanDraftComponent","PlanComponent","PitchComponent","FinalDraft2Component","FinalDraft1Component","FinalDocComponent","final_doc_component_class","finalDocFormSubscriptions","checkStep","displayUploader","checkDisplayingUploader","switchMap","shouldDisableForm","displayTable","finalDocuments","displayingValidationMessage","take","stepType","getFinalStepTypeBySpecialisation","currentDocuments","getFinalDocuments","displayValidButton","checkNewDocuments","EMPTY","uploadDocument","newDocumentsExist","finalDocForm","updateThesisAndDispatchToStore","thesisInformationRequest","coSupervisorId","updateThesisStep4Async","routes","path","component","canActivateChild","StudentStepGuard","_2","inject","Store","Router","requestedStepID","getStepRouteByRoute","requestedRoute","requestedStep","entries","_","Number","routeConfig","currentStepRoute","Error","parseUrl","children","EvaluationFormComponent","IntermediateDocsFormComponent","OralOrganizationComponent","redirectTo","StudentRoutingModule","RouterModule","StudentModule","CommonStepsModule","SharedModule","TranslateModule","ThesisStepsModule"],"sourceRoot":"webpack:///","sources":["./src/app/shared/components/footer/footer.component.ts","./src/app/shared/components/footer/footer.component.html","./src/app/views/student/components/edi/framing-subject/framing-subject.component.html","./src/app/views/student/components/edi/framing-subject/framing-subject.component.ts","./src/app/views/student/components/oral-result/oral-result.component.html","./src/app/views/student/components/oral-result/oral-result.component.ts","./src/app/core/guards/student-steps.guard.ts","./src/app/shared/components/timeline/timeline.component.html","./src/app/shared/components/timeline/timeline.component.ts","./src/app/shared/api/models/convention-status.ts","./src/app/views/student/components/common/convention-agreement-button/convention-agreement-button.component.ts","./src/app/views/student/components/common/convention-agreement-button/convention-agreement-button.component.html","./src/app/shared/directives/numbers-only.directive.ts","./src/app/views/student/components/common/convention-agreement-form/convention-agreement-form.component.html","./src/app/views/student/components/common/convention-agreement-form/convention-agreement-form.component.ts","./src/app/views/student/student-steps/student-steps.component.html","./src/app/views/student/student-steps/student-steps.component.ts","./src/app/shared/services/student-steps.service.ts","./src/app/views/student/student-steps/steps/register/register.component.html","./src/app/views/student/student-steps/steps/register/register.component.ts","./src/app/views/student/student-steps/components/single-doc-upload/single-doc-upload.component.html","./src/app/views/student/student-steps/components/single-doc-upload/single-doc-upload.component.ts","./src/app/views/student/student-steps/steps/literature/literature.component.ts","./src/app/views/student/student-steps/steps/plan-draft/plan-draft.component.ts","./src/app/views/student/student-steps/steps/plan/plan.component.ts","./src/app/views/student/student-steps/steps/pitch/pitch.component.ts","./src/app/views/student/student-steps/steps/final-draft2/final-draft2.component.ts","./src/app/views/student/student-steps/steps/final-draft1/final-draft1.component.ts","./src/app/views/student/student-steps/steps/final-doc/final-doc.component.html","./src/app/views/student/student-steps/steps/final-doc/final-doc.component.ts","./src/app/views/student/student-routing.module.ts","./src/app/views/student/student.module.ts"],"sourcesContent":["import { Component, EventEmitter, Input, Output } from '@angular/core';\n\n@Component({\n selector: 'app-footer',\n templateUrl: './footer.component.html',\n styleUrls: ['./footer.component.scss'],\n})\nexport class FooterComponent {\n @Input() formIsValid = false;\n @Output() readonly onValidStep = new EventEmitter();\n validStep() {\n this.onValidStep.emit(true);\n }\n}\n","
\n \n
\n","
\n
\n \n
\n
\n {{ 'CONFIRM_FRAMING' | translate }}\n
\n {{ 'CONFIRM_FRAMING2' | translate }}\n
\n
\n 1\">\n
\n \n
\n \n \n
\n","import { Component, EventEmitter, OnInit, Output } from '@angular/core';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { StepsService } from '@sharedServices/steps.service';\nimport * as studentReducer from 'src/store/student/student.reducer';\nimport { AutoUnsubscribe } from 'src/app/shared/decorators/autoUnsubscribe';\nimport { Store } from '@ngrx/store';\nimport GlobalStorageService from '@coreServices/globalStorageService';\nimport { Subscription } from 'rxjs';\nimport { StepResponse } from '@sharedModels/step-response';\nimport { StudentResponse } from '@sharedModels/student-response';\nimport { StudentState } from 'src/store/student/student.states';\nimport { NotificationService } from '@sharedServices/notification.service';\nimport { EnumStepStatus } from '@sharedModels/enum-step-status';\nimport { StepType } from '@sharedEnums/step-type.enum';\n\n@Component({\n selector: 'app-framing-subject',\n templateUrl: './framing-subject.component.html',\n styleUrls: ['./framing-subject.component.scss'],\n})\n@AutoUnsubscribe()\nexport class FramingSubjectComponent implements OnInit {\n @Output() stepChange = new EventEmitter();\n\n documentType = DocumentType.SUBJECT;\n framingSubjectSubscription = new Subscription();\n currentStudent!: StudentResponse;\n confirmed = false;\n displayValidationMessage = false;\n currentStepId!: string;\n depositLimitDate!: string;\n currentStudentStep!: number;\n stepType = StepType.SUBJECT;\n\n constructor(\n private stepsService: StepsService,\n private studentStore: Store,\n private globalStorageService: GlobalStorageService,\n private notificationService: NotificationService\n ) {}\n\n ngOnInit(): void {\n this.getStudent();\n }\n\n getStudent(): void {\n this.framingSubjectSubscription.add(\n this.studentStore.select(studentReducer.getStudent).subscribe(result => {\n this.currentStudent = result;\n if (this.currentStudent) {\n this.currentStudentStep = this.currentStudent.currentStep;\n this.confirmed = this.currentStudentStep > 1;\n this.displayValidationMessage = this.currentStudent.currentStepStatus == EnumStepStatus.ValidationInProgress && this.currentStudentStep == 1;\n this.depositLimitDate = this.currentStudent.depositLimitDate ?? '';\n\n if (this.currentStudent.currentStepId) {\n this.currentStepId = this.currentStudent.currentStepId;\n }\n }\n })\n );\n }\n\n validStep(): void {\n if (this.currentStudent.currentStepId) {\n this.stepsService\n .updateStepAsync({\n stepId: this.currentStudent.currentStepId,\n body: {\n stepStatus: EnumStepStatus.ValidationInProgress,\n },\n })\n .subscribe(result => {\n this.displayValidationMessage = true;\n this.globalStorageService.updateStudentCurrentStepAndDispatchToStore(this.currentStudent, result);\n });\n this.notificationService.success('VALID_SUCCESS');\n }\n }\n}\n","
\n
\n

{{ 'ORGA_TITLE' | translate }}

\n

{{ 'ORGA_MESSAGE' | translate }}

\n
\n\n
\n

{{ title | translate }}

\n

{{ subtitle | translate }}

\n {{ info | translate }}\n
\n \n \n
\n
{{ reportTitle | translate }}
\n

{{ examination.finalGrade1 }}/20

\n
\n
\n {{ examination.examinatedAt | date : 'dd/MM/yyyy' }}\n
\n
\n {{ resultTitle | translate }}\n
\n
\n
\n
{{ jury.description }}
\n
{{ jury.fullName }}
\n
\n
\n
\n
\n
{{ 'THESIS_COMMENT' | translate }}
\n
\n
\n \n \n
\n
\n \n
\n
{{ 'EXACATEXEPRJPRO' | translate }}
\n

{{ examination.finalGrade1 }}/20

\n
\n
{{ 'THESIS_COMMENT' | translate }}
\n
\n
\n \n
\n
\n
{{ 'EXECATMEMPROTUT' | translate }}
\n

{{ examination.finalGrade2 }}/20

\n
\n
{{ 'THESIS_COMMENT' | translate }}
\n
\n
\n
\n
\n
\n
\n
\n\n \n \n
\n
{{ reportTitle | translate }}
\n
\n
{{ '06/07/1998' | date : 'dd/MM/yyyy' }}
\n
\n
\n
{{ 'MINI_THESIS_MARK' | translate }}
\n
{{ miniThesisMark }}/20
\n
\n
\n
{{ 'WEIGHTING' | translate }}
\n
60%
\n
\n
\n \"separating\n
\n
\n
{{ 'PROJECT_MARK' | translate }}
\n
{{ projectMark }}/20
\n
\n
\n
{{ 'WEIGHTING' | translate }}
\n
40%
\n
\n
\n \"separating\n
\n
\n
{{ 'FINAL_MARK' | translate }}
\n

{{ examination.finalGrade1 }}/20

\n
\n
\n
{{ resultTitle | translate }}
\n
\n
\n
{{ jury.description }}
\n
{{ jury.fullName }}
\n
\n
\n
\n
\n
{{ 'THESIS_COMMENT' | translate }}
\n
\n
\n
\n
\n
\n
\n
\n
\n","import { Component, OnInit } from '@angular/core';\nimport { AutoUnsubscribe } from 'src/app/shared/decorators/autoUnsubscribe';\nimport * as studentReducer from 'src/store/student/student.reducer';\nimport { StudentState } from 'src/store/student/student.states';\nimport { Store } from '@ngrx/store';\nimport { Subscription } from 'rxjs';\nimport { StudentResponse } from '@sharedModels/student-response';\nimport { ExaminationResponse } from '@sharedModels/examination-response';\nimport { Jury } from '@sharedModels/jury.model';\nimport { ProfessionalResponse } from '@sharedModels/professional-response';\nimport { ProjectResponse } from '@sharedModels/project-response';\nimport { Project } from '@sharedEnums/project.enum';\nimport { EnumStepStatus } from '@sharedModels/enum-step-status';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { Specialisation } from '@sharedEnums/specialisation.enum';\n\n@Component({\n selector: 'app-oral-result',\n templateUrl: './oral-result.component.html',\n styleUrls: ['./oral-result.component.scss'],\n})\n@AutoUnsubscribe()\nexport class OralResultComponent implements OnInit {\n EnumSpecialisations = Specialisation;\n oralResultSubscription = new Subscription();\n currentStudent!: StudentResponse;\n juries = new Array();\n title!: string;\n subtitle!: string;\n info!: string;\n reportTitle!: string;\n resultTitle!: string;\n examination!: ExaminationResponse;\n studentProject!: ProjectResponse;\n ProjectEnum = Project;\n miniThesisMark: number | undefined;\n projectMark: number | undefined;\n examinationSubmitted = true;\n\n constructor(private studentStore: Store) {}\n\n ngOnInit(): void {\n this.getStudent();\n this.getTranslations();\n }\n\n getStudent(): void {\n this.oralResultSubscription.add(\n this.studentStore.select(studentReducer.getStudent).subscribe(result => {\n this.currentStudent = result;\n if (this.currentStudent) {\n this.studentProject = this.currentStudent.thesis?.project!;\n\n if (this.currentStudent.currentStepStatus !== EnumStepStatus.Validated) {\n this.examinationSubmitted = false;\n }\n\n if (this.currentStudent.thesis?.examination) {\n this.examination = this.currentStudent.thesis.examination;\n }\n\n if (this.studentProject.code === Project.PCI) {\n this.getPCIMarks();\n }\n }\n this.getJuries();\n })\n );\n }\n\n getPCIMarks(): void {\n this.miniThesisMark = this.examination.thesisMark ?? undefined;\n this.projectMark = this.examination.projectMark ?? undefined;\n }\n\n getJuries(): void {\n if (this.currentStudent.thesis?.supervisor)\n this.juries.push({\n description: 'Jury 1',\n fullName: `${this.currentStudent.thesis.supervisor.lastName} ${this.currentStudent.thesis.supervisor.firstName}`,\n });\n\n if (this.currentStudent.thesis?.coSupervisor)\n this.juries.push({\n description: 'Jury 2',\n fullName: `${this.currentStudent.thesis.coSupervisor.lastName} ${this.currentStudent.thesis.coSupervisor.firstName}`,\n });\n\n let jury3!: ProfessionalResponse | undefined;\n if (this.currentStudent.thesis?.professionalSupervisors.length == 1) {\n jury3 = this.currentStudent.thesis?.professionalSupervisors[0];\n } else {\n jury3 = this.currentStudent.thesis?.professionalSupervisors.find(pro => !pro.isReferent);\n }\n\n if (jury3)\n this.juries.push({\n description: 'Jury 3',\n fullName: jury3.fullName ?? '',\n });\n }\n\n downloadFile(): void {\n const documentUrl = this.currentStudent.thesis?.documents.find(doc => doc.documentTypeCode == DocumentType.SIGNEDPV)?.downloadUrl;\n if (documentUrl) window.open(documentUrl, '_blank');\n }\n\n getTranslations(): void {\n if (this.examination?.isValidated) {\n this.title = 'THESIS_VALID_TITLE';\n this.subtitle = 'THESIS_VALID_SUB';\n this.info = 'THESIS_VALID_INFO';\n this.resultTitle = 'THESIS_VALIDATED';\n } else {\n this.title = 'THESIS_NOTVALID_TITLE';\n this.subtitle = 'THESIS_NOTVALID_SUB';\n this.resultTitle = 'THESIS_INVALIDATED';\n }\n this.reportTitle = 'REPORT_TITLE';\n }\n}\n","import { inject } from '@angular/core';\nimport { ActivatedRouteSnapshot, Router, RouterStateSnapshot } from '@angular/router';\nimport { Store } from '@ngrx/store';\nimport { Project } from '@sharedEnums/project.enum';\nimport { Specialisation } from '@sharedEnums/specialisation.enum';\nimport { ThesisStepRoute } from '@sharedEnums/thesis-step-route.enum';\nimport { map } from 'rxjs';\nimport * as studentReducer from 'src/store/student/student.reducer';\nimport { StudentState } from 'src/store/student/student.states';\nimport { ThesisTimelineActions } from 'src/store/thesis-timeline/thesis-timeline.actions';\nimport { ThesisTimelineState } from 'src/store/thesis-timeline/thesis-timeline.states';\n\n/**\n * Acts as a guard for the student steps.\n * * This method satisfies the `CanActivateFn` type from Angular's router.\n * * See https://angular.io/api/router/CanActivateFn\n */\nexport function StudentStepGuard(\n route: ActivatedRouteSnapshot,\n _2: RouterStateSnapshot,\n studentStore = inject(Store),\n timelineStore = inject(Store),\n router = inject(Router)\n) {\n return studentStore.select(studentReducer.getStudent).pipe(\n map(result => {\n const specialization = result.specialisation.name as Specialisation;\n const project = result.thesis?.project?.name as Project | undefined;\n const currentStudentStep = result.currentStep;\n\n const requestedStepID = getStepRouteByRoute(specialization, project, route.routeConfig?.path);\n if (requestedStepID && requestedStepID <= currentStudentStep) {\n dispatchTimelineActiveStep(timelineStore, requestedStepID);\n return true;\n }\n\n const currentStepRoute = getStepRouteByID(specialization, project, currentStudentStep);\n if (!currentStepRoute) {\n throw new Error('Retrieved current student step is not defined in student routes');\n }\n\n if ((!requestedStepID || requestedStepID > currentStudentStep) && currentStepRoute !== route.routeConfig?.path) {\n dispatchTimelineActiveStep(timelineStore, currentStudentStep);\n return router.parseUrl(`/student/${currentStepRoute}`);\n }\n\n return true;\n })\n );\n}\n\nexport function getStepRouteByID(specialization: Specialisation, project: Project | undefined, stepID: number): ThesisStepRoute | undefined {\n const steps = getSteps(specialization, project);\n return steps[stepID];\n}\n\nfunction getStepRouteByRoute(specialization: Specialisation, project: Project | undefined, requestedRoute: string | undefined): number | undefined {\n const steps = getSteps(specialization, project);\n const requestedStep = Object.entries(steps).find(([_, route]) => route === requestedRoute);\n return requestedStep ? Number(requestedStep[0]) : undefined;\n}\n\nfunction getSteps(specialization: Specialisation, project: Project | undefined): StudentSteps {\n const specializationSteps = STUDENT_STEPS[specialization];\n\n let steps: StudentSteps;\n if (!project || !specializationSteps[project]) {\n steps = specializationSteps.steps;\n } else {\n steps = specializationSteps[project] ?? {};\n }\n\n return steps;\n}\n\nfunction dispatchTimelineActiveStep(timelineStore: Store, activeStep: number) {\n timelineStore.dispatch(ThesisTimelineActions.updateThesisTimeline({ activeStep }));\n}\n\ntype SpecializationSteps = {\n steps: StudentSteps;\n} & {\n [key in Project]?: StudentSteps;\n};\n\ntype StudentSteps = { [key: number]: ThesisStepRoute };\n\nconst STUDENT_STEPS: { [key in Specialisation]: SpecializationSteps } = {\n [Specialisation.CLASSIQUE]: {\n steps: {\n 1: ThesisStepRoute.REGISTERSTEP,\n 2: ThesisStepRoute.PITCHSTEP,\n 3: ThesisStepRoute.INTERMEDIATESTEP,\n 4: ThesisStepRoute.FINALDOCSTEP,\n 5: ThesisStepRoute.EVALUATIONSTEP,\n 6: ThesisStepRoute.ORGAEXAMINATIONSTEP,\n 7: ThesisStepRoute.RESEXAMINATIONSTEP,\n },\n [Project.PCI]: {\n 4: ThesisStepRoute.EVALUATIONSTEP,\n 5: ThesisStepRoute.RESEXAMINATIONSTEP,\n },\n [Project.IBL]: {\n 2: ThesisStepRoute.INTERMEDIATESTEP,\n 3: ThesisStepRoute.FINALDOCDRAFT1,\n 4: ThesisStepRoute.FINALDOCDRAFT2,\n 5: ThesisStepRoute.FINALDOCSTEP,\n 6: ThesisStepRoute.EVALUATIONSTEP,\n 7: ThesisStepRoute.ORGAEXAMINATIONSTEP,\n 8: ThesisStepRoute.RESEXAMINATIONSTEP,\n },\n },\n [Specialisation.ALTERNANCE]: {\n steps: {\n 1: ThesisStepRoute.REGISTERSTEP,\n 2: ThesisStepRoute.PITCHSTEP,\n 3: ThesisStepRoute.INTERMEDIATESTEP,\n 4: ThesisStepRoute.FINALDOCSTEP,\n 5: ThesisStepRoute.EVALUATIONSTEP,\n 6: ThesisStepRoute.ORGAEXAMINATIONSTEP,\n 7: ThesisStepRoute.RESEXAMINATIONSTEP,\n },\n },\n [Specialisation.EDI]: {\n steps: {\n 1: ThesisStepRoute.SUBJECTSTEP,\n 2: ThesisStepRoute.LITERATURESTEP,\n 3: ThesisStepRoute.PLANDRAFTSTEP,\n 4: ThesisStepRoute.PLANSTEP,\n 5: ThesisStepRoute.FINALDOCSTEP,\n 6: ThesisStepRoute.EVALUATIONSTEP,\n 7: ThesisStepRoute.RESEXAMINATIONSTEP,\n },\n },\n};\n","\n \n {{ step.key | translate }}\n\n \n check\n \n \n\n","import { Component, EventEmitter, OnInit, Output } from '@angular/core';\nimport { Observable, Subscription, forkJoin, tap } from 'rxjs';\nimport * as studentReducer from 'src/store/student/student.reducer';\nimport { Store } from '@ngrx/store';\nimport { StepperSelectionEvent } from '@angular/cdk/stepper';\nimport { AutoUnsubscribe } from '../../decorators/autoUnsubscribe';\nimport { StepTypeResponse } from '@sharedModels/step-type-response';\nimport { StudentState } from 'src/store/student/student.states';\nimport { ThesisTimelineState } from 'src/store/thesis-timeline/thesis-timeline.states';\nimport * as studentTimelineReducer from 'src/store/thesis-timeline/thesis-timeline.reducer';\nimport { StudentResponse } from '../../api/models';\n\n@Component({\n selector: 'app-timeline',\n templateUrl: './timeline.component.html',\n})\n@AutoUnsubscribe()\nexport class TimelineComponent implements OnInit {\n @Output() readonly onStepChanged = new EventEmitter();\n\n steps: Array = [];\n activeStep = 1;\n currentStudentStep = 0;\n\n private readonly subscriptions = new Subscription();\n\n constructor(private readonly studentStore: Store, private readonly timelineStore: Store) {}\n\n /** Initializes the component by subscribing to getting the student and the timeline observables. */\n ngOnInit(): void {\n this.subscriptions.add(\n forkJoin({\n student: this.getStudent(),\n timeline: this.getTimeline(),\n }).subscribe()\n );\n }\n\n /**\n * Emits the new active step selected in provided event.\n *\n * @param event - The event object containing information about the step change.\n */\n onStepperSelectionChanged(event: StepperSelectionEvent): void {\n this.onStepChanged.emit(event.selectedIndex + 1);\n }\n\n /**\n * Retrieves the student from the student store then saves it's current step and dispatches it as active step.\n *\n * @return An observable that emits the student connected response.\n */\n private getStudent(): Observable {\n return this.studentStore.select(studentReducer.getStudent).pipe(\n tap(result => {\n if (result) {\n this.currentStudentStep = result.currentStep;\n }\n })\n );\n }\n\n /**\n * Retrieves the timeline from the timeline store then saves it's steps and active step if it's different from the current.\n *\n * @return An observable that emits the timeline values.\n */\n private getTimeline() {\n return this.timelineStore.select(studentTimelineReducer.getThesisTimeline).pipe(\n tap(result => {\n this.steps = result.steps;\n\n if (result.activeStep !== this.activeStep) {\n setTimeout(() => {\n this.activeStep = result.activeStep;\n });\n }\n })\n );\n }\n}\n","/* tslint:disable */\n/* eslint-disable */\nexport enum ConventionStatus {\n InProgress = 'InProgress',\n ValidationInProgress = 'ValidationInProgress',\n Validated = 'Validated',\n Signed = 'Signed'\n}\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\nimport { StudentResponse } from '@sharedModels/student-response';\nimport { ConventionResponse } from '@sharedModels/convention-response';\nimport { ConventionStatus } from '@sharedModels/convention-status';\nimport { MatDialog, MatDialogConfig } from '@angular/material/dialog';\nimport { DialogComponent } from '@sharedComponents/dialog/dialog.component';\nimport { ConventionsService } from '@sharedServices/conventions.service';\nimport { NotificationService } from 'src/app/shared/services/notification.service';\nimport GlobalStorageService from '@coreServices/globalStorageService';\n@Component({\n selector: 'app-convention-agreement-button',\n templateUrl: './convention-agreement-button.component.html',\n styleUrls: ['./convention-agreement-button.component.scss'],\n})\nexport class ConventionAgreementButtonComponent implements OnInit {\n @Input() currentStudent!: StudentResponse;\n @Output() changeConventionView = new EventEmitter();\n\n studentConvention: ConventionResponse | undefined;\n\n buttonClass: string = 'add-button';\n buttonIcon: string = 'add';\n buttonTitle: string = 'ADD_COLLABORATION';\n\n matDialogConfig!: MatDialogConfig;\n\n constructor(\n private conventionService: ConventionsService,\n private notificationService: NotificationService,\n private globalStorageService: GlobalStorageService,\n public matDialog: MatDialog\n ) {}\n\n ngOnInit(): void {\n this.studentConvention = this.currentStudent.thesis?.convention;\n this.updateButtonIcon();\n this.updateButtonTitleAndClass();\n this.matDialogConfig = this.getDialogConfig();\n }\n\n changeToConventionView(): void {\n if (this.studentConvention?.status === ConventionStatus.Signed) {\n this.openReplaceDialog();\n } else {\n this.changeConventionView.emit();\n }\n }\n\n updateButtonIcon(): void {\n if (this.studentConvention && this.studentConvention.status !== ConventionStatus.Signed) {\n this.buttonIcon = 'visibility';\n }\n }\n\n updateButtonTitleAndClass(): void {\n if (this.studentConvention) {\n switch (this.studentConvention.status) {\n case ConventionStatus.Validated:\n this.buttonTitle = 'AVAILABLE_COLLABORATION';\n this.buttonClass = 'available-button';\n break;\n case ConventionStatus.InProgress:\n case ConventionStatus.ValidationInProgress:\n this.buttonTitle = 'IN_PROGRESS_COLLABORATION';\n this.buttonClass = 'in-progress-button';\n break;\n }\n }\n }\n\n getDialogConfig(): MatDialogConfig {\n const dialogConfig = new MatDialogConfig();\n dialogConfig.width = '500px';\n dialogConfig.disableClose = false;\n dialogConfig.enterAnimationDuration = '300ms';\n dialogConfig.exitAnimationDuration = '200ms';\n dialogConfig.data = {\n title: 'REPLACE_CONVENTION_TITLE',\n content: 'REPLACE_CONVENTION_CONTENT',\n alignContent: 'center',\n cancelButton: { name: 'CANCEL', className: 'cancel-button' },\n validButton: { name: 'REPLACE_CONVENTION_CONFIRM' },\n };\n return dialogConfig;\n }\n\n openReplaceDialog(): void {\n const dialogRef = this.matDialog.open(DialogComponent, this.matDialogConfig);\n dialogRef.afterClosed().subscribe(result => {\n if (result) {\n this.deleteForm();\n } else {\n this.changeConventionView.emit();\n }\n });\n }\n\n deleteForm(): void {\n if (this.studentConvention) {\n this.conventionService\n .deleteConventionByIdAsync({\n conventionId: this.studentConvention.id,\n })\n .subscribe(result => {\n if (result) {\n this.notificationService.success('DELETE_SUCCESS');\n this.globalStorageService.updateConventionAndDispatchToStore(this.currentStudent, undefined);\n this.changeConventionView.emit();\n } else {\n this.notificationService.error('ERROR.SAVE');\n }\n });\n }\n }\n}\n","\n","import { Directive, ElementRef, HostListener } from '@angular/core';\n\n@Directive({\n selector: '[numbersOnly]'\n})\nexport class NumbersOnlyDirective {\n constructor(private el: ElementRef) { }\n\n @HostListener('input', ['$event']) onInputChange(event: Event) {\n const initialValue = this.el.nativeElement.value;\n this.el.nativeElement.value = initialValue.replace(/[^0-9]/g, '');\n if (initialValue !== this.el.nativeElement.value) {\n event.stopPropagation();\n }\n }\n}\n","
\n
\n \n
\n

{{ 'CONVENTION_TITLE' | translate }}

\n
\n

{{ 'FIELDS_MANDATORY' | translate }}

\n
\n\n \n

\n \n {{ 'FORM_PENDING_APPROVAL' | translate }}\n \n \n {{ 'AVAILABLE_COLLABORATION' | translate }}\n \n

\n
\n\n \n
\n \n \n
\n\n
\n \n \n
{{ 'CONSULTING_PROJECT_TITLE' | translate }}
\n
\n \n \n \n {{ projectForm.controls.title.value?.length }} / {{ titlesMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n {{ projectForm.controls.context.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n {{ projectForm.controls.finality.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n\n \n
\n \n
{{ 'PRO_SUP_INFO' | translate }}
\n
\n \n
{{ 'PRO_TUTOR_INFO' | translate }}
\n
\n
\n
\n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n
\n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n {{ 'ERROR.EMAIL' | translate }}\n \n \n
\n
\n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n\n \n
\n
{{ 'HR_INFO' | translate }}
\n
\n
\n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n\n \n
\n
{{ 'COMPANY_TITLE' | translate }}
\n
\n \n \n \n {{ companyForm.controls.companyName.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n {{ companyForm.controls.companyAddress1.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n \n
\n
\n \n \n \n {{ companyForm.controls.companyAddress2.value?.length }} / {{ fieldsMaxLength }} \n \n
\n
\n \n
\n
\n \n \n \n {{ companyForm.controls.companyAddress3.value?.length }} / {{ fieldsMaxLength }} \n \n
\n
\n
\n
\n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n \n {{ country.name }}\n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n \n \n \n {{ companyForm.controls.companyMeans.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n\n \n
\n
{{ 'MODULE_TITLE' | translate }}
\n
\n \n \n \n {{ moduleForm.controls.titleModule1.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n {{ moduleForm.controls.detailModule1.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n \n \n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n \n \n \n {{ moduleForm.controls.titleModule2.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n {{ moduleForm.controls.detailModule2.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n \n \n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n \n \n \n {{ moduleForm.controls.titleModule3.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n \n \n \n {{ moduleForm.controls.detailModule3.value?.length }} / {{ fieldsMaxLength }} \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n \n \n \n \n \n \n {{ 'ERROR.REQUIRED' | translate }}\n \n \n
\n
\n
\n \n
\n\n \n
\n
\n \n \n \n \n
\n
\n
\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\nimport { AbstractControl, FormBuilder, FormGroup, Validators } from '@angular/forms';\nimport { debounceTime, map, Observable, of, Subscription, tap } from 'rxjs';\nimport { AutoUnsubscribe } from 'src/app/shared/decorators/autoUnsubscribe';\nimport { StudentResponse } from '@sharedModels/student-response';\nimport { CreateOrUpdateConventionRequest } from '@sharedModels/create-or-update-convention-request';\nimport { ConventionResponse } from '@sharedModels/convention-response';\nimport { ThesisResponse } from '@sharedModels/thesis-response';\nimport { ConventionsService } from '@sharedServices/conventions.service';\nimport { NotificationService } from 'src/app/shared/services/notification.service';\nimport {\n CommentResponse,\n ConventionStatus,\n CountryResponse,\n CreateOrUpdateProfessionalRequest,\n DocumentResponse,\n SemesterResponse,\n SpecialisationResponse,\n} from 'src/app/shared/api/models';\nimport { Specialisation } from '@sharedEnums/specialisation.enum';\nimport { MatDialog, MatDialogConfig } from '@angular/material/dialog';\nimport { DialogComponent } from '@sharedComponents/dialog/dialog.component';\nimport { CountriesService } from '@sharedServices/countries.service';\nimport GlobalStorageService from '@coreServices/globalStorageService';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { DocumentsService } from '@sharedServices/documents.service';\nimport { sortListByDate } from '@sharedServices/tools.service';\n\n@Component({\n selector: 'app-convention-agreement-form',\n templateUrl: './convention-agreement-form.component.html',\n styleUrls: ['./convention-agreement-form.component.scss'],\n})\n@AutoUnsubscribe()\nexport class ConventionAgreementFormComponent implements OnInit {\n @Input() currentStudent!: StudentResponse;\n @Input() studentSemester!: SemesterResponse;\n @Output() returnToStudentFormRequested = new EventEmitter();\n\n conventionAgreementSubscription = new Subscription();\n\n currentStudentStep!: number;\n currentThesis!: ThesisResponse;\n currentSpecialisation!: SpecialisationResponse;\n currentConvention: ConventionResponse | undefined;\n semesterStartDate!: Date;\n countryData!: CountryResponse[];\n\n conventionNotSigned!: DocumentResponse[];\n signedConvention!: DocumentResponse[];\n currentStudentDocuments!: DocumentResponse[];\n\n matDialogConfig!: MatDialogConfig;\n\n titlesMaxLength = 200;\n fieldsMaxLength = 2000;\n debounceTime = 1000;\n\n disableForm = false;\n showAdresse2 = false;\n showAdresse3 = false;\n displayValidationMessage = false;\n documentUploading = false;\n autosaveInProgress = false;\n\n SpecialisationEnum = Specialisation;\n ConventionStatusEnum = ConventionStatus;\n\n // Forms init\n projectForm: FormGroup = this.formBuilder.group({\n title: [null, [Validators.required, Validators.maxLength(this.titlesMaxLength)]],\n context: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n finality: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n });\n\n professionalForm: FormGroup = this.formBuilder.group({\n fullName: [null, [Validators.required]],\n function: [null, [Validators.required]],\n email: [null, [Validators.required, Validators.email]],\n phone: [null],\n });\n\n hrForm: FormGroup = this.formBuilder.group({\n hrFullName: [null, [Validators.required]],\n hrFunction: [null, [Validators.required]],\n });\n\n companyForm: FormGroup = this.formBuilder.group({\n companyName: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n companyAddress1: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n companyAddress2: [null, [Validators.maxLength(this.fieldsMaxLength)]],\n companyAddress3: [null, [Validators.maxLength(this.fieldsMaxLength)]],\n companyZipCode: [null, [Validators.required]],\n companyCountry: [null, [Validators.required]],\n companyMeans: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n });\n\n moduleForm: FormGroup = this.formBuilder.group({\n titleModule1: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n detailModule1: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n limitDateModule1: [null, [Validators.required]],\n titleModule2: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n detailModule2: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n limitDateModule2: [null, [Validators.required]],\n titleModule3: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n detailModule3: [null, [Validators.required, Validators.maxLength(this.fieldsMaxLength)]],\n limitDateModule3: [null, [Validators.required]],\n });\n\n conventionAgreementForm: FormGroup = this.formBuilder.group({\n project: this.projectForm,\n professionalSupervisor: this.professionalForm,\n hr: this.hrForm,\n company: this.companyForm,\n module: this.moduleForm,\n });\n\n constructor(\n private formBuilder: FormBuilder,\n private conventionService: ConventionsService,\n private countriesService: CountriesService,\n private notificationService: NotificationService,\n private documentsService: DocumentsService,\n private globalStorageService: GlobalStorageService,\n public matDialog: MatDialog\n ) {}\n\n ngOnInit(): void {\n this.loadStudentData();\n this.getCountryData();\n this.matDialogConfig = this.getDialogConfig();\n }\n\n loadStudentData(): void {\n this.currentStudentStep = this.currentStudent.currentStep;\n this.currentThesis = this.currentStudent.thesis!;\n this.currentSpecialisation = this.currentStudent.specialisation!;\n this.semesterStartDate = new Date(this.studentSemester.startRegisterAt);\n\n if (this.currentStudent.thesis?.documents) {\n this.currentStudentDocuments = this.currentStudent?.thesis?.documents;\n this.getConventionDocuments(this.currentStudentDocuments);\n }\n\n this.patchFormData();\n }\n\n patchFormData(): void {\n let formObservable: Observable | null = null;\n\n if (this.currentThesis.convention) {\n // Convention exist, load it\n formObservable = this.loadExistingForm();\n } else if (this.currentThesis.professionalSupervisors) {\n // Convention doesn't exist, try to load professional supervisor info\n formObservable = this.patchProfessionalFormWithThesisInfo();\n }\n\n formObservable?.subscribe(() => {\n this.initializeAutoSave();\n });\n }\n\n getConventionDocuments(documents: DocumentResponse[]): void {\n this.conventionNotSigned = documents.filter(doc => doc.documentTypeCode == DocumentType.CONV);\n if (this.conventionNotSigned && this.conventionNotSigned.length > 0) {\n this.conventionNotSigned = sortListByDate(this.conventionNotSigned) as DocumentResponse[];\n }\n this.signedConvention = documents.filter(doc => doc.documentTypeCode == DocumentType.SIGNEDCONV);\n if (this.signedConvention && this.signedConvention.length > 0) {\n this.signedConvention = sortListByDate(this.signedConvention) as DocumentResponse[];\n }\n }\n\n loadExistingForm(): Observable {\n let conventionResult$ = this.conventionService.getConventionByIdAsync({\n conventionId: this.currentThesis.convention?.id,\n });\n\n return conventionResult$.pipe(\n tap(result => {\n if (result) {\n this.currentConvention = result;\n this.patchConventionAgreementForm(result);\n this.checkShowAdresses();\n this.checkDisableForm();\n }\n })\n );\n }\n\n patchConventionAgreementForm(convention: ConventionResponse): void {\n this.projectForm.patchValue({ ...convention });\n this.professionalForm.patchValue({ ...convention.professionalSupervisor });\n this.hrForm.patchValue({ ...convention });\n this.companyForm.patchValue({ ...convention });\n this.moduleForm.patchValue({ ...convention });\n }\n\n patchProfessionalFormWithThesisInfo(): Observable {\n if (this.currentThesis.professionalSupervisors[0]) {\n this.professionalForm.get('fullName')?.setValue(this.currentThesis.professionalSupervisors[0].fullName ?? null);\n this.professionalForm.get('email')?.setValue(this.currentThesis.professionalSupervisors[0].email ?? null);\n this.professionalForm.get('phone')?.setValue(this.currentThesis.professionalSupervisors[0].phone ?? null);\n this.companyForm.get('companyName')?.setValue(this.currentThesis.professionalSupervisors[0].companyName ?? null);\n }\n return of(null);\n }\n\n checkShowAdresses(): void {\n if (this.currentConvention) {\n if (this.currentConvention.companyAddress2 && this.currentConvention.companyAddress2 != '') {\n this.showAdresse2 = true;\n }\n if (this.currentConvention.companyAddress3 && this.currentConvention.companyAddress3 != '') {\n this.showAdresse3 = true;\n }\n }\n }\n\n checkDisableForm(): void {\n if (this.currentConvention) {\n this.disableForm = this.currentConvention.status !== ConventionStatus.InProgress;\n } else {\n this.disableForm = false;\n }\n\n if (this.disableForm) {\n this.disableAllFormControls(this.conventionAgreementForm);\n }\n }\n\n disableAllFormControls(formGroup: FormGroup): void {\n formGroup.disable();\n }\n\n getAllFormControls(formGroup: FormGroup): AbstractControl[] {\n const controls: AbstractControl[] = [];\n Object.keys(formGroup.controls).forEach(key => {\n const control = formGroup.controls[key];\n if (control instanceof FormGroup) {\n controls.push(...this.getAllFormControls(control));\n } else {\n controls.push(control);\n }\n });\n return controls;\n }\n\n initializeAutoSave(): void {\n for (const formControl of this.getAllFormControls(this.conventionAgreementForm)) {\n formControl.valueChanges\n .pipe(\n tap(() => (this.autosaveInProgress = this.conventionAgreementForm.valid)),\n debounceTime(this.debounceTime)\n )\n .subscribe(value => {\n if (value && value != '' && !this.disableForm) {\n this.saveForm(ConventionStatus.InProgress);\n }\n });\n }\n }\n\n getCountryData(): void {\n this.countriesService.getAllCountriesAsync().subscribe(countries => {\n this.countryData = countries;\n });\n }\n\n saveForm(conventionStatus?: ConventionStatus): Observable {\n let conventionResult$: Observable;\n\n let professionalRequest: CreateOrUpdateProfessionalRequest = {\n ...this.professionalForm.value,\n phone: this.professionalForm.value.phone ? this.professionalForm.value.phone.toString() : null,\n thesisId: this.currentThesis.id,\n companyName: this.companyForm.value.companyName,\n isReferent: true,\n };\n\n let conventionRequest: CreateOrUpdateConventionRequest = {\n thesisId: this.currentThesis.id,\n ...this.projectForm.value,\n ...this.hrForm.value,\n ...this.companyForm.value,\n ...this.moduleForm.value,\n limitDateModule1: this.moduleForm.value.limitDateModule1,\n limitDateModule2: this.moduleForm.value.limitDateModule2,\n limitDateModule3: this.moduleForm.value.limitDateModule3,\n professional: {\n ...professionalRequest,\n },\n status: conventionStatus ? conventionStatus : ConventionStatus.InProgress,\n };\n\n if (this.currentConvention) {\n conventionResult$ = this.conventionService.updateConventionByIdAsync({\n conventionId: this.currentConvention.id,\n body: conventionRequest,\n });\n } else {\n conventionResult$ = this.conventionService.createConventionAsync({\n body: conventionRequest,\n });\n }\n\n conventionResult$.subscribe(result => {\n if (result) {\n this.currentConvention = result;\n this.globalStorageService.updateConventionAndDispatchToStore(this.currentStudent, result);\n this.notificationService.success('SAVE_SUCCESS');\n } else {\n this.notificationService.error('ERROR.SAVE');\n }\n });\n\n return conventionResult$;\n }\n\n validAndSaveForm(): void {\n if (this.conventionAgreementForm.valid) {\n this.saveForm(ConventionStatus.ValidationInProgress).subscribe(result => {\n if (result) {\n this.disableForm = true;\n this.disableAllFormControls(this.conventionAgreementForm);\n this.displayValidationMessage = true;\n if (this.currentConvention) {\n this.currentConvention.status = ConventionStatus.ValidationInProgress;\n }\n this.currentThesis = {\n ...this.currentThesis,\n convention: result,\n };\n }\n });\n }\n }\n\n openDeleteDialog(): void {\n const dialogRef = this.matDialog.open(DialogComponent, this.matDialogConfig);\n dialogRef.afterClosed().subscribe(result => {\n if (result) {\n this.deleteForm();\n }\n });\n }\n\n deleteForm(): void {\n if (this.currentConvention) {\n this.conventionService\n .deleteConventionByIdAsync({\n conventionId: this.currentConvention.id,\n })\n .subscribe(result => {\n if (result) {\n this.notificationService.success('DELETE_SUCCESS');\n this.reloadView();\n } else {\n this.notificationService.error('ERROR.SAVE');\n }\n });\n }\n }\n\n reloadView(): void {\n setTimeout(() => {\n location.reload();\n }, 1000);\n }\n\n toggleAdresse2(): void {\n this.showAdresse2 = !this.showAdresse2;\n }\n\n toggleAdresse3(): void {\n this.showAdresse3 = !this.showAdresse3;\n }\n\n goBackToCurrentStudentStep(): void {\n this.returnToStudentFormRequested.emit();\n }\n\n downloadConvention(): void {\n if (this.conventionNotSigned) {\n window.open(this.conventionNotSigned[0].downloadUrl, '_blank');\n }\n }\n\n uploadSignedConvention(uploadedDocuments: File[]) {\n this.documentUploading = true;\n const thesisId = this.currentStudent?.thesis?.id;\n const projectCode = this.currentThesis.project?.code;\n if (thesisId && projectCode) {\n uploadedDocuments.forEach(document => {\n const name = this.incrementNameVersion(document, this.signedConvention.length);\n const request = {\n FileToUpload: new File([document], name, { type: document.type }),\n ThesisId: thesisId,\n DocumentTypeCode: DocumentType.SIGNEDCONV,\n SpecialisationName: this.currentStudent.specialisation.name,\n ProjectCode: projectCode,\n };\n\n this.documentsService\n .createDocumentAsync({ body: request })\n .pipe(\n map((result: DocumentResponse) => {\n if (result.id) {\n this.signedConvention = [...this.signedConvention, result];\n this.currentStudentDocuments = [...this.currentStudentDocuments, ...this.signedConvention.filter(doc => !doc.isArchived)];\n this.globalStorageService.updateThesisDocumentsAndDispatchToStore(this.currentStudent, this.currentStudentDocuments);\n }\n }),\n tap(() => (this.documentUploading = false))\n )\n .subscribe();\n });\n }\n }\n\n incrementNameVersion(document: File, documentsLength: number): string {\n const index = document.name?.lastIndexOf('.');\n const extension = document.name?.slice(index);\n return `${document.name?.slice(0, index)}-v${documentsLength + 1}${extension}`;\n }\n\n deleteSignedConvention(id: string) {\n this.documentUploading = true;\n this.documentsService\n .deleteDocumentAsync({ documentId: id })\n .pipe(\n map(result => {\n if (result) {\n const updatedDocuments = this.currentStudentDocuments.filter(doc => doc.id != id);\n this.signedConvention = updatedDocuments.filter(doc => doc.documentTypeCode === DocumentType.SIGNEDCONV);\n this.globalStorageService.updateThesisDocumentsAndDispatchToStore(this.currentStudent, updatedDocuments);\n }\n }),\n tap(() => (this.documentUploading = false))\n )\n .subscribe();\n }\n\n validSignedConvention(): void {\n this.saveForm(ConventionStatus.Signed).subscribe(result => {\n if (result) {\n this.disableForm = true;\n this.displayValidationMessage = true;\n if (this.currentConvention) {\n this.currentConvention.status = ConventionStatus.Signed;\n }\n this.currentThesis = {\n ...this.currentThesis,\n convention: result,\n };\n }\n });\n }\n\n getDialogConfig(): MatDialogConfig {\n const dialogConfig = new MatDialogConfig();\n dialogConfig.width = '500px';\n dialogConfig.disableClose = false;\n dialogConfig.enterAnimationDuration = '300ms';\n dialogConfig.exitAnimationDuration = '200ms';\n dialogConfig.data = {\n title: 'DELETE_CONVENTION_TITLE',\n content: 'DELETE_CONVENTION_CONTENT',\n alignContent: 'center',\n cancelButton: { name: 'CANCEL', className: 'cancel-button' },\n validButton: { name: 'DELETE_CONVENTION_CONFIRM' },\n };\n return dialogConfig;\n }\n}\n","
\n
\n \n
\n \n
\n \n
\n\n \n \n \n\n \n
\n \n
\n\n \n \n \n\n \n \n \n\n \n\n \n \n
\n
\n
\n
\n
\n","import { Component, OnInit } from '@angular/core';\nimport { Store } from '@ngrx/store';\nimport { StudentState } from 'src/store/student/student.states';\nimport * as studentReducer from 'src/store/student/student.reducer';\nimport { Subscription, forkJoin, tap } from 'rxjs';\nimport { AutoUnsubscribe } from 'src/app/shared/decorators/autoUnsubscribe';\nimport { Specialisation } from '@sharedEnums/specialisation.enum';\nimport { ExaminationResponse } from '@sharedModels/examination-response';\nimport { SpecialisationResponse } from '@sharedModels/specialisation-response';\nimport { StepTypeResponse } from '@sharedModels/step-type-response';\nimport { ProjectResponse } from '@sharedModels/project-response';\nimport { Project } from '@sharedEnums/project.enum';\nimport { StepTypesService } from '@sharedServices/step-types.service';\nimport { Router } from '@angular/router';\nimport { StudentResponse } from '@sharedModels/student-response';\nimport { SemesterResponse } from '@sharedModels/semester-response';\nimport { ThesisTimelineState } from 'src/store/thesis-timeline/thesis-timeline.states';\nimport { ThesisTimelineActions } from 'src/store/thesis-timeline/thesis-timeline.actions';\nimport { getThesisTimeline } from 'src/store/thesis-timeline/thesis-timeline.reducer';\nimport { getStepRouteByID } from 'src/app/core/guards/student-steps.guard';\n\n@Component({\n selector: 'app-student-steps',\n host: { class: 'app-creation' },\n templateUrl: './student-steps.component.html',\n styleUrls: ['./student-steps.component.scss'],\n})\n@AutoUnsubscribe()\nexport class StudentStepsComponent implements OnInit {\n projectId: string = '';\n specialisationEnum = Specialisation;\n currentStudentStep?: number;\n loading = true;\n currentStudent!: StudentResponse;\n studentSemester: SemesterResponse | undefined;\n specialisation: SpecialisationResponse | undefined;\n project: ProjectResponse | undefined;\n examination: ExaminationResponse | undefined;\n currentStepTab: StepTypeResponse | undefined;\n coordinatorMode!: boolean;\n displayConventionButton = false;\n displayConvention = false;\n\n private readonly subscriptions = new Subscription();\n\n constructor(\n private readonly studentStore: Store,\n private readonly stepTypesService: StepTypesService,\n private readonly timelineStore: Store,\n private readonly router: Router\n ) {}\n\n ngOnInit(): void {\n this.subscriptions.add(\n forkJoin({\n student: this.getStudent(),\n timeline: this.timelineStore.select(getThesisTimeline).pipe(\n tap(result => {\n this.getCurrentStudentStepTab(result.steps);\n })\n ),\n }).subscribe()\n );\n }\n\n getStudent() {\n return this.studentStore.select(studentReducer.getStudent).pipe(\n tap(result => {\n this.currentStudent = result;\n if (this.currentStudent) {\n this.loading = false;\n\n this.studentSemester = this.currentStudent.thesis?.semesters?.find(s => s.isCurrent);\n this.specialisation = result.specialisation;\n this.examination = result.thesis?.examination;\n\n if (result.thesis?.project?.id) {\n this.project = result.thesis.project;\n this.projectId = result.thesis.project.id;\n }\n\n this.currentStudentStep = this.currentStudent.currentStep;\n this.redirectToStep(this.currentStudentStep);\n\n this.displayConventionButton = this.checkDisplayingConventionButton(this.currentStudentStep, this.specialisation, this.project);\n if (this.projectId && this.projectId !== '') {\n this.getStepTypesBySpecialisation();\n }\n }\n })\n );\n }\n\n getCurrentStudentStepTab(steps: StepTypeResponse[]): void {\n if (!steps || !this.currentStudentStep) {\n return;\n }\n\n this.currentStepTab = steps[this.currentStudentStep - 1];\n }\n\n // Timeline steps by specialisation\n getStepTypesBySpecialisation() {\n this.stepTypesService\n .getAllStepTypesBySpecialisationIdAsync({\n specialisationId: this.specialisation?.id,\n projectId: this.projectId,\n })\n .subscribe(steps => {\n this.timelineStore.dispatch(ThesisTimelineActions.updateThesisTimeline({ steps }));\n });\n }\n\n onTimelineStepChanged(newActiveStep: number) {\n if (this.currentStudentStep === newActiveStep) return;\n\n this.redirectToStep(newActiveStep);\n this.currentStudentStep = newActiveStep;\n }\n\n redirectToStep(stepID: number) {\n if (!this.specialisation?.name || !this.project?.name || !this.currentStudentStep) return;\n\n const route = getStepRouteByID(this.specialisation.name as Specialisation, this.project.name as Project, stepID);\n this.router.navigate(['student', route]);\n }\n\n changeConventionView(): void {\n this.displayConvention = !this.displayConvention;\n }\n\n checkDisplayingConventionButton(currentStudentStep: number, specialisation: SpecialisationResponse, projectId: ProjectResponse | undefined) {\n return (\n currentStudentStep >= 2 &&\n ((specialisation?.name === Specialisation.CLASSIQUE && (projectId?.code === Project.IBL || projectId?.code === Project.PC)) ||\n (specialisation?.name === Specialisation.ALTERNANCE && projectId?.code === Project.PC))\n );\n }\n}\n","import { Injectable } from '@angular/core';\nimport { Store } from '@ngrx/store';\nimport { combineLatest, map } from 'rxjs';\nimport * as studentReducer from 'src/store/student/student.reducer';\nimport { StudentState } from 'src/store/student/student.states';\nimport { getThesisTimeline } from 'src/store/thesis-timeline/thesis-timeline.reducer';\nimport { ThesisTimelineState } from 'src/store/thesis-timeline/thesis-timeline.states';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class StudentStepsService {\n constructor(private readonly studentStore: Store, private readonly timelineStore: Store) {}\n\n getStudentAndActiveStep() {\n return combineLatest([\n this.studentStore.select(studentReducer.getStudent),\n this.timelineStore.select(getThesisTimeline).pipe(map(result => result.activeStep)),\n ]).pipe(\n map(([student, activeStep]) => {\n return {\n studentConnected: student,\n activeStep,\n // Step should be readonly if the active step has already been completed\n readonly: activeStep < student.currentStep,\n };\n })\n );\n }\n}\n","\n\n\n
\n

{{ currentTitle | translate }}

\n\n \n\n \n
\n
\n \n \n \n
\n
\n
\n\n\n","import { Component, OnInit } from '@angular/core';\nimport { MatDialog, MatDialogConfig } from '@angular/material/dialog';\nimport { DialogComponent } from '@sharedComponents/dialog/dialog.component';\nimport { map, Observable, Subscription } from 'rxjs';\nimport { Store } from '@ngrx/store';\nimport { ThesisService } from '@sharedServices/thesis.service';\nimport { EnumStepStatus } from '@sharedModels/enum-step-status';\nimport { ThesisResponse } from '@sharedModels/thesis-response';\nimport { AutoUnsubscribe } from 'src/app/shared/decorators/autoUnsubscribe';\nimport { NotificationService } from 'src/app/shared/services/notification.service';\nimport { StepType } from '@sharedEnums/step-type.enum';\nimport { SpecialisationResponse } from '@sharedModels/specialisation-response';\nimport { StudentResponse } from '@sharedModels/student-response';\nimport { SemesterResponse } from '@sharedModels/semester-response';\nimport { StepTypesService } from '@sharedServices/step-types.service';\nimport { ThesisTimelineState } from 'src/store/thesis-timeline/thesis-timeline.states';\nimport { ThesisTimelineActions } from 'src/store/thesis-timeline/thesis-timeline.actions';\nimport { StudentStepsService } from '@sharedServices/student-steps.service';\nimport { RegistrationFormValues } from 'src/app/shared/modules/thesis-steps/components/registration-form/registration-form.component';\nimport { CreateOrUpdateThesisRequest } from '@sharedModels/create-or-update-thesis-request';\n\n@Component({\n selector: 'app-register',\n templateUrl: './register.component.html',\n styleUrls: ['./register.component.scss'],\n})\n@AutoUnsubscribe()\nexport class RegisterComponent implements OnInit {\n readonlyStep!: boolean;\n currentStep: number | undefined;\n\n matDialogConfig!: MatDialogConfig;\n\n validationInProgress = false;\n\n StepStatusEnum = EnumStepStatus;\n\n stepType = StepType.INSCRIPTION;\n currentTitle = 'INSCR_THESIS';\n currentStudent!: StudentResponse;\n currentStudentStep: number | undefined;\n currentStudentStepStatus?: EnumStepStatus;\n currentThesis!: ThesisResponse;\n currentSemester!: SemesterResponse;\n currentSpecialisation!: SpecialisationResponse;\n depositLimitDate!: string;\n\n registrationForm: { values: RegistrationFormValues | undefined; isValid: boolean } = {\n values: undefined,\n isValid: false,\n };\n\n readonly registrationFormSubscriptions = new Subscription();\n\n constructor(\n private readonly matDialog: MatDialog,\n private readonly thesisService: ThesisService,\n private readonly notificationService: NotificationService,\n private readonly stepTypesService: StepTypesService,\n private readonly timelineStore: Store,\n private readonly studentStepsService: StudentStepsService\n ) {}\n\n ngOnInit(): void {\n this.registrationFormSubscriptions.add(\n this.studentStepsService.getStudentAndActiveStep().subscribe(({ studentConnected, activeStep, readonly }) => {\n this.readonlyStep = readonly;\n this.currentStep = activeStep;\n this.getStudent(studentConnected);\n })\n );\n\n this.matDialogConfig = this.getDialogConfig();\n }\n\n getStudent(student: StudentResponse): void {\n this.currentStudent = student;\n if (student) {\n this.currentStudentStep = this.currentStudent.currentStep;\n this.currentStudentStepStatus = this.currentStudent.currentStepStatus;\n this.depositLimitDate = this.currentStudent.depositLimitDate ?? '';\n\n if (this.currentStudent.specialisation) {\n this.currentSpecialisation = this.currentStudent.specialisation;\n }\n\n if (this.currentStudent.thesis?.semesters) {\n const currentSemester = this.currentStudent.thesis.semesters.find(s => s.isCurrent);\n if (currentSemester) {\n this.currentSemester = currentSemester;\n }\n }\n\n if (this.currentStudent.thesis) {\n this.currentThesis = this.currentStudent.thesis;\n }\n }\n }\n\n onRegistrationFormValuesChanges(event: { values: RegistrationFormValues; isValid: boolean }): void {\n this.registrationForm = event;\n }\n\n getStepTypesByProject(projectId: string) {\n this.stepTypesService\n .getAllStepTypesBySpecialisationIdAsync({\n specialisationId: this.currentSpecialisation.id,\n projectId,\n })\n .subscribe(steps => {\n this.timelineStore.dispatch(ThesisTimelineActions.updateThesisTimeline({ steps }));\n });\n }\n\n validForm(): void {\n const dialogRef = this.matDialog.open(DialogComponent, this.matDialogConfig);\n dialogRef.afterClosed().subscribe(result => {\n if (result) {\n this.termsAccepted();\n }\n });\n }\n\n saveForm() {\n this.createOrUpdateThesis().subscribe(result => {\n if (result) {\n this.notificationService.success('SAVE_SUCCESS');\n } else {\n this.notificationService.error('ERROR.SAVE');\n }\n });\n }\n\n createOrUpdateThesis(): Observable {\n const request = this.getThesisRequest();\n let requestResult$: Observable;\n if (this.currentThesis?.id) {\n requestResult$ = this.thesisService.updateThesisStep1Async({\n thesisId: this.currentThesis.id,\n body: request,\n });\n } else {\n requestResult$ = this.thesisService.createThesisAsync({ body: request }).pipe(\n map(result => {\n if (this.currentStudent && result.id) {\n this.currentThesis = { ...result };\n return result;\n }\n return null;\n })\n );\n }\n return requestResult$;\n }\n\n getThesisRequest(): CreateOrUpdateThesisRequest {\n const phoneNumber = this.registrationForm?.values?.professional?.phone?.trim();\n if (phoneNumber && this.registrationForm.values?.professional) {\n this.registrationForm.values.professional.phone = phoneNumber;\n }\n\n return {\n ...this.registrationForm.values,\n professional: {\n ...this.registrationForm.values?.professional,\n },\n supervisorId: this.registrationForm.values?.supervisor?.id,\n studentId: this.currentStudent.id,\n partnerId: this.registrationForm.values?.withPartner === true ? this.registrationForm.values?.studentPartner?.id : null,\n projectId: this.registrationForm?.values?.projectId ?? '',\n semesterId: this.currentSemester.id,\n stepStatus: this.currentStudentStepStatus,\n };\n }\n\n termsAccepted() {\n if (this.registrationForm.isValid) {\n this.currentStudentStepStatus = EnumStepStatus.ValidationInProgress;\n this.createOrUpdateThesis().subscribe(result => {\n this.validationInProgress = !!result;\n });\n }\n }\n\n getDialogConfig(): MatDialogConfig {\n const dialogConfig = new MatDialogConfig();\n dialogConfig.width = '500px';\n dialogConfig.disableClose = true;\n dialogConfig.enterAnimationDuration = '300ms';\n dialogConfig.exitAnimationDuration = '200ms';\n dialogConfig.data = {\n content: 'TERMS',\n alignContent: 'justify',\n cancelButton: { name: 'DECLINED', className: 'customButtons' },\n validButton: { name: 'AGREE', className: 'customButtons' },\n };\n return dialogConfig;\n }\n}\n","
\n \n \n
\n \n\n
\n
\n \n
\n \n\n \n \n \n
\n
\n\n \n
\n {{ 'COMMENTS' | translate }}\n\n \n \n \n \n \n\n \n \n \n\n \n \n\n \n \n \n \n
\n {{ comment.supervisor.lastName }} {{ comment.supervisor.firstName }}\n {{ comment.userRole | translate }}\n {{ comment.createdAt | date : 'dd/MM/yyyy' }}
{{ comment.reason }}
\n
\n
\n
\n
\n\n \n \n
\n

{{ depositTitle | translate }}

\n
\n\n
\n
\n \n \n
\n\n
\n \n \n
\n
\n
\n\n \n \n \n\n \n
\n
\n \n
\n
\n\n \n \n
\n","import { Component, Input, OnInit } from '@angular/core';\nimport { Store } from '@ngrx/store';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { Specialisation } from '@sharedEnums/specialisation.enum';\nimport { StepType } from '@sharedEnums/step-type.enum';\nimport { DocumentResponse } from '@sharedModels/document-response';\nimport { EnumStepStatus } from '@sharedModels/enum-step-status';\nimport { StudentResponse } from '@sharedModels/student-response';\nimport { DocumentsService } from '@sharedServices/documents.service';\nimport { StepsService } from '@sharedServices/steps.service';\nimport { combineLatest, Subscription, tap } from 'rxjs';\nimport { AutoUnsubscribe } from 'src/app/shared/decorators/autoUnsubscribe';\nimport * as studentReducer from 'src/store/student/student.reducer';\nimport { StudentState } from 'src/store/student/student.states';\nimport GlobalStorageService from '@coreServices/globalStorageService';\nimport { CommentResponse } from '@sharedModels/comment-response';\nimport { CommentsService } from '@sharedServices/comments.service';\nimport { CommentRequest } from '@sharedModels/comment-request';\nimport { sortListByDate } from '@sharedServices/tools.service';\nimport { ThesisTimelineState } from 'src/store/thesis-timeline/thesis-timeline.states';\nimport { getThesisTimeline } from 'src/store/thesis-timeline/thesis-timeline.reducer';\n\n@Component({\n selector: 'app-single-doc-upload',\n templateUrl: './single-doc-upload.component.html',\n styleUrls: ['./single-doc-upload.component.scss'],\n})\n@AutoUnsubscribe()\nexport class SingleDocUploadComponent implements OnInit {\n @Input() documentType!: DocumentType;\n @Input() stepType!: StepType;\n @Input() depositTitle!: string;\n\n currentStep: number | undefined;\n\n EnumStepStatus = EnumStepStatus;\n currentStudent!: StudentResponse;\n currentStepStatus!: EnumStepStatus | undefined;\n currentStudentStep: number | undefined;\n currentStudentProjectCode!: string;\n documentsByType!: DocumentResponse[];\n comments!: CommentResponse[];\n\n formJustSavedOrValidated = false;\n enableValidButton = false;\n uploading = false;\n stepSubmitted = false;\n displaySmallUploader = false;\n displayFooter = false;\n\n depositLimitDate!: string;\n\n readonly singleDocSubscription = new Subscription();\n\n constructor(\n private readonly globalStorageService: GlobalStorageService,\n private readonly studentStore: Store,\n private readonly stepsService: StepsService,\n private readonly documentsService: DocumentsService,\n private readonly commentService: CommentsService,\n private readonly thesisTimelineStore: Store\n ) {}\n\n ngOnInit(): void {\n this.singleDocSubscription.add(\n combineLatest([this.getCurrentStepFromTimeline(), this.getStudent()]).subscribe(() => {\n this.getComments();\n this.displaySmallUploader = this.checkDisplayingSmallUploader();\n })\n );\n }\n\n getCurrentStepFromTimeline() {\n return this.thesisTimelineStore.select(getThesisTimeline).pipe(\n tap(({ activeStep }) => {\n this.currentStep = activeStep;\n })\n );\n }\n\n getStudent() {\n return this.studentStore.select(studentReducer.getStudent).pipe(\n tap(result => {\n if (result) {\n this.currentStudent = result;\n this.currentStudentStep = this.currentStudent.currentStep;\n this.currentStepStatus = this.currentStudent.currentStepStatus;\n this.depositLimitDate = this.currentStudent.depositLimitDate ?? '';\n\n if (this.currentStudent.thesis?.documents) {\n this.documentsByType = this.currentStudent.thesis.documents.filter(doc => doc.documentTypeCode == this.documentType);\n this.checkValidationDocuments();\n }\n\n this.displayFooter = this.checkDisplayingFooter();\n }\n })\n );\n }\n\n getComments() {\n if (this.currentStudent.thesis && this.currentStep) {\n const commentRequest: CommentRequest = {\n thesisId: this.currentStudent.thesis.id,\n stepNumber: this.currentStep,\n commentType: null,\n };\n\n this.commentService.commentsPost({ body: commentRequest }).subscribe(result => {\n this.comments = result;\n if (this.comments?.length > 0) this.comments = sortListByDate(this.comments);\n });\n }\n }\n\n checkDisplayingFooter(): boolean {\n const stepStatus = this.currentStepStatus;\n\n return (\n this.currentStudent.specialisation.name === Specialisation.EDI && !!stepStatus && [EnumStepStatus.Refused, EnumStepStatus.InProgress].includes(stepStatus)\n );\n }\n\n // Display the small uploader when current student step is 'Refused'\n checkDisplayingSmallUploader(): boolean {\n return this.currentStep === this.currentStudentStep && this.currentStepStatus === EnumStepStatus.Refused;\n }\n\n checkValidationDocuments(): void {\n if (this.currentStudentStep === this.currentStep) {\n this.enableValidButton = this.documentsByType.some(doc => !doc.isArchived && !doc.isValidated && doc.documentTypeCode === this.documentType);\n }\n }\n\n incrementNameVersion(document: File, documentsLength: number): string {\n const index = document.name?.lastIndexOf('.');\n const extension = document.name?.slice(index);\n return `${document.name?.slice(0, index)}-v${documentsLength + 1}${extension}`;\n }\n\n uploadDocuments(uploadedDocuments: File[]): void {\n this.uploading = true;\n const thesisId = this.currentStudent.thesis?.id;\n const projectCode = this.currentStudent.thesis?.project?.code;\n if (thesisId && projectCode) {\n uploadedDocuments.forEach(document => {\n const name = this.incrementNameVersion(document, this.documentsByType.length);\n const request = {\n FileToUpload: new File([document], name, { type: document.type }),\n ThesisId: thesisId,\n DocumentTypeCode: this.documentType,\n SpecialisationName: this.currentStudent.specialisation.name,\n ProjectCode: projectCode,\n };\n\n this.documentsService\n .createDocumentAsync({ body: request })\n .pipe(\n tap((result: DocumentResponse) => {\n if (result.id) {\n this.documentsByType = [result, ...this.documentsByType];\n if (this.documentsByType?.length > 0) this.documentsByType = sortListByDate(this.documentsByType);\n this.uploading = false;\n this.checkValidationDocuments();\n }\n })\n )\n .subscribe();\n });\n }\n }\n\n deleteDocument(documentId: string): void {\n this.uploading = true;\n this.documentsService\n .deleteDocumentAsync({ documentId })\n .pipe(\n tap(result => {\n if (result) {\n this.documentsByType = [...this.documentsByType.filter(doc => doc.id != documentId)];\n this.uploading = false;\n this.enableValidButton = false;\n }\n })\n )\n .subscribe();\n }\n\n validStep(): void {\n const hasBookDocument = this.documentsByType.findIndex(doc => doc.documentTypeCode === this.documentType) !== -1;\n if (!hasBookDocument || !this.currentStudent.currentStepId) return;\n this.formJustSavedOrValidated = true;\n\n this.stepsService\n .updateStepAsync({\n stepId: this.currentStudent.currentStepId,\n body: {\n stepStatus: EnumStepStatus.ValidationInProgress,\n },\n })\n .subscribe({\n next: result => {\n this.stepSubmitted = !!result;\n this.globalStorageService.updateStudentCurrentStepAndDispatchToStore(this.currentStudent, result);\n },\n complete: () => (this.formJustSavedOrValidated = false),\n });\n }\n\n downloadFile(document: DocumentResponse): void {\n window.open(document.downloadUrl, '_blank');\n }\n}\n","import { Component } from '@angular/core';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { StepType } from '@sharedEnums/step-type.enum';\n\n@Component({\n template: '',\n})\nexport class LiteratureComponent {\n documentType = DocumentType.BOOK;\n stepType = StepType.BOOK;\n depositTitle = 'BOOK_DEPOSIT';\n}\n","import { Component } from '@angular/core';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { StepType } from '@sharedEnums/step-type.enum';\n\n@Component({\n template: '',\n})\nexport class PlanDraftComponent {\n documentType = DocumentType.DRAFT;\n stepType = StepType.DRAFT;\n depositTitle = 'DRAFT_DEPOSIT';\n}\n","import { Component } from '@angular/core';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { StepType } from '@sharedEnums/step-type.enum';\n\n@Component({\n template: '',\n})\nexport class PlanComponent {\n documentType = DocumentType.PLAN;\n stepType = StepType.PLAN;\n depositTitle = 'PLAN_DEPOSIT';\n}\n","import { Component } from '@angular/core';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { StepType } from '@sharedEnums/step-type.enum';\n\n@Component({\n template: '',\n})\nexport class PitchComponent {\n documentType = DocumentType.PITCH;\n stepType = StepType.PITCH;\n depositTitle = 'PITCH_DEPOSIT';\n}\n","import { Component } from '@angular/core';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { StepType } from '@sharedEnums/step-type.enum';\n\n@Component({\n template: '',\n})\nexport class FinalDraft2Component {\n documentType = DocumentType.FINALDRAFT2;\n stepType = StepType.FINAL_DRAFTS;\n depositTitle = 'FINALDRAFT2_DEPOSIT';\n}\n","import { Component } from '@angular/core';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { StepType } from '@sharedEnums/step-type.enum';\n\n@Component({\n template: '',\n})\nexport class FinalDraft1Component {\n documentType = DocumentType.FINALDRAFT1;\n stepType = StepType.FINAL_DRAFTS;\n depositTitle = 'FINALDRAFT1_DEPOSIT';\n}\n","\n
\n
\n \n\n
\n
\n
\n
{{ pageTitle | translate }}
\n
{{ 'FIELDS_MANDATORY' | translate }}
\n
\n\n \n
\n\n \n
\n \n \n \n
\n\n \n \n \n\n \n \n\n \n \n \n\n \n \n \n\n \n\n \n \n \n
Document
{{ document.createdAt | date : 'dd/MM/yyyy' }}\n \"file\n {{ document.name }}\n \n \n \n \n \n \n\n \n \n \n \n \n
\n\n
0\" class=\"comments\">\n \n \n \n \n \n \n \n\n \n \n \n\n \n \n \n \n \n\n \n \n \n \n
\n {{ comment.supervisor.lastName }} {{ comment.supervisor.firstName }}\n {{ comment.userRole | translate }}\n {{ comment.createdAt | date : 'dd/MM/yyyy' }}
\n \n
{{ comment.reason }}
\n
\n
\n
\n
\n\n \n
\n
\n \n \n\n \n \n
\n
\n\n\n\n","import { Component, Input } from '@angular/core';\nimport * as studentReducer from 'src/store/student/student.reducer';\nimport { combineLatest, EMPTY, map, Observable, Subscription, switchMap, take, tap } from 'rxjs';\nimport { Store } from '@ngrx/store';\nimport { AutoUnsubscribe } from 'src/app/shared/decorators/autoUnsubscribe';\nimport { StepType } from '@sharedEnums/step-type.enum';\nimport { ThesisService } from '@sharedServices/thesis.service';\nimport { EnumStepStatus } from '@sharedModels/enum-step-status';\nimport { StudentResponse } from '@sharedModels/student-response';\nimport { DocumentType } from '@sharedEnums/documentType.enum';\nimport { DocumentResponse } from '@sharedModels/document-response';\nimport { DocumentsService } from '@sharedServices/documents.service';\nimport { StepsService } from '@sharedServices/steps.service';\nimport { ThesisResponse } from '@sharedModels/thesis-response';\nimport { NotificationService } from 'src/app/shared/services/notification.service';\nimport { UpdateThesisStep4Request } from '@sharedModels/update-thesis-step-4-request';\nimport { Specialisation } from '@sharedEnums/specialisation.enum';\nimport GlobalStorageService from '@coreServices/globalStorageService';\nimport { Project } from '@sharedEnums/project.enum';\nimport { SpecialisationResponse } from '@sharedModels/specialisation-response';\nimport { CommentsService } from '@sharedServices/comments.service';\nimport { CommentResponse } from '@sharedModels/comment-response';\nimport { ThesisSupervisorResponse } from '@sharedModels/thesis-supervisor-response';\nimport { StudentState } from 'src/store/student/student.states';\nimport { CommentRequest } from '@sharedModels/comment-request';\nimport { sortListByDate } from '@sharedServices/tools.service';\nimport { ThesisTimelineState } from 'src/store/thesis-timeline/thesis-timeline.states';\nimport { getThesisTimeline } from 'src/store/thesis-timeline/thesis-timeline.reducer';\nimport { FinalDocFormValues } from 'src/app/shared/modules/thesis-steps/components/final-doc-form/final-doc-form.component';\n\n@Component({\n selector: 'app-final-doc',\n templateUrl: './final-doc.component.html',\n styleUrls: ['./final-doc.component.scss'],\n})\n@AutoUnsubscribe()\nexport class FinalDocComponent {\n @Input() readonlyStep!: boolean;\n\n pageTitle = 'FINAL_DEPOSIT';\n\n finalDocForm: {\n values: FinalDocFormValues | null;\n isValid: boolean;\n } = {\n values: null,\n isValid: false,\n };\n\n disableForm = false;\n currentStep: number | undefined;\n currentStudent!: StudentResponse;\n currentStudentStep = 0;\n currentThesis?: ThesisSupervisorResponse | undefined;\n finalDocuments!: DocumentResponse[];\n comments!: CommentResponse[];\n EnumStepStatus = EnumStepStatus;\n\n formJustSavedOrValidated = false;\n uploading = false;\n enableValidButton = false;\n displayValidButton = false;\n displayValidationMessage = false;\n displayTable = false;\n displayUploader = false;\n newDocumentsExist = false;\n currentStepStatus?: EnumStepStatus;\n currentDocuments!: DocumentResponse[];\n stepType!: StepType;\n depositLimitDate!: string;\n\n readonly finalDocFormSubscriptions = new Subscription();\n\n constructor(\n private readonly notificationService: NotificationService,\n private readonly thesisService: ThesisService,\n private readonly documentsService: DocumentsService,\n private readonly stepsService: StepsService,\n private readonly studentStore: Store,\n private readonly globalStorageService: GlobalStorageService,\n private readonly commentService: CommentsService,\n private readonly timelineStore: Store\n ) {}\n\n ngOnInit(): void {\n this.finalDocFormSubscriptions.add(\n combineLatest([\n this.getStudent().pipe(\n tap(() => {\n this.checkStep();\n this.displayUploader = this.checkDisplayingUploader();\n })\n ),\n this.getTimeline(),\n ])\n .pipe(switchMap(() => this.getComments()))\n .subscribe()\n );\n }\n\n /** Retrieves the timeline from the timeline store and sets the current step. */\n getTimeline() {\n return this.timelineStore.select(getThesisTimeline).pipe(\n tap(result => {\n this.currentStep = result.activeStep;\n })\n );\n }\n\n checkStep() {\n const specialisation = this.currentStudent?.specialisation;\n const projectCode = this.currentStudent?.thesis?.project?.code;\n const shouldDisableForm =\n (this.currentStudentStep !== 4 && specialisation?.name === Specialisation.CLASSIQUE && projectCode !== Project.IBL) ||\n (this.currentStudentStep !== 5 && specialisation?.name === Specialisation.CLASSIQUE && projectCode === Project.IBL) ||\n (this.currentStudentStep !== 4 && specialisation?.name === Specialisation.ALTERNANCE) ||\n (this.currentStudentStep == 5 &&\n (this.currentStepStatus == EnumStepStatus.ValidationInProgress || this.currentStepStatus == EnumStepStatus.Waiting) &&\n specialisation?.name === Specialisation.EDI) ||\n (this.currentStudentStep > 5 && specialisation?.name === Specialisation.EDI);\n\n this.displayTable = this.currentStepStatus == EnumStepStatus.Refused;\n\n if (shouldDisableForm) {\n this.disableForm = true;\n this.displayTable = this.finalDocuments.length > 0;\n }\n\n this.displayingValidationMessage();\n }\n\n displayingValidationMessage() {\n const specialisation = this.currentStudent?.specialisation;\n const projectCode = this.currentStudent?.thesis?.project?.code;\n\n if (\n (this.currentStudentStep === 4 && specialisation?.name === Specialisation.CLASSIQUE && projectCode !== Project.IBL) ||\n (this.currentStudentStep === 5 && specialisation?.name === Specialisation.CLASSIQUE && projectCode === Project.IBL) ||\n (this.currentStudentStep === 4 && specialisation?.name === Specialisation.ALTERNANCE) ||\n (this.currentStudentStep === 5 && specialisation?.name === Specialisation.EDI)\n ) {\n if (this.currentStepStatus === EnumStepStatus.ValidationInProgress || this.currentStepStatus === EnumStepStatus.Waiting) {\n this.displayValidationMessage = true;\n return;\n }\n }\n\n this.displayValidationMessage = false;\n }\n\n /** Retrieves the student from the student store and updates the current student and some values from it. */\n getStudent(): Observable {\n return this.studentStore.select(studentReducer.getStudent).pipe(\n take(1),\n tap(result => {\n this.currentStudent = result;\n\n if (this.currentStudent) {\n this.depositLimitDate = this.currentStudent.depositLimitDate ?? '';\n\n this.currentThesis = this.currentStudent.thesis;\n this.currentStepStatus = this.currentStudent.currentStepStatus;\n this.currentStudentStep = this.currentStudent.currentStep ?? 0;\n this.stepType = this.getFinalStepTypeBySpecialisation(this.currentStudent.specialisation);\n\n if (this.currentStudent.thesis?.documents) {\n this.currentDocuments = this.currentStudent.thesis.documents;\n this.getFinalDocuments(this.currentDocuments);\n }\n\n this.displayValidButton = this.currentStepStatus == EnumStepStatus.InProgress || this.currentStepStatus == EnumStepStatus.Refused;\n this.enableValidButton = this.finalDocuments.some(doc => !doc.isArchived && !doc.isValidated);\n this.checkNewDocuments();\n }\n })\n );\n }\n\n getFinalDocuments(documents: DocumentResponse[]): void {\n this.finalDocuments = documents.filter(doc => doc.documentTypeCode == DocumentType.FINAL);\n if (this.finalDocuments && this.finalDocuments.length > 0) this.finalDocuments = sortListByDate(this.finalDocuments);\n }\n\n /** Retrieves the comments for the current student's thesis and step. */\n getComments(): Observable {\n if (!this.currentStudent?.thesis || !this.currentStep) return EMPTY;\n\n const commentRequest: CommentRequest = {\n thesisId: this.currentStudent.thesis.id,\n stepNumber: this.currentStep,\n };\n\n return this.commentService.commentsPost({ body: commentRequest }).pipe(\n tap(result => {\n this.comments = result;\n if (this.comments && this.comments.length > 0) this.comments = sortListByDate(this.comments);\n })\n );\n }\n\n getFinalStepTypeBySpecialisation(specialisation: SpecialisationResponse) {\n switch (specialisation.name) {\n case Specialisation.ALTERNANCE:\n return StepType.FINAL_ALTERNANCE;\n case Specialisation.EDI:\n return StepType.FINAL_EDI;\n default:\n return StepType.FINAL;\n }\n }\n\n checkDisplayingUploader(): boolean {\n return this.currentStudent?.specialisation.name === Specialisation.CLASSIQUE && (this.currentStudentStep === 4 || this.currentStudentStep === 5);\n }\n\n downloadFile(document: DocumentResponse): void {\n window.open(document.downloadUrl, '_blank');\n }\n\n uploadDocument(uploadedDocuments: File[]) {\n this.uploading = true;\n const thesisId = this.currentStudent?.thesis?.id;\n const projectCode = this.currentThesis?.project?.code;\n if (thesisId && projectCode) {\n uploadedDocuments.forEach(document => {\n const name = this.incrementNameVersion(document, this.finalDocuments.length);\n const request = {\n FileToUpload: new File([document], name, { type: document.type }),\n ThesisId: thesisId,\n DocumentTypeCode: DocumentType.FINAL,\n SpecialisationName: this.currentStudent.specialisation.name,\n ProjectCode: projectCode,\n };\n\n this.documentsService\n .createDocumentAsync({ body: request })\n .pipe(\n map((result: DocumentResponse) => {\n if (result.id) {\n this.finalDocuments = [...this.finalDocuments, result];\n this.enableValidButton = this.finalDocuments.some(doc => !doc.isArchived);\n this.currentDocuments = [...this.currentDocuments, ...this.finalDocuments.filter(doc => !doc.isArchived)];\n this.checkNewDocuments();\n this.globalStorageService.updateThesisDocumentsAndDispatchToStore(this.currentStudent, this.currentDocuments);\n }\n }),\n tap(() => (this.uploading = false))\n )\n .subscribe();\n });\n }\n }\n\n deleteDocument(id: string) {\n this.uploading = true;\n this.documentsService\n .deleteDocumentAsync({ documentId: id })\n .pipe(\n map(result => {\n if (result) {\n const updatedDocuments = this.currentDocuments.filter(doc => doc.id != id);\n this.finalDocuments = updatedDocuments.filter(doc => doc.documentTypeCode === DocumentType.FINAL);\n this.enableValidButton = false;\n this.checkNewDocuments();\n this.globalStorageService.updateThesisDocumentsAndDispatchToStore(this.currentStudent, updatedDocuments);\n }\n }),\n tap(() => (this.uploading = false))\n )\n .subscribe();\n }\n\n checkNewDocuments(): void {\n this.newDocumentsExist = this.finalDocuments.some(doc => !doc.isArchived && !doc.isValidated);\n }\n\n incrementNameVersion(document: File, documentsLength: number): string {\n const index = document.name?.lastIndexOf('.');\n const extension = document.name?.slice(index);\n return `${document.name?.slice(0, index)}-v${documentsLength + 1}${extension}`;\n }\n\n validForm() {\n if (\n this.finalDocForm.isValid &&\n this.finalDocuments.filter(doc => !doc.isArchived && !doc.isValidated).length == 1 &&\n this.currentThesis?.id &&\n this.currentStudent?.currentStepId\n ) {\n this.formJustSavedOrValidated = true;\n this.createOrUpdateThesis(this.currentThesis.id).subscribe(result => {\n if (result && this.currentStudent?.currentStepId) {\n this.stepsService\n .updateStepAsync({\n stepId: this.currentStudent.currentStepId,\n body: {\n stepStatus: EnumStepStatus.ValidationInProgress,\n },\n })\n .subscribe({\n next: result => {\n this.currentStepStatus = result.status;\n this.globalStorageService.updateStudentCurrentStepAndDispatchToStore(this.currentStudent, result);\n },\n complete: () => {\n this.formJustSavedOrValidated = false;\n this.displayValidationMessage = true;\n },\n });\n }\n });\n }\n }\n\n saveForm() {\n if (this.currentThesis?.id) {\n this.formJustSavedOrValidated = true;\n this.createOrUpdateThesis(this.currentThesis?.id).subscribe({\n next: result => {\n this.globalStorageService.updateThesisAndDispatchToStore(this.currentStudent, result);\n },\n complete: () => {\n this.formJustSavedOrValidated = false;\n this.notificationService.success('SAVE_SUCCESS');\n },\n });\n }\n }\n\n createOrUpdateThesis(thesisId: string): Observable {\n const thesisInformationRequest: UpdateThesisStep4Request = {\n ...this.finalDocForm.values,\n coSupervisorId: this.currentThesis?.coSupervisor?.id,\n };\n return this.thesisService.updateThesisStep4Async({\n thesisId: thesisId,\n body: { ...thesisInformationRequest, ...this.finalDocForm.values },\n });\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouterModule, Routes } from '@angular/router';\nimport { IntermediateDocsFormComponent } from './components/intermediate-docs-form/intermediate-docs-form.component';\nimport { EvaluationFormComponent } from './components/common/evaluation-form/evaluation-form.component';\nimport { OralOrganizationComponent } from './components/oral-organization/oral-organization.component';\nimport { FramingSubjectComponent } from './components/edi/framing-subject/framing-subject.component';\nimport { ThesisStepRoute } from '@sharedEnums/thesis-step-route.enum';\nimport { OralResultComponent } from './components/oral-result/oral-result.component';\nimport { StudentStepGuard } from 'src/app/core/guards/student-steps.guard';\nimport { StudentStepsComponent } from './student-steps/student-steps.component';\nimport { RegisterComponent } from './student-steps/steps/register/register.component';\nimport { LiteratureComponent } from './student-steps/steps/literature/literature.component';\nimport { PlanDraftComponent } from './student-steps/steps/plan-draft/plan-draft.component';\nimport { PlanComponent } from './student-steps/steps/plan/plan.component';\nimport { PitchComponent } from './student-steps/steps/pitch/pitch.component';\nimport { FinalDraft2Component } from './student-steps/steps/final-draft2/final-draft2.component';\nimport { FinalDraft1Component } from './student-steps/steps/final-draft1/final-draft1.component';\nimport { FinalDocComponent } from './student-steps/steps/final-doc/final-doc.component';\n\nconst routes: Routes = [\n {\n path: '',\n component: StudentStepsComponent,\n canActivateChild: [StudentStepGuard],\n children: [\n {\n path: ThesisStepRoute.EVALUATIONSTEP,\n component: EvaluationFormComponent,\n },\n {\n path: ThesisStepRoute.FINALDOCSTEP,\n component: FinalDocComponent,\n },\n {\n path: ThesisStepRoute.INTERMEDIATESTEP,\n component: IntermediateDocsFormComponent,\n },\n {\n path: ThesisStepRoute.ORGAEXAMINATIONSTEP,\n component: OralOrganizationComponent,\n },\n {\n path: ThesisStepRoute.REGISTERSTEP,\n component: RegisterComponent,\n },\n {\n path: ThesisStepRoute.RESEXAMINATIONSTEP,\n component: OralResultComponent,\n },\n {\n path: ThesisStepRoute.FINALDOCDRAFT1,\n component: FinalDraft1Component,\n },\n {\n path: ThesisStepRoute.FINALDOCDRAFT2,\n component: FinalDraft2Component,\n },\n {\n path: ThesisStepRoute.LITERATURESTEP,\n component: LiteratureComponent,\n },\n {\n path: ThesisStepRoute.PITCHSTEP,\n component: PitchComponent,\n },\n {\n path: ThesisStepRoute.PLANDRAFTSTEP,\n component: PlanDraftComponent,\n },\n {\n path: ThesisStepRoute.PLANSTEP,\n component: PlanComponent,\n },\n {\n path: ThesisStepRoute.SUBJECTSTEP,\n component: FramingSubjectComponent,\n },\n {\n path: '**',\n redirectTo: ThesisStepRoute.REGISTERSTEP,\n },\n ],\n },\n];\n\n@NgModule({\n imports: [RouterModule.forChild(routes)],\n exports: [RouterModule],\n})\nexport class StudentRoutingModule {}\n","import { NgModule } from '@angular/core';\nimport { SharedModule } from 'src/app/shared/shared.module';\nimport { StudentRoutingModule } from './student-routing.module';\nimport { IntermediateDocsFormComponent } from './components/intermediate-docs-form/intermediate-docs-form.component';\nimport { OralOrganizationComponent } from './components/oral-organization/oral-organization.component';\nimport { EvaluationFormComponent } from './components/common/evaluation-form/evaluation-form.component';\nimport { TranslateModule } from '@ngx-translate/core';\nimport { OralResultComponent } from './components/oral-result/oral-result.component';\nimport { FramingSubjectComponent } from './components/edi/framing-subject/framing-subject.component';\nimport { CommonStepsModule } from '@views/common/common-steps.module';\nimport { ConventionAgreementButtonComponent } from './components/common/convention-agreement-button/convention-agreement-button.component';\nimport { ConventionAgreementFormComponent } from './components/common/convention-agreement-form/convention-agreement-form.component';\nimport { StudentStepsComponent } from './student-steps/student-steps.component';\nimport { RegisterComponent } from './student-steps/steps/register/register.component';\nimport { ThesisStepsModule } from 'src/app/shared/modules/thesis-steps/thesis-steps.module';\nimport { PitchComponent } from './student-steps/steps/pitch/pitch.component';\nimport { LiteratureComponent } from './student-steps/steps/literature/literature.component';\nimport { PlanDraftComponent } from './student-steps/steps/plan-draft/plan-draft.component';\nimport { SingleDocUploadComponent } from './student-steps/components/single-doc-upload/single-doc-upload.component';\nimport { PlanComponent } from './student-steps/steps/plan/plan.component';\nimport { FinalDraft1Component } from './student-steps/steps/final-draft1/final-draft1.component';\nimport { FinalDraft2Component } from './student-steps/steps/final-draft2/final-draft2.component';\nimport { FinalDocComponent } from './student-steps/steps/final-doc/final-doc.component';\n\n@NgModule({\n declarations: [\n StudentStepsComponent,\n IntermediateDocsFormComponent,\n EvaluationFormComponent,\n OralOrganizationComponent,\n OralResultComponent,\n FramingSubjectComponent,\n ConventionAgreementButtonComponent,\n ConventionAgreementFormComponent,\n SingleDocUploadComponent,\n FinalDraft1Component,\n FinalDraft2Component,\n LiteratureComponent,\n PitchComponent,\n PlanComponent,\n PlanDraftComponent,\n RegisterComponent,\n FinalDocComponent,\n ],\n imports: [StudentRoutingModule, CommonStepsModule, SharedModule, TranslateModule.forChild(), ThesisStepsModule],\n})\nexport class StudentModule {}\n"],"x_google_ignoreList":[]}