我正在从 Angular 向 Django 发送一个 excel 文件。我想使用 Pandas 读取文件并在文件中执行一些操作,但我不知道该怎么做。
class fileupload(APIView) :
def post(self, request):
f = request.FILES
print(f)
当我打印时,它显示在下面,
<MultiValueDict: {'excelfile': [<InMemoryUploadedFile: New_Excel.xlsx (application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)>]}>
在这里,我想将此文件保存到某个位置并使用 pandas 执行操作,或者如果可能的话,直接需要使用 pandas 读取文件。我是 Django 和 Pandas 的新手,所以如果有什么问题,请帮忙.. 提前致谢