( 7 months ago )
I have done this in my views:
from django.core.management import call_command
if request.method == 'POST':
new_company = request.FILES['myfile']
call_command('loaddata', new_company, verbosity=0)
return render(request, 'company/import.html')
Its similar to
python manage.py loaddata.
But when I try to execute this I get the following error:
No fixture named 'Primium Shipment-2019-04-11 14_01_24.254460' found.
Can anyone tell me why this is happening?