only 10 records is processed
only 10 records is processed
RobinLI
Posts: 4Questions: 1Answers: 0
I have a queryset, which have 12 records, but finally it only processed 10.
trace show it was limit to 10 in function paging(), actually I set the "paging" as false.
This discussion has been closed.
Answers
Thanks for your question - however, per the forum rules can you link to a test case showing the issue please. This will allow the issue to be debugged.
Information on how to create a test page, if you can't provide a link to your own page can be found here.
Thanks,
Allan
I put the code here. It's Python code with Django.
records in testabc:
when I type the jsonaddress in browser(http://localhost:8000/test_datatable_Json) and get the following result:
it's show 12 records, but actually only return 10.
I trace into the datatable view, the issue is the paging() function return 10.
Just found that when I put &length=-1 in the address, it will get all 12 results.
(http://localhost:8000/measurement/test_datatable_Json?&length=-1)
Is this a bug? or should put length=-1 there?
It sounds and looks like your Python script hasn't implemented server-side processing. Either you need to implement that, or not use server-side processing.
Allan
Sure, it's server side process issue. At server side, installed Django-datatable-view 1.13.0. and my code is based on BaseDatatableView base clase. the issue is in the base class funcction paging().
with my example, it goes to else and set
limit
to 10. So I put&length=-1
at request to set thislimit
to-1
.I dont' know why my
'paging' = false
doesn't take effect. for my understanding, it should not go topaging()
.I'm afraid I'm not familiar with that Django library. You would need to contact the author of that library for assistance with it - I know next to nothing about Python!
Allan