bcgov / bcparks-ar-admin

BCParks Attendance and Revenue Admin
Apache License 2.0
4 stars 11 forks source link

No Data to Export Should Inform User / Not Generate Report #384

Open davidclaveau opened 1 month ago

davidclaveau commented 1 month ago

Description:

When I choose to generate a report, if there are no values found then an empty report should not be generated and I should be informed on the frontend that the report is empty and not needed.

The user doesn't see that a report is empty unless they download the report and open the spreadsheet (and find there is no data). This could be applied to Variance or Missing.

Acceptance Criteria:

Given I am an A&R user When I choose to generate a report Then when there's no data, the UI tells me and does not create an empty report (and it prevents me from downloading an empty report).

Development Checklist:

Definition of Ready (Note: If any of these points are not applicable, mark N/A)

Definition of Done

Notes:

davidclaveau commented 2 weeks ago

Hey @manuji this is ready to be moved to TEST now!

This is just that nice-to-have change that you had mentioned, which Nicole and Sally had agreed would be good to add. If there's no data to export the backend won't create a document/upload it to S3, and the frontend will now make note for the user and show 'No data - no report generated'.

Note that it's currently just for the Missing Export as I didn't want to step on the toes of @meredithom's changes coming in #254, but it should be pretty easy to add once that's done 😄

Image

Dianadec commented 1 day ago

@davidclaveau is this one ready to be tested or is it waiting on a piece from #254 ? cc @manuji

manuji commented 1 day ago

Hi @Dianadec , this is ready for QA and I will update the status of this today as well. My apologies for the delay.

manuji commented 13 hours ago

Tested on TEST: Passed