mirror of
				https://github.com/inventree/InvenTree.git
				synced 2025-11-03 22:55:43 +00:00 
			
		
		
		
	Don't add "remove row" button if there is only one row
This commit is contained in:
		@@ -655,12 +655,14 @@ function receivePurchaseOrderItems(order_id, line_items, options={}) {
 | 
			
		||||
            );
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        buttons += makeIconButton(
 | 
			
		||||
            'fa-times icon-red',
 | 
			
		||||
            'button-row-remove',
 | 
			
		||||
            pk,
 | 
			
		||||
            '{% trans "Remove row" %}',
 | 
			
		||||
        );
 | 
			
		||||
        if (line_items.length > 1) {
 | 
			
		||||
            buttons += makeIconButton(
 | 
			
		||||
                'fa-times icon-red',
 | 
			
		||||
                'button-row-remove',
 | 
			
		||||
                pk,
 | 
			
		||||
                '{% trans "Remove row" %}',
 | 
			
		||||
            );
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        buttons += '</div>';
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user