#NEWLINE# def job_deactivate( request , job_id , auth ) : #NEWLINE# #INDENT# ' Deactivates a job and shows an active jobs list.    \n    ' #NEWLINE# job = get_object_or_404 ( Job , pk = job_id , auth = auth ) #NEWLINE# extra_context = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# if ( job . is_active ( ) or job . is_temporary ( ) ) : #NEWLINE# #INDENT# job . deactivate ( ) #NEWLINE# messages . add_message ( request , messages . INFO , _ ( 'Your job has been deactivated.' ) ) #NEWLINE# extra_context [ 'page_type' ] = 'deactivate' #NEWLINE# #UNINDENT# queryset = Job . active . all ( ) #NEWLINE# return object_list ( request , queryset = queryset , extra_context = extra_context , paginate_by = djobberbase_settings . DJOBBERBASE_JOBS_PER_PAGE )