Browse Source
			
			
			Update deduplica_comissao.py
			
				Co-Authored-By: João Rodrigues <cont.joaorodrigues@gmail.com>
			
			
				script-comissao
			
			
		 
		
			
				
					
						 Edward
					
					7 years ago
						Edward
					
					7 years ago
					
						
							committed by
							
								 GitHub
								GitHub
							
						 
					
				 
				
			 
		 
		
			
				
					
					No known key found for this signature in database
					
						
							GPG Key ID: 4AEE18F83AFDEB23
						
					
				
			
		
		
		
	
		
			
				 1 changed files with 
1 additions and 
1 deletions
			 
			
		 
		
			
				- 
					
					
					 
					deduplica_comissao.py
				
				
				
					
						
							
								
									
	
		
		
			
				
					|  | @ -166,7 +166,7 @@ def deduplicate_comissao(): | 
			
		
	
		
		
			
				
					|  |  |         ## TODO: PODEM EXISTIR CASOS DA COMISSAO DE DESTINO NAO TER AUTOR, TERIA QUE CRIAR |  |  |         ## TODO: PODEM EXISTIR CASOS DA COMISSAO DE DESTINO NAO TER AUTOR, TERIA QUE CRIAR | 
			
		
	
		
		
			
				
					|  |  |         ## TODO: POR ENQUANTO OPTEI POR PEGAR A ULTIMA COMISSAO COM AUTOR CRIADO |  |  |         ## TODO: POR ENQUANTO OPTEI POR PEGAR A ULTIMA COMISSAO COM AUTOR CRIADO | 
			
		
	
		
		
			
				
					|  |  |         while True: |  |  |         while True: | 
			
		
	
		
		
			
				
					
					|  |  |             c = comissoes.pop() |  |  |             c = comissoes.pop(0) | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |             try: |  |  |             try: | 
			
		
	
		
		
			
				
					|  |  |                 Autor.objects.get(content_type=content_type, tipo=tipo, object_id=c) |  |  |                 Autor.objects.get(content_type=content_type, tipo=tipo, object_id=c) | 
			
		
	
		
		
			
				
					|  |  |                 comissoes = [c] + comissoes |  |  |                 comissoes = [c] + comissoes | 
			
		
	
	
		
		
			
				
					|  | 
 |