事件记录导出完成
This commit is contained in:
parent
cb33dcb021
commit
93a00363b2
|
@ -26,7 +26,7 @@ from apps.ecm.service import update_remind_read
|
||||||
from apps.utils.viewsets import CustomGenericViewSet, CustomModelViewSet
|
from apps.utils.viewsets import CustomGenericViewSet, CustomModelViewSet
|
||||||
from apps.utils.export import export_excel_img
|
from apps.utils.export import export_excel_img
|
||||||
|
|
||||||
obj_cate_dict = {'people': '人员', 'operation': '作业', 'other': '其他'}
|
obj_cate_dict = {'people': '人员', 'opl': '作业', 'other': '其他'}
|
||||||
mark_dict = {10: '正常', 20: '误报'}
|
mark_dict = {10: '正常', 20: '误报'}
|
||||||
|
|
||||||
# Create your views here.
|
# Create your views here.
|
||||||
|
@ -171,7 +171,6 @@ class EventViewSet(ListModelMixin, RetrieveModelMixin, DestroyModelMixin, Custom
|
||||||
|
|
||||||
for i in odata:
|
for i in odata:
|
||||||
cates_str = ''
|
cates_str = ''
|
||||||
ep_str = ''
|
|
||||||
for m in i['cates_']:
|
for m in i['cates_']:
|
||||||
cates_str = cates_str + m['name'] + '/'
|
cates_str = cates_str + m['name'] + '/'
|
||||||
data.append(
|
data.append(
|
||||||
|
@ -188,7 +187,6 @@ class EventViewSet(ListModelMixin, RetrieveModelMixin, DestroyModelMixin, Custom
|
||||||
i['face_img']
|
i['face_img']
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
print(data)
|
|
||||||
return Response({'path': export_excel_img(field_data, data, '事件记录')})
|
return Response({'path': export_excel_img(field_data, data, '事件记录')})
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue