Пример #1
0
 def manager_accept(self):
     if self.status == 'DIR_SUBMIT':
         self.teacher_accept()
     elif self.status == 'COM_SUBMIT' or self.status == 'COM_KO':
         next_status = get_next_status(self, "accept")
         emails_dissert.send_email(self, 'dissertation_accepted_by_com', self.author)
         self.set_status(next_status)
     elif self.status == 'EVA_SUBMIT' or self.status == 'EVA_KO' or self.status == 'DEFENDED':
         next_status = get_next_status(self, "accept")
         self.set_status(next_status)
Пример #2
0
 def refuse(self):
     next_status = get_next_status(self, "refuse")
     if self.status == 'DIR_SUBMIT':
         emails_dissert.send_email(self, 'dissertation_refused_by_teacher',
                                   [self.author])
     if self.status == 'COM_SUBMIT':
         emails_dissert.send_email(
             self, 'dissertation_refused_by_com_to_student', [self.author])
         emails_dissert.send_email_to_all_promotors(
             self, 'dissertation_refused_by_com_to_teacher')
     self.set_status(next_status)
Пример #3
0
    def go_forward(self):
        next_status = get_next_status(self, "go_forward")
        if self.status == 'TO_RECEIVE' and next_status == 'TO_DEFEND':
            emails_dissert.send_email(self, 'dissertation_acknowledgement',
                                      [self.author])
        if (self.status == 'DRAFT'
                or self.status == 'DIR_KO') and next_status == 'DIR_SUBMIT':
            emails_dissert.send_email_to_all_promotors(
                self, 'dissertation_adviser_new_project_dissertation')

        self.set_status(next_status)
Пример #4
0
 def manager_accept(self):
     if self.status == 'DIR_SUBMIT':
         self.teacher_accept()
     elif self.status == 'COM_SUBMIT' or self.status == 'COM_KO':
         next_status = get_next_status(self, "accept")
         emails_dissert.send_email(self, 'dissertation_accepted_by_com',
                                   [self.author])
         if offer_proposition.get_by_offer(
                 self.offer_year_start.offer
         ).global_email_to_commission is True:
             emails_dissert.send_email_to_jury_members(self)
         self.set_status(next_status)
     elif self.status == 'EVA_SUBMIT' or self.status == 'EVA_KO' or self.status == 'DEFENDED':
         next_status = get_next_status(self, "accept")
         self.set_status(next_status)
Пример #5
0
 def manager_accept(self):
     if self.status == dissertation_status.DIR_SUBMIT:
         self.teacher_accept()
     elif self.status == dissertation_status.ENDED_LOS:
         self.set_status(dissertation_status.TO_RECEIVE)
     elif self.status == dissertation_status.COM_SUBMIT or self.status == dissertation_status.COM_KO:
         next_status = get_next_status(self, "accept")
         emails_dissert.send_email(self, 'dissertation_accepted_by_com',
                                   [self.author])
         if get_object_or_none(OfferProposition, education_group=self.education_group_year.education_group) \
                 .global_email_to_commission:
             emails_dissert.send_email_to_jury_members(self)
         self.set_status(next_status)
     elif self.status == dissertation_status.EVA_SUBMIT or \
             self.status == dissertation_status.EVA_KO or self.status == dissertation_status.DEFENDED:
         next_status = get_next_status(self, "accept")
         self.set_status(next_status)
Пример #6
0
 def refuse(self):
     next_status = get_next_status(self, "refuse")
     if self.status == 'DIR_SUBMIT':
         emails_dissert.send_email(self, 'dissertation_refused_by_teacher', self.author)
     if self.status == 'COM_SUBMIT':
         emails_dissert.send_email(self, 'dissertation_refused_by_com_to_student', self.author)
         emails_dissert.send_email(self,
                                   'dissertation_refused_by_com_to_teacher',
                                   get_promoteur_by_dissertation(self))
     self.set_status(next_status)
Пример #7
0
 def teacher_accept(self):
     if self.status == 'DIR_SUBMIT':
         next_status = get_next_status(self, "accept")
         emails_dissert.send_email(self, 'dissertation_accepted_by_teacher',
                                   [self.author])
         self.set_status(next_status)