bcgov / cas-ciip-portal

The Climate Action Secretariat's CleanBC Industrial Incentive Program application
https://ciip.gov.bc.ca/
Apache License 2.0
10 stars 2 forks source link

As a reporter, I want to only report the fuels that are allowed for emission categories, so that I am following the guidance #1986

Closed LindsayMacfarlane closed 1 year ago

LindsayMacfarlane commented 2 years ago

Description:

Applicants should report flaring and venting using the Natural Gas fuel. The guidance states this, but it was ignored by many and we received many applications with various other fuels reporting under flaring and venting.

~In #1985, administrators will have the ability to define the fuels that can be used under each emission category.~

2145 has replaced #1985. In #2145 we will have a database table that defines the fuels that are reportable under each emission category. This user story will enforce those rules for the industrial reporter

Below is a screenshot of the current fuel form: image.png

To be able to filter the list of fuel based on the emission category, the emission category has to be chosen first.

Acceptance Criteria:

Given I am industrial reporter filling out a CIIP application When I am on the Fuels tab Then I cannot enter fuel data incorrectly for the related emission category

UPDATED Given I am industrial reporter filling out a CIIP application When I am on the Fuels tab and change the emission category to one not containing the selected fuel Then the fuel, quantity, and unit fields are reset.

Given I am industrial reporter filling out a CIIP application When I am on the Fuels tab and change the emission category to one that also contains the entered fuel, Then then the fuel, quantity, and units remain filled in.

Checklist:

matthieu-foucault commented 2 years ago

Two options for redesign:

1) A possible option would be to redesign the fuel form to look similar to the on-site emissions form (see below), and to display headers for each emission category.

image.png

With this option, we would need an add button for each emission category. Each row would have a drop-down for the fuel name, an input to enter the amount, and a remove button.

2) A second option would be to keep displaying a single list of fuels, but to only display the "Emission Category" dropdown, until it is chosen. When the emission category is chosen, The fuel name dropdown can be displayed.

In either case, the form's JSON schema should not be modified. I think that option 1 is better in terms of UX, but may require a bit more code.

matthieu-foucault commented 2 years ago

TODO: schedule a meeting with Hanna and @rajpersram

matthieu-foucault commented 2 years ago

GGIRCS team to create mockups for both options.

An information tooltip should be displayed to explain to reporters that the list of fuels is filtered based on the emission category.

If a fuel is reported in SWRS, which does not match the rules, we should show a warning saying "This fuel cannot be reported under this emission category, please remove it or contact CAS for assistance". See products form for a similar feature.

Dianadec commented 1 year ago

Based on labels currently added, does this card need an updated design in order to add an estimate? @dleard cc @LindsayMacfarlane

dleard commented 1 year ago

It does need a small bit of design for ensuring an emission category is selected before allowing the fuel data to be entered. My inital thought is that it could be a dropdown in the fuel card and everything below is disabled until the emission category is selected.

dleard commented 1 year ago

Hey team! Please add your planning poker estimate with Zenhub @BCerki @gurjmatharu @mikevespi @sam-warren @Sepehr-Sobhani @tmastrom

LindsayMacfarlane commented 1 year ago

@dleard - is this ticket still required? I had a note saying 1986 was closed and replaced with 2134, but I could have made a mistake.

dleard commented 1 year ago

yes, this is the front-end work related to #2145. In #2145 we created relationships in the database to associate fuels with specific emission categories. In this card, we need to enforce that association on the front-end so that only the fuels associated to the selected emission category can be reported under that category.

dleard commented 1 year ago

1985 was replaced by #2145, this one I just did a small re-write because the work was not heavily affected by our shift in priorities after the CIIP prioritization meeting.

mikevespi commented 1 year ago

Note: I made some UX decisions here.

pbastia commented 1 year ago

Nice @mikevespi ! I can see that there are no fuels associated to the 'Wastewater' Emission Category - this was done in #2145 as part of the data CIIP gave us. This can probably be deleted at a later point.

mikevespi commented 1 year ago

For posterity, Fugitive also has no fuels associated.