mirror of
				https://github.com/inventree/InvenTree.git
				synced 2025-10-31 05:05:42 +00:00 
			
		
		
		
	* Allow part category table to be ordered by part count * Add queryset annotation for part-category part-count - Uses subquery to annotate the part-count for sub-categories - Huge reduction in number of queries * Update 'pathstring' property of PartCategory and StockLocation - No longer a dynamically calculated value - Constructed when the model is saved, and then written to the database - Limited to 250 characters * Data migration to re-construct pathstring for PartCategory objects * Fix for tree model save() method * Add unit tests for pathstring construction * Data migration for StockLocation pathstring values * Update part API - Add new annotation to PartLocationDetail view * Update API version * Apply similar annotation to StockLocation API endpoints * Extra tests for PartCategory API * Unit test fixes * Allow PartCategory and StockLocation lists to be sorted by 'pathstring' * Further unit test fixes
		
			
				
	
	
		
			19 lines
		
	
	
		
			452 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			19 lines
		
	
	
		
			452 B
		
	
	
	
		
			Python
		
	
	
	
	
	
| # Generated by Django 3.2.14 on 2022-07-31 23:54
 | |
| 
 | |
| from django.db import migrations, models
 | |
| 
 | |
| 
 | |
| class Migration(migrations.Migration):
 | |
| 
 | |
|     dependencies = [
 | |
|         ('stock', '0079_alter_stocklocation_name'),
 | |
|     ]
 | |
| 
 | |
|     operations = [
 | |
|         migrations.AddField(
 | |
|             model_name='stocklocation',
 | |
|             name='pathstring',
 | |
|             field=models.CharField(blank=True, help_text='Path', max_length=250, verbose_name='Path'),
 | |
|         ),
 | |
|     ]
 |