mirror of https://github.com/jumpserver/jumpserver
				
				
				
			perf: 作业日志添加任务类型
							parent
							
								
									f660c38d80
								
							
						
					
					
						commit
						d7f8ba58ad
					
				| 
						 | 
				
			
			@ -23,7 +23,7 @@ class JobLogSerializer(JobExecutionSerializer):
 | 
			
		|||
    class Meta:
 | 
			
		||||
        model = models.JobLog
 | 
			
		||||
        read_only_fields = [
 | 
			
		||||
            "id", "material", "time_cost", 'date_start',
 | 
			
		||||
            "id", "material", 'job_type', "time_cost", 'date_start',
 | 
			
		||||
            'date_finished', 'date_created',
 | 
			
		||||
            'is_finished', 'is_success',
 | 
			
		||||
            'task_id', 'creator_name'
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -43,6 +43,7 @@ def clean_password_change_log_period():
 | 
			
		|||
    days = get_log_keep_day('PASSWORD_CHANGE_LOG_KEEP_DAYS')
 | 
			
		||||
    expired_day = now - datetime.timedelta(days=days)
 | 
			
		||||
    PasswordChangeLog.objects.filter(datetime__lt=expired_day).delete()
 | 
			
		||||
    logger.info("Clean password change log done")
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def clean_activity_log_period():
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue