From 0cb2b4933361ecac611755ff3fd857315c1273ea Mon Sep 17 00:00:00 2001 From: Oliver Date: Mon, 12 Jul 2021 22:23:08 +1000 Subject: [PATCH] Remove unused forms --- InvenTree/part/forms.py | 10 --------- InvenTree/stock/forms.py | 44 ---------------------------------------- 2 files changed, 54 deletions(-) diff --git a/InvenTree/part/forms.py b/InvenTree/part/forms.py index 3b60567695..f04f512045 100644 --- a/InvenTree/part/forms.py +++ b/InvenTree/part/forms.py @@ -56,16 +56,6 @@ class PartImageDownloadForm(HelperForm): ] -class PartImageForm(HelperForm): - """ Form for uploading a Part image """ - - class Meta: - model = Part - fields = [ - 'image', - ] - - class BomExportForm(forms.Form): """ Simple form to let user set BOM export options, before exporting a BOM (bill of materials) file. diff --git a/InvenTree/stock/forms.py b/InvenTree/stock/forms.py index ec3eee09d5..0061bbb984 100644 --- a/InvenTree/stock/forms.py +++ b/InvenTree/stock/forms.py @@ -328,50 +328,6 @@ class UninstallStockForm(forms.ModelForm): ] -class AdjustStockForm(forms.ModelForm): - """ Form for performing simple stock adjustments. - - - Add stock - - Remove stock - - Count stock - - Move stock - - This form is used for managing stock adjuments for single or multiple stock items. - """ - - destination = TreeNodeChoiceField(queryset=StockLocation.objects.all(), label=_('Destination'), required=True, help_text=_('Destination stock location')) - - note = forms.CharField(label=_('Notes'), required=True, help_text=_('Add note (required)')) - - # transaction = forms.BooleanField(required=False, initial=False, label='Create Transaction', help_text='Create a stock transaction for these parts') - - confirm = forms.BooleanField(required=False, initial=False, label=_('Confirm stock adjustment'), help_text=_('Confirm movement of stock items')) - - set_loc = forms.BooleanField(required=False, initial=False, label=_('Set Default Location'), help_text=_('Set the destination as the default location for selected parts')) - - class Meta: - model = StockItem - - fields = [ - 'destination', - 'note', - # 'transaction', - 'confirm', - ] - - -class EditStockItemStatusForm(HelperForm): - """ - Simple form for editing StockItem status field - """ - - class Meta: - model = StockItem - fields = [ - 'status', - ] - - class EditStockItemForm(HelperForm): """ Form for editing a StockItem object. Note that not all fields can be edited here (even if they can be specified during creation.