def disable_participant(self, user, user_to_disable, note):
        """
        Mark the user_to_disable as disabled. Must include a note explaining
        reasons for this action. Also the 'user' arg is used for logging who
        carried this out
        """
        if not note:
            raise UnableToDisableParticipant, __('Must supply a reason for'\
                    ' disabling a participant. None given.')
        try:
            p_as_user = Participant.objects.get(workflowactivity=self, 
                            user=user, disabled=False)
            p_to_disable = Participant.objects.get(workflowactivity=self, 
                    user=user_to_disable)
            if not p_to_disable.disabled:
                p_to_disable.disabled = True
                p_to_disable.save()
                name = user_to_disable.get_full_name() if user_to_disable.get_full_name() else user_to_disable.username
                note = _('Participant %s disabled with the reason: %s')%(name, note)
                current_state = self.current_state().state if self.current_state() else None
                deadline = self.current_state().deadline if self.current_state() else None
                wh = WorkflowHistory(
                            workflowactivity=self,
                            state=current_state,
                            log_type=WorkflowHistory.ROLE,
                            participant=p_as_user,
                            note=note,
                            deadline=deadline
                            )
                wh.save()
                return wh
            else:
                # They're already disabled
                return None
        except __HOLE__:
            # If we can't find the assignee then there is nothing to do
            return None
dataset/ETHPy150Open ntoll/workflow/workflow/models.py/WorkflowActivity.disable_participant