Closed Sriram-pc closed 2 years ago
Should this UI include assigning new swrs fuels (ie: new spellings / actual new fuels) to a normalized fuel type?
I think so yes
Hey team! Please add your planning poker estimate with ZenHub @AlexZorkin @matthieu-foucault @pbastia
Rough UI design
Something to consider with this work and the work in #385 (and any subsequent work that may touch the swrs schema) is that up until now, the swrs schema has been read-only, with no extra functions or mutations added. We really have two different types of data in this schema at the moment:
Our load process clones the current schema, loads updated data via materialized views into the clone, drops the current schema and renames the clone to match the original. We haven't had any custom mutations added to the swrs schema, but under the current load process those mutations would be lost in the drop.
I think it makes sense to add a new schema that won't be dropped for mutations and custom queries, but it also may make sense (at some point) to move those contextual data tables like fuel_mapping into that new un-dropped schema as well. That would separate concerns, where the swrs schema would be purely data that comes from ECCC and context tables that we populate ourselves would live elsewhere. This would require a refactor in the code as well as manually fixing a lot of questions in metabase that would point to a non-existent table once those contextual tables were removed.
@LindsayMacfarlane This needs a little bit of tinkering in the dev environment database in order to properly review it. Let me know when you want to look this over and I can make some edits beforehand.
Thanks for the demo @dleard . When you are ready, feel free to push to Test to start testing with the CIIP team.
Description:
The list of fuels in the
swrs.fuel_carbon_tax_details
table is only editable by developers at the moment. This list contains the normalized fuel names, and connects them to the fuels defined in the carbon tax act. This feature would allow CAS staff to make updates without the development team's involvement.This feature should provide a UI allowing CAS staff to manage the contents of the
swrs.fuel_carbon_tax_details
tableAcceptance Criteria: Given I am logged into the ggircs app When I am on the landing page Then there is a option to manage the normalized fuel types
Given I am in the fuel types management UI When I first load the page Then any fuels that are not associated to a normalized fuel type are clearly shown and I can easily set the normalized fuel type for that fuel
Given I am in the fuel types management UI When I want to find a fuel type Then I can search the normalized fuel types
Given I am in the fuel types management UI When I need to edit a normalized fuel type Then I can make a change to the normalized fuel type
Given I am in the fuel types management UI When I need to remove a fuel's association with a normalized fuel type Then I can remove that fuel from the normalized fuel type and it is then shown at the top of the page as an unassociated fuel
Development Checklist