diff --git a/app/backend/wells/views_v2.py b/app/backend/wells/views_v2.py index 9b6e922c8..b026ee57e 100644 --- a/app/backend/wells/views_v2.py +++ b/app/backend/wells/views_v2.py @@ -155,6 +155,7 @@ def geoJSONResponse(self): "identification_plate_number", "street_address", "city", + "well_status", "artesian_conditions", "storativity", "transmissivity", diff --git a/app/frontend/src/aquifers/components/AquiferMap.vue b/app/frontend/src/aquifers/components/AquiferMap.vue index 1cb3951a1..bb88b13a7 100755 --- a/app/frontend/src/aquifers/components/AquiferMap.vue +++ b/app/frontend/src/aquifers/components/AquiferMap.vue @@ -83,6 +83,7 @@ import observationWellInactiveLegendSrc from '../../common/assets/images/owells- import observationWellActiveLegendSrc from '../../common/assets/images/owells-active.svg' import wellsAllLegendSrc from '../../common/assets/images/wells-all.svg' import wellsArtesianLegendSrc from '../../common/assets/images/wells-artesian.svg' +import wellsClosedLegendSrc from '../../common/assets/images/wells-closed.svg' import wellsHydraulicLegendSrc from '../../common/assets/images/wells-hydraulic.svg' import { setupFeatureTooltips } from '../../common/mapbox/popup' @@ -149,13 +150,17 @@ export default { { imageSrc: wellsArtesianLegendSrc, label: 'artesian' + }, + { + imageSrc: wellsClosedLegendSrc, + label: 'decommissioned' } ] }, { show: false, id: WELLS_AQUIFER_PARAMETER_LAYER_ID, - label: 'Wells - aquifer parameters', + label: 'Wells - aquifer parameters', imageSrc: wellsHydraulicLegendSrc }, { diff --git a/app/frontend/src/aquifers/components/SingleAquiferMap.vue b/app/frontend/src/aquifers/components/SingleAquiferMap.vue index 00f05da65..c8e50e4c2 100644 --- a/app/frontend/src/aquifers/components/SingleAquiferMap.vue +++ b/app/frontend/src/aquifers/components/SingleAquiferMap.vue @@ -58,9 +58,7 @@ import { WELLS_SOURCE, AQUIFERS_SOURCE, observationWellsLayer, - WELLS_OBSERVATION_LAYER_ID, - - + WELLS_OBSERVATION_LAYER_ID } from '../../common/mapbox/layers' import { computeBoundsFromMultiPolygon } from '../../common/mapbox/geometry' import { LayersControl, LegendControl } from '../../common/mapbox/controls' @@ -77,6 +75,7 @@ import wellsHydraulicLegendSrc from '../../common/assets/images/wells-hydraulic. import wellsAllLegendSrc from '../../common/assets/images/wells-all.svg' import wellsArtesianLegendSrc from '../../common/assets/images/wells-artesian.svg' +import wellsClosedLegendSrc from '../../common/assets/images/wells-closed.svg' import uncorrelatedWellsIconSrc from '../../common/assets/images/wells-uncorrelated.svg' import emsWellsIconSrc from '../../common/assets/images/wells-ems.svg' import { setupFeatureTooltips } from '../../common/mapbox/popup' @@ -138,13 +137,17 @@ export default { { imageSrc: wellsArtesianLegendSrc, label: 'artesian' + }, + { + imageSrc: wellsClosedLegendSrc, + label: 'decommissioned' } ] }, { show: true, id: WELLS_AQUIFER_PARAMETER_LAYER_ID, - label: 'Wells - aquifer parameters', + label: 'Wells - aquifer parameters', imageSrc: wellsHydraulicLegendSrc }, { @@ -514,13 +517,13 @@ export default { const endEvents = ['zoomend', 'moveend'] endEvents.forEach(eventName => { this.map.on(eventName, (e) => { - this.updateMapLegendBasedOnVisibleElements(); + this.updateMapLegendBasedOnVisibleElements(); }) }) } }, - + watch: { aquiferId (newAquiferId, oldAquiferId) { this.setSelectedAquifer(oldAquiferId, false) diff --git a/app/frontend/src/common/assets/images/wells-closed.svg b/app/frontend/src/common/assets/images/wells-closed.svg new file mode 100644 index 000000000..f3174d326 --- /dev/null +++ b/app/frontend/src/common/assets/images/wells-closed.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/app/frontend/src/common/mapbox/images.js b/app/frontend/src/common/mapbox/images.js index 1980798e0..56c46c355 100644 --- a/app/frontend/src/common/mapbox/images.js +++ b/app/frontend/src/common/mapbox/images.js @@ -110,6 +110,17 @@ export class PulsingArtesianWellImage extends PulsingDotImage { } } +export class PulsingClosedWellImage extends PulsingDotImage { + constructor (map) { + super(map, { + size: 90, + dotColour: 'rgba(48, 45, 87, 1)', + dotStrokeColour: 'rgba(0, 0, 0, 1)', + pulseColour: 'rgba(173, 171, 199, %d)' + }) + } +} + export function buildLeafletStyleMarker (longitude, latitude, options = {}) { const element = document.createElement('div') element.className = 'map-pin' diff --git a/app/frontend/src/common/mapbox/layers.js b/app/frontend/src/common/mapbox/layers.js index 632f96959..d7a1bd2d9 100644 --- a/app/frontend/src/common/mapbox/layers.js +++ b/app/frontend/src/common/mapbox/layers.js @@ -17,7 +17,7 @@ export const FOCUSED_WELLS_LAYER_ID = 'focused-wells' export const FOCUSED_WELLS_ARTESIAN_LAYER_ID = 'focused-wells-artesian' export const FOCUSED_WELL_IMAGE_ID = 'focused-well-image' export const FOCUSED_WELL_ARTESIAN_IMAGE_ID = 'focused-artesian-well-image' - +export const FOCUSED_WELL_CLOSED_IMAGE_ID = 'focused-closed-well-image' export const SEARCHED_REGISTRIES_SOURCE_ID = 'searched-registries-source' export const SEARCHED_REGISTRIES_LAYER_ID = 'searched-registries-layer' @@ -278,14 +278,18 @@ export function wellsBaseAndArtesianLayer (options = {}) { const styles = defaultsDeep(options.styles, { 'circle-color': [ 'case', + ['==', ['get', 'well_status'], 'CLOSURE'], '#302d57', + ['==', ['get', 'well_status'], 'ABANDONED'], '#302d57', ['to-boolean', ['get', 'artesian']], '#1099FE', '#0162FE' ], 'circle-radius': 3, 'circle-stroke-color': [ 'case', + ['==', ['get', 'well_status'], 'CLOSURE'], 'transparent', + ['==', ['get', 'well_status'], 'ABANDONED'], 'transparent', ['to-boolean', ['get', 'artesian']], '#EE14CA', - 'transparent' + 'black' ], 'circle-stroke-width': 2.5 }) @@ -316,12 +320,16 @@ export function searchedWellsLayer (options = {}) { const styles = defaultsDeep(options.styles, { 'circle-color': [ 'case', + ['==', ['get', 'well_status'], 'CLOSURE'], '#302d57', + ['==', ['get', 'well_status'], 'ABANDONED'], '#302d57', ['to-boolean', ['get', 'artesian_conditions']], '#1099FE', '#0162FE' ], 'circle-radius': 5, 'circle-stroke-color': [ 'case', + ['==', ['get', 'well_status'], 'CLOSURE'], 'transparent', + ['==', ['get', 'well_status'], 'ABANDONED'], 'transparent', ['to-boolean', ['get', 'artesian_conditions']], '#EE14CA', 'black' ], @@ -337,6 +345,8 @@ export function focusedWellsLayer (options = {}) { const layout = defaultsDeep(options.layout, { 'icon-image': [ 'case', + ['==', ['get', 'well_status'], 'CLOSURE'], FOCUSED_WELL_CLOSED_IMAGE_ID, + ['==', ['get', 'well_status'], 'ABANDONED'], FOCUSED_WELL_CLOSED_IMAGE_ID, ['to-boolean', ['get', 'artesian_conditions']], FOCUSED_WELL_ARTESIAN_IMAGE_ID, FOCUSED_WELL_IMAGE_ID ] diff --git a/app/frontend/src/submissions/components/SubmissionForm/ActivitySubmissionForm.vue b/app/frontend/src/submissions/components/SubmissionForm/ActivitySubmissionForm.vue index c31c66667..88c504d12 100644 --- a/app/frontend/src/submissions/components/SubmissionForm/ActivitySubmissionForm.vue +++ b/app/frontend/src/submissions/components/SubmissionForm/ActivitySubmissionForm.vue @@ -50,7 +50,7 @@ Licensed under the Apache License, Version 2.0 (the "License");

Submit activity on a well. Try a search to see if the well exists in the system before submitting a report.

-

All form fields marked with a trailing asterisk are mandatory fields.

+

All form fields marked with a trailing asterisk are mandatory fields.

diff --git a/app/frontend/src/wells/components/SearchMap.vue b/app/frontend/src/wells/components/SearchMap.vue index 12907e7f8..7be5afc98 100644 --- a/app/frontend/src/wells/components/SearchMap.vue +++ b/app/frontend/src/wells/components/SearchMap.vue @@ -39,19 +39,21 @@ import { focusedWellsLayer, FOCUSED_WELL_IMAGE_ID, FOCUSED_WELL_ARTESIAN_IMAGE_ID, + FOCUSED_WELL_CLOSED_IMAGE_ID, wellLayerFilter, SEARCHED_WELLS_LAYER_ID, - WELLS_SOURCE, + WELLS_SOURCE } from '../../common/mapbox/layers' import { LegendControl, BoxZoomControl, SearchOnMoveControl, ClearSearchCriteriaControl } from '../../common/mapbox/controls' import { createWellPopupElement } from '../popup' -import { PulsingWellImage, PulsingArtesianWellImage } from '../../common/mapbox/images' +import { PulsingWellImage, PulsingArtesianWellImage, PulsingClosedWellImage } from '../../common/mapbox/images' import { DEFAULT_MAP_ZOOM, CENTRE_LNG_LAT_BC, buildWellsGeoJSON, convertLngLatBoundsToDirectionBounds, boundsCompletelyContains } from '../../common/mapbox/geometry' import { RESET_WELLS_SEARCH, SEARCH_WELLS } from '../../wells/store/actions.types' import wellsAllLegendSrc from '../../common/assets/images/wells-all.svg' import wellsArtesianLegendSrc from '../../common/assets/images/wells-artesian.svg' +import wellsClosedLegendSrc from '../../common/assets/images/wells-closed.svg' import { mapGetters } from 'vuex' import { setupFeatureTooltips } from '../../common/mapbox/popup' @@ -61,7 +63,7 @@ const WELL_FEATURE_PROPERTIES_FOR_POPUP = [ 'street_address', 'is_published' ] -const FOCUSED_WELL_PROPERTIES = WELL_FEATURE_PROPERTIES_FOR_POPUP.concat(['artesian_conditions']) +const FOCUSED_WELL_PROPERTIES = WELL_FEATURE_PROPERTIES_FOR_POPUP.concat(['artesian_conditions', 'well_status']) export default { name: 'SearchMap', @@ -88,6 +90,10 @@ export default { imageSrc: wellsArtesianLegendSrc, label: 'artesian' }, + { + imageSrc: wellsClosedLegendSrc, + label: 'decommissioned' + } ] } ], @@ -200,6 +206,7 @@ export default { this.map.on('load', () => { this.map.addImage(FOCUSED_WELL_ARTESIAN_IMAGE_ID, new PulsingArtesianWellImage(this.map), { pixelRatio: 2 }) this.map.addImage(FOCUSED_WELL_IMAGE_ID, new PulsingWellImage(this.map), { pixelRatio: 2 }) + this.map.addImage(FOCUSED_WELL_CLOSED_IMAGE_ID, new PulsingClosedWellImage(this.map), { pixelRatio: 2 }) const tooltipLayers = { [WELLS_BASE_AND_ARTESIAN_LAYER_ID]: { diff --git a/docker-compose.yml b/docker-compose.yml index 667b7f406..324b316f6 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,4 +1,4 @@ -version: '3.7' +# version: '3.7' # NOTE For Red Hat or other images on the internal registry please login as follows: # 1. Be logged into the BC Gov OpenShift Console # https://console.pathfinder.gov.bc.ca:8443/console/catalog)