mirror of
https://github.com/inventree/InvenTree.git
synced 2025-07-11 15:34:15 +00:00
Order barcodes (#4575)
* Add barcode support to external orders - ReturnOrder - PurchaseOrder - SalesOrder * Support scanning for new model types * Integrate UI elements for ReturnOrder * Update PurchaseOrder page * SalesOrder implementation
This commit is contained in:
@ -11,12 +11,13 @@ import json
|
||||
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
|
||||
from company.models import SupplierPart
|
||||
import company.models
|
||||
import order.models
|
||||
import part.models
|
||||
import stock.models
|
||||
from InvenTree.helpers import hash_barcode
|
||||
from part.models import Part
|
||||
from plugin import InvenTreePlugin
|
||||
from plugin.mixins import BarcodeMixin
|
||||
from stock.models import StockItem, StockLocation
|
||||
|
||||
|
||||
class InvenTreeInternalBarcodePlugin(BarcodeMixin, InvenTreePlugin):
|
||||
@ -33,10 +34,13 @@ class InvenTreeInternalBarcodePlugin(BarcodeMixin, InvenTreePlugin):
|
||||
"""Returns a list of database models which support barcode functionality"""
|
||||
|
||||
return [
|
||||
Part,
|
||||
StockItem,
|
||||
StockLocation,
|
||||
SupplierPart,
|
||||
company.models.SupplierPart,
|
||||
order.models.PurchaseOrder,
|
||||
order.models.ReturnOrder,
|
||||
order.models.SalesOrder,
|
||||
part.models.Part,
|
||||
stock.models.StockItem,
|
||||
stock.models.StockLocation,
|
||||
]
|
||||
|
||||
def format_matched_response(self, label, model, instance):
|
||||
|
Reference in New Issue
Block a user