Open cybkong opened 3 years ago
@cybkong, thank you for this issue. For future issues, please make sure to provide enough context to reproduce the issue. This usually includes:
For items 1,2 above, for example: https://billmap.govtrack.us/bills/117hr1
Ok I think 116hr1 has 46 pages for press statements
I think pagination is being done manually in the HTML, and datatables supports pagination in the other tables @ayeshamk was there a reason we're using manual pagination here or can I switch it out?
@aih @ayeshamk Also, locally, I can't seem to access 116hr1, etc. Do I have to run the bill jobs again to make sure? I ran it recently but maybe it failed for those? I have some odd behaviors on local that I need to look at soon.
I think we just have to remove the commented out code above and add the initialization of data tables on bills.js
But locally I'm not able to test on 117hr1 or 116hr1, I'll try re running bills jobs to fix local environment, but if anyone has other data/bills I could use, let me know! Or maybe Ayesha or Ari can test the fix and check in
I'll test it out. I have uploaded a recent django fixture of the whole db that will have data for all of the bills. I'm not sure if it's worth downloading and restoring that dump. @leedavidr, I'll send you a message on Slack with details.
I tried the suggested solution in a branch, but it doesn't work. This is probably due to the timing of the collection of data for the press statements from the API: the data is not available in time to create the Datatable with pagination.
IMO the way the Press Statements is currently being collected is a temporary solution. We will want to get the data from the API on the back-end and query our own back-end for that. Then render and apply the Datatable once the data is available. All of that is time-consuming, so I suggest we put this issue on the backlog for future.
Ok thank you Ari, we'll move this down
I think there may be a way to initialize the data when we need but sounds like the current way it works is not the ideal scenario anyway
@nkinaba @cybkong
Understand the Context section- pagination and scroll for "Press Statements" tab needs to be corrected Story 79 https://billmap.govtrack.us/bills/117hr1