Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

Add notificationURL testing parameter and documentation

ZachTRice534109ea1e5c
diff --git a/doc/testing.md b/doc/testing.md
index c2e1fa6ba..1fb1701e0 100644
--- a/doc/testing.md
+++ b/doc/testing.md
@@ -67,3 +67,4 @@ To run tests for both browsers in sequence: `npm run e2e`.
| `now` | date | *`YYYY-MM-DDThh:mm:ssZ`* | Overrides the current date and time. This only works when using the `now()` function from `js/util/util.js`. |
| `showError` | boolean | *`true` or `false`* | If any value is specified, an error dialog will be shown on startup. |
| `showSubdaily` | boolean | *`true` or `false`* | If any value is specified, the hour input, minute input and "minutes" timeline zoom option will be shown. |
+| `notificationURL` | string | `https://testing.url.com` | Overrides the notification URL found in the features.json configuration file. |
diff --git a/web/js/notifications/ui.js b/web/js/notifications/ui.js
index fd2ce3083..ddccc6260 100644
--- a/web/js/notifications/ui.js
+++ b/web/js/notifications/ui.js
@@ -48,6 +48,9 @@ export function notificationsUi(models, config) {
if (config.parameters.mockAlerts) {
url = 'mock/notify_' + config.parameters.mockAlerts + '.json';
}
+ if (config.parameters.notificationURL) {
+ url = 'https://status.earthdata.nasa.gov/api/v1/notifications?domain=' + config.parameters.notificationURL;
+ }
mainIcon = $('#wv-info-button')[0];
mainIconLabel = $('#wv-info-button label')[0];