车间操作接口bug

This commit is contained in:
caoqianming 2021-11-19 10:46:16 +08:00
parent bd179c20b1
commit 718845b39a
1 changed files with 2 additions and 2 deletions

View File

@ -1,6 +1,6 @@
from django.shortcuts import render from django.shortcuts import render
from rest_framework.generics import CreateAPIView, GenericAPIView from rest_framework.generics import CreateAPIView, GenericAPIView
from rest_framework.mixins import CreateModelMixin, ListModelMixin, RetrieveModelMixin from rest_framework.mixins import CreateModelMixin, DestroyModelMixin, ListModelMixin, RetrieveModelMixin
from rest_framework.utils import serializer_helpers from rest_framework.utils import serializer_helpers
from rest_framework.utils.field_mapping import get_relation_kwargs from rest_framework.utils.field_mapping import get_relation_kwargs
from rest_framework.views import APIView from rest_framework.views import APIView
@ -264,7 +264,7 @@ class OperationViewSet(ListModelMixin, RetrieveModelMixin, CreateModelMixin, Gen
生产操作记录 生产操作记录
""" """
perms_map={'*':'*'} perms_map={'*':'*'}
queryset = Operation.objects.select_related('step', 'material').all() queryset = Operation.objects.select_related('step').all()
serializer_class = OperationListSerializer serializer_class = OperationListSerializer
filterset_fields = ['step', 'step__process', 'is_submited'] filterset_fields = ['step', 'step__process', 'is_submited']
ordering_fields = ['id'] ordering_fields = ['id']