mirror of
				https://github.com/django/django.git
				synced 2025-10-27 07:36:08 +00:00 
			
		
		
		
	Python 2.6 has some different behaviour when checking isinstance(foo, collections.Iterator).
		
			
				
	
	
		
			14 lines
		
	
	
		
			262 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			14 lines
		
	
	
		
			262 B
		
	
	
	
		
			Python
		
	
	
	
	
	
| from django.db import models
 | |
| 
 | |
| 
 | |
| class Category(models.Model):
 | |
|     name = models.CharField(max_length=100)
 | |
| 
 | |
|     def next(self):
 | |
|         return self
 | |
| 
 | |
| 
 | |
| class Thing(models.Model):
 | |
|     name = models.CharField(max_length=100)
 | |
|     category = models.ForeignKey(Category)
 |