This commit is contained in:
caoqianming 2020-09-24 10:03:10 +08:00
parent ea28be2f5f
commit 87ced2556d
3 changed files with 3 additions and 0 deletions

1
.gitignore vendored
View File

@ -7,6 +7,7 @@ media/
static/
__pycache__/
*.pyc
*.sqlite3
# client
node_modules/

View File

@ -120,6 +120,7 @@ class QualificationViewSet(ModelViewSet):
search_fields = ['cma', 'cnas', 'sszx', 'other', 'service']
# ordering_fields = ['sszx']
ordering = 'sszx'
filterset_fields = ['sszx']
@action(methods=['get'], detail=False,url_name='qualification_group_by', perms_map = {'*':'*'})
def group(self, request, pk=None):
@ -146,6 +147,7 @@ class CNASViewSet(ModelViewSet):
serializer_class = CNASSerializer
search_fields = ['bzbh', 'bzmc', 'sszx', 'xmmc', 'bztk']
ordering_fields = ['bzmc']
filterset_fields = ['sszx']
ordering = 'bzmc'
@action(methods=['post'], detail=False, url_path='import', url_name='cnas_import', perms_map = {'post':'cnas_import'})

Binary file not shown.