diff --git a/.ddev/.gitignore b/.ddev/.gitignore index 28eb786f34..5003016019 100644 --- a/.ddev/.gitignore +++ b/.ddev/.gitignore @@ -16,8 +16,8 @@ /commands/.gitattributes /commands/db/mysql /commands/host/launch -/commands/web/live /commands/web/xdebug +/commands/web/live /config.*.y*ml /db_snapshots /import-db diff --git a/.ddev/config.local.yaml.example b/.ddev/config.local.yaml.example index 0d821108ae..bb87c986a8 100644 --- a/.ddev/config.local.yaml.example +++ b/.ddev/config.local.yaml.example @@ -5,11 +5,19 @@ hooks: AND mail NOT LIKE '%~%'" - exec: drush sqlq "UPDATE users SET mail = replace(mail, '~', '.test~') WHERE uid > 0 AND mail LIKE '%~%'" - - exec: drush en devel views_ui -y + - exec: drush en devel views_ui field_ui -y + - exec: drush fra -y - exec: drush uli post-start: - exec: "cd .. && chmod +x ./scripts/build && ./scripts/build" - exec: drush site-install -y hedley install_configure_form.update_status_module='array(FALSE,FALSE)' --locale=en --account-name="admin" --account-pass="admin" --account-mail="admin@example.com" --db-url=mysql://db:db@db/db --uri="https://ihangane.ddev.site:4443" - - exec: drush en devel views_ui -y + - exec: drush en devel views_ui field_ui -y + - exec: drush fra -y - exec: composer install -d sites/default/files/composer + # Run migration + - exec: drush en -y hedley_migrate + - exec: drush en -y migrate migrate_ui migrate_extras + - exec: drush mi --group=default --user=1 + - exec: drush mi --group=counseling --user=1 + - exec: drush mi --group=forms --user=1 - exec: drush uli diff --git a/.ddev/config.yaml b/.ddev/config.yaml index 50c3442fe0..e850c9692b 100644 --- a/.ddev/config.yaml +++ b/.ddev/config.yaml @@ -1,7 +1,7 @@ name: ihangane type: drupal7 docroot: server/www -php_version: "7.2" +php_version: "7.3" webserver_type: nginx-fpm router_http_port: "8081" router_https_port: "4443" @@ -15,9 +15,9 @@ composer_version: "1" web_environment: [] -# This config.yaml was created with ddev version v1.17.0 -# webimage: drud/ddev-webserver:v1.17.0 -# dbimage: drud/ddev-dbserver-mariadb-10.3:v1.17.0 +# This config.yaml was created with ddev version v1.17.7 +# webimage: drud/ddev-webserver:v1.17.7 +# dbimage: drud/ddev-dbserver-mariadb-10.3:v1.17.7 # dbaimage: phpmyadmin:5 # However we do not recommend explicitly wiring these images into the # config.yaml as they may break future versions of ddev. @@ -56,6 +56,11 @@ web_environment: [] # "ddev xdebug" to enable xdebug and "ddev xdebug off" to disable it work better, # as leaving xdebug enabled all the time is a big performance hit. +# xhprof_enabled: false # Set to true to enable xhprof and "ddev start" or "ddev restart" +# Note that for most people the commands +# "ddev xhprof" to enable xhprof and "ddev xhprof off" to disable it work better, +# as leaving xhprof enabled all the time is a big performance hit. + # webserver_type: nginx-fpm # or apache-fpm # timezone: Europe/Berlin @@ -158,7 +163,7 @@ web_environment: [] # In this case the user must provide all such settings. # You can inject environment variables into the web container with: -# web_environment: +# web_environment: # - SOMEENV=somevalue # - SOMEOTHERENV=someothervalue @@ -168,8 +173,6 @@ web_environment: [] # This is to enable experimentation with alternate file mounting strategies. # For advanced users only! -# provider: default # Currently "default", "pantheon", "ddev-live" -# # Many ddev commands can be extended to run tasks before or after the # ddev command is executed, for example "post-start", "post-import-db", # "pre-composer", "post-composer" diff --git a/.ddev/db-build/Dockerfile.example b/.ddev/db-build/Dockerfile.example index 3fdd1be604..ff00a3dd7c 100644 --- a/.ddev/db-build/Dockerfile.example +++ b/.ddev/db-build/Dockerfile.example @@ -3,4 +3,4 @@ # or packages or anything else to your dbimage ARG BASE_IMAGE FROM $BASE_IMAGE -RUN echo "Built from drud/ddev-dbserver-mariadb-10.2:v1.17.0" >/var/tmp/built-from.txt +RUN echo "Built from drud/ddev-dbserver-mariadb-10.2:v1.17.7" >/var/tmp/built-from.txt diff --git a/.travis.yml b/.travis.yml index 9e647ba359..af64c4c4a9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -59,7 +59,7 @@ jobs: - "$TRAVIS_BUILD_DIR/ci-scripts/test_server.sh" - stage: Deploy name: "Deployment to Pantheon" - if: branch = develop + if: branch = _hold_ script: - "export DEPLOY=1 && $TRAVIS_BUILD_DIR/ci-scripts/install_client.sh" - "$TRAVIS_BUILD_DIR/ci-scripts/install_ddev.sh" diff --git a/client/gulpfile.js b/client/gulpfile.js index 1ce8eb8113..9089b25676 100644 --- a/client/gulpfile.js +++ b/client/gulpfile.js @@ -404,7 +404,6 @@ var precacheProd = [ 'bower_components/dropzone/dist/min/dropzone.min.*.css', 'bower_components/dropzone/dist/min/dropzone.min.*.js', 'bower_components/dexie/dist/dexie.min.*.js', - 'bower_components/exif-js/exif.js', 'bower_components/semantic/dist/themes/**/' + precacheFileGlob, 'bower_components/semantic/dist/semantic.min.*.css' ]; diff --git a/client/package-lock.json b/client/package-lock.json index bdbe028b1e..d59a0185e2 100644 --- a/client/package-lock.json +++ b/client/package-lock.json @@ -9,7 +9,7 @@ "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.9.2.tgz", "integrity": "sha512-NE2DtOdufG7R5vnfQUTehdTfNycfUANEtCa9PssN9O/xmTzP4E08UI797ixaei6hBEVL9BI/PsdJS5x7mWoB9Q==", "requires": { - "regenerator-runtime": "0.13.5" + "regenerator-runtime": "^0.13.5" } }, "@hapi/address": { @@ -32,10 +32,10 @@ "resolved": "https://registry.npmjs.org/@hapi/joi/-/joi-15.1.1.tgz", "integrity": "sha512-entf8ZMOK8sc+8YfeOlM8pCfg3b5+WZIKBfUaaJT8UsjAAPjartzxIYm3TIbjvA4u+u++KbcXD38k682nVHDAQ==", "requires": { - "@hapi/address": "2.1.4", - "@hapi/bourne": "1.3.2", - "@hapi/hoek": "8.5.1", - "@hapi/topo": "3.1.6" + "@hapi/address": "2.x.x", + "@hapi/bourne": "1.x.x", + "@hapi/hoek": "8.x.x", + "@hapi/topo": "3.x.x" } }, "@hapi/topo": { @@ -43,7 +43,7 @@ "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-3.1.6.tgz", "integrity": "sha512-tAag0jEcjwH+P2quUfipd7liWCNX2F8NvYjQp2wtInsZxnMlypdw0FtAOLxtvvkO+GSRRbmNi8m/5y42PQJYCQ==", "requires": { - "@hapi/hoek": "8.5.1" + "@hapi/hoek": "^8.3.0" } }, "@mrmlnc/readdir-enhanced": { @@ -52,8 +52,8 @@ "integrity": "sha512-bPHp6Ji8b41szTOcaP63VlnbbO5Ny6dwAATtY6JTjh5N2OLrb5Qk/Th5cRkRQhkWCt+EJsYrNB0MiL+Gpn6e3g==", "dev": true, "requires": { - "call-me-maybe": "1.0.1", - "glob-to-regexp": "0.3.0" + "call-me-maybe": "^1.0.1", + "glob-to-regexp": "^0.3.0" } }, "@nodelib/fs.stat": { @@ -97,9 +97,9 @@ "integrity": "sha512-1Bh06cbWJUHMC97acuD6UMG29nMt0Aqz1vF3guLfG+kHHJhy3AyohZFFxYk2f7Q1SQIrNwvncxAE0N/9s70F2w==", "dev": true, "requires": { - "@types/events": "3.0.0", - "@types/minimatch": "3.0.3", - "@types/node": "13.9.5" + "@types/events": "*", + "@types/minimatch": "*", + "@types/node": "*" } }, "@types/gulp-util": { @@ -108,10 +108,10 @@ "integrity": "sha512-E06WN1OfqL5UsMwJ1T7ClgnaXgaPipb7Ee8euMc3KRHLNqxdvWrDir9KA6uevgzBgT7XbjgmzZA2pkzDqBBX7A==", "dev": true, "requires": { - "@types/node": "13.9.5", - "@types/through2": "2.0.34", - "@types/vinyl": "2.0.4", - "chalk": "2.4.2" + "@types/node": "*", + "@types/through2": "*", + "@types/vinyl": "*", + "chalk": "^2.2.0" }, "dependencies": { "ansi-styles": { @@ -120,7 +120,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -129,9 +129,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -161,7 +161,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -188,10 +188,10 @@ "resolved": "https://registry.npmjs.org/@types/request/-/request-2.48.4.tgz", "integrity": "sha512-W1t1MTKYR8PxICH+A4HgEIPuAC3sbljoEVfyZbeFJJDbr30guDspJri2XOaM2E+Un7ZjrihaDi7cf6fPa2tbgw==", "requires": { - "@types/caseless": "0.12.2", - "@types/node": "13.9.5", - "@types/tough-cookie": "2.3.6", - "form-data": "2.5.1" + "@types/caseless": "*", + "@types/node": "*", + "@types/tough-cookie": "*", + "form-data": "^2.5.0" } }, "@types/through2": { @@ -200,7 +200,7 @@ "integrity": "sha512-nhRG8+RuG/L+0fAZBQYaRflXKjTrHOKH8MFTChnf+dNVMxA3wHYYrfj0tztK0W51ABXjGfRCDc0vRkecCOrsow==", "dev": true, "requires": { - "@types/node": "13.9.5" + "@types/node": "*" } }, "@types/tough-cookie": { @@ -214,8 +214,8 @@ "integrity": "sha512-2o6a2ixaVI2EbwBPg1QYLGQoHK56p/8X/sGfKbFC8N6sY9lfjsMf/GprtkQkSya0D4uRiutRZ2BWj7k3JvLsAQ==", "dev": true, "requires": { - "@types/expect": "1.20.4", - "@types/node": "13.9.5" + "@types/expect": "^1.20.4", + "@types/node": "*" } }, "@wdio/config": { @@ -224,8 +224,8 @@ "integrity": "sha512-i5dJQWb80darcRA//tfG0guMeQCeRUXroZNnHjGNb1qzvTRZmcIIhdxaD+DbK/5dWEx6aoMfoi6wjVp/CXwdAg==", "requires": { "@wdio/logger": "5.16.10", - "deepmerge": "4.2.2", - "glob": "7.1.6" + "deepmerge": "^4.0.0", + "glob": "^7.1.2" } }, "@wdio/logger": { @@ -233,10 +233,10 @@ "resolved": "https://registry.npmjs.org/@wdio/logger/-/logger-5.16.10.tgz", "integrity": "sha512-hRKhxgd9uB48Dtj2xe2ckxU4KwI/RO8IwguySuaI2SLFj6EDbdonwzpVkq111/fjBuq7R1NauAaNcm3AMEbIFA==", "requires": { - "chalk": "3.0.0", - "loglevel": "1.6.7", - "loglevel-plugin-prefix": "0.8.4", - "strip-ansi": "6.0.0" + "chalk": "^3.0.0", + "loglevel": "^1.6.0", + "loglevel-plugin-prefix": "^0.8.4", + "strip-ansi": "^6.0.0" } }, "@wdio/protocols": { @@ -258,7 +258,7 @@ "integrity": "sha512-OVdK7P9Gne9tR6dl1GEKucwX4mtS47F26g4lH8r0HURvMegZLGtcchI1cqF6hjK7EpP737b+C3q4ooZSBdH9XQ==", "requires": { "@wdio/logger": "5.16.10", - "deepmerge": "4.2.2" + "deepmerge": "^4.0.0" } }, "abbrev": { @@ -273,7 +273,7 @@ "integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", "dev": true, "requires": { - "mime-types": "2.1.26", + "mime-types": "~2.1.24", "negotiator": "0.6.2" } }, @@ -294,10 +294,10 @@ "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.0.tgz", "integrity": "sha512-D6gFiFA0RRLyUbvijN74DWAjXSFxWKaWP7mldxkVhyhAV3+SWA9HEJPHQ2c9soIeTFJqcSdFDGFgdqs1iUU2Hw==", "requires": { - "fast-deep-equal": "3.1.1", - "fast-json-stable-stringify": "2.1.0", - "json-schema-traverse": "0.4.1", - "uri-js": "4.2.2" + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" }, "dependencies": { "fast-deep-equal": { @@ -319,7 +319,7 @@ "integrity": "sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA==", "dev": true, "requires": { - "ansi-wrap": "0.1.0" + "ansi-wrap": "^0.1.0" } }, "ansi-cyan": { @@ -359,8 +359,8 @@ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", "requires": { - "@types/color-name": "1.1.1", - "color-convert": "2.0.1" + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" } }, "ansi-wrap": { @@ -381,8 +381,8 @@ "integrity": "sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw==", "dev": true, "requires": { - "micromatch": "3.1.10", - "normalize-path": "2.1.1" + "micromatch": "^3.1.4", + "normalize-path": "^2.1.1" }, "dependencies": { "normalize-path": { @@ -391,7 +391,7 @@ "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", "dev": true, "requires": { - "remove-trailing-separator": "1.1.0" + "remove-trailing-separator": "^1.0.1" } } } @@ -402,7 +402,7 @@ "integrity": "sha1-2CIM9GYIFSXv6lBhTz3mUU36WPE=", "dev": true, "requires": { - "buffer-equal": "1.0.0" + "buffer-equal": "^1.0.0" } }, "aproba": { @@ -425,7 +425,7 @@ "dev": true, "optional": true, "requires": { - "file-type": "4.4.0" + "file-type": "^4.2.0" }, "dependencies": { "file-type": { @@ -442,13 +442,13 @@ "resolved": "https://registry.npmjs.org/archiver/-/archiver-3.1.1.tgz", "integrity": "sha512-5Hxxcig7gw5Jod/8Gq0OneVgLYET+oNHcxgWItq4TbhOzRLKNAFUb9edAftiMKXvXfCB0vbGrJdZDNq0dWMsxg==", "requires": { - "archiver-utils": "2.1.0", - "async": "2.6.3", - "buffer-crc32": "0.2.13", - "glob": "7.1.6", - "readable-stream": "3.6.0", - "tar-stream": "2.1.2", - "zip-stream": "2.1.3" + "archiver-utils": "^2.1.0", + "async": "^2.6.3", + "buffer-crc32": "^0.2.1", + "glob": "^7.1.4", + "readable-stream": "^3.4.0", + "tar-stream": "^2.1.0", + "zip-stream": "^2.1.2" } }, "archiver-utils": { @@ -456,16 +456,16 @@ "resolved": "https://registry.npmjs.org/archiver-utils/-/archiver-utils-2.1.0.tgz", "integrity": "sha512-bEL/yUb/fNNiNTuUz979Z0Yg5L+LzLxGJz8x79lYmR54fmTIb6ob/hNQgkQnIUDWIFjZVQwl9Xs356I6BAMHfw==", "requires": { - "glob": "7.1.6", - "graceful-fs": "4.2.3", - "lazystream": "1.0.0", - "lodash.defaults": "4.2.0", - "lodash.difference": "4.5.0", - "lodash.flatten": "4.4.0", - "lodash.isplainobject": "4.0.6", - "lodash.union": "4.6.0", - "normalize-path": "3.0.0", - "readable-stream": "2.3.7" + "glob": "^7.1.4", + "graceful-fs": "^4.2.0", + "lazystream": "^1.0.0", + "lodash.defaults": "^4.2.0", + "lodash.difference": "^4.5.0", + "lodash.flatten": "^4.4.0", + "lodash.isplainobject": "^4.0.6", + "lodash.union": "^4.6.0", + "normalize-path": "^3.0.0", + "readable-stream": "^2.0.0" }, "dependencies": { "readable-stream": { @@ -473,13 +473,13 @@ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -496,8 +496,8 @@ "integrity": "sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w==", "dev": true, "requires": { - "delegates": "1.0.0", - "readable-stream": "2.3.7" + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" }, "dependencies": { "readable-stream": { @@ -506,13 +506,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -523,7 +523,7 @@ "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", "dev": true, "requires": { - "sprintf-js": "1.0.3" + "sprintf-js": "~1.0.2" } }, "arr-diff": { @@ -574,7 +574,7 @@ "integrity": "sha1-mjRBDk9OPaI96jdb5b5w8kd47Dk=", "dev": true, "requires": { - "array-uniq": "1.0.3" + "array-uniq": "^1.0.1" } }, "array-uniq": { @@ -606,7 +606,7 @@ "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", "requires": { - "safer-buffer": "2.1.2" + "safer-buffer": "~2.1.0" } }, "assert-plus": { @@ -625,7 +625,7 @@ "resolved": "https://registry.npmjs.org/async/-/async-2.6.3.tgz", "integrity": "sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg==", "requires": { - "lodash": "4.17.15" + "lodash": "^4.17.14" } }, "async-each": { @@ -669,13 +669,13 @@ "integrity": "sha512-URo6Zvt7VYifomeAfJlMFnYDhow1rk2bufwkbamPEAtQFcL11moLk4PnR7n9vlu7M+BkXAZkHFA0mIcY7tjQFg==", "dev": true, "requires": { - "browserslist": "4.11.0", - "caniuse-lite": "1.0.30001038", - "chalk": "2.4.2", - "normalize-range": "0.1.2", - "num2fraction": "1.2.2", - "postcss": "7.0.27", - "postcss-value-parser": "4.0.3" + "browserslist": "^4.11.0", + "caniuse-lite": "^1.0.30001036", + "chalk": "^2.4.2", + "normalize-range": "^0.1.2", + "num2fraction": "^1.2.2", + "postcss": "^7.0.27", + "postcss-value-parser": "^4.0.3" }, "dependencies": { "ansi-styles": { @@ -684,7 +684,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -693,9 +693,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -725,7 +725,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -747,7 +747,7 @@ "dev": true, "requires": { "follow-redirects": "1.5.10", - "is-buffer": "2.0.4" + "is-buffer": "^2.0.2" }, "dependencies": { "is-buffer": { @@ -763,7 +763,7 @@ "resolved": "https://registry.npmjs.org/babel-extract-comments/-/babel-extract-comments-1.0.0.tgz", "integrity": "sha512-qWWzi4TlddohA91bFwgt6zO/J0X+io7Qp184Fw0m2JYRSTZnJbFR8+07KmzudHCZgOiKRCrjhylwv9Xd8gfhVQ==", "requires": { - "babylon": "6.18.0" + "babylon": "^6.18.0" } }, "babel-plugin-syntax-object-rest-spread": { @@ -776,8 +776,8 @@ "resolved": "https://registry.npmjs.org/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz", "integrity": "sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY=", "requires": { - "babel-plugin-syntax-object-rest-spread": "6.13.0", - "babel-runtime": "6.26.0" + "babel-plugin-syntax-object-rest-spread": "^6.8.0", + "babel-runtime": "^6.26.0" } }, "babel-runtime": { @@ -785,8 +785,8 @@ "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz", "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=", "requires": { - "core-js": "2.6.11", - "regenerator-runtime": "0.11.1" + "core-js": "^2.4.0", + "regenerator-runtime": "^0.11.0" }, "dependencies": { "regenerator-runtime": { @@ -818,13 +818,13 @@ "integrity": "sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==", "dev": true, "requires": { - "cache-base": "1.0.1", - "class-utils": "0.3.6", - "component-emitter": "1.2.1", - "define-property": "1.0.0", - "isobject": "3.0.1", - "mixin-deep": "1.3.2", - "pascalcase": "0.1.1" + "cache-base": "^1.0.1", + "class-utils": "^0.3.5", + "component-emitter": "^1.2.1", + "define-property": "^1.0.0", + "isobject": "^3.0.1", + "mixin-deep": "^1.2.0", + "pascalcase": "^0.1.1" }, "dependencies": { "define-property": { @@ -833,7 +833,7 @@ "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", "dev": true, "requires": { - "is-descriptor": "1.0.2" + "is-descriptor": "^1.0.0" } }, "is-accessor-descriptor": { @@ -842,7 +842,7 @@ "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.0" } }, "is-data-descriptor": { @@ -851,7 +851,7 @@ "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.0" } }, "is-descriptor": { @@ -860,9 +860,9 @@ "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, "requires": { - "is-accessor-descriptor": "1.0.0", - "is-data-descriptor": "1.0.0", - "kind-of": "6.0.3" + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" } } } @@ -895,7 +895,7 @@ "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", "requires": { - "tweetnacl": "0.14.5" + "tweetnacl": "^0.14.3" } }, "beeper": { @@ -920,11 +920,11 @@ "dev": true, "optional": true, "requires": { - "decompress": "4.2.0", - "download": "6.2.5", - "execa": "0.7.0", - "p-map-series": "1.0.0", - "tempfile": "2.0.0" + "decompress": "^4.0.0", + "download": "^6.2.2", + "execa": "^0.7.0", + "p-map-series": "^1.0.0", + "tempfile": "^2.0.0" } }, "bin-check": { @@ -934,8 +934,8 @@ "dev": true, "optional": true, "requires": { - "execa": "0.7.0", - "executable": "4.1.1" + "execa": "^0.7.0", + "executable": "^4.1.0" } }, "bin-version": { @@ -945,8 +945,8 @@ "dev": true, "optional": true, "requires": { - "execa": "1.0.0", - "find-versions": "3.2.0" + "execa": "^1.0.0", + "find-versions": "^3.0.0" }, "dependencies": { "cross-spawn": { @@ -956,11 +956,11 @@ "dev": true, "optional": true, "requires": { - "nice-try": "1.0.5", - "path-key": "2.0.1", - "semver": "5.7.1", - "shebang-command": "1.2.0", - "which": "1.3.1" + "nice-try": "^1.0.4", + "path-key": "^2.0.1", + "semver": "^5.5.0", + "shebang-command": "^1.2.0", + "which": "^1.2.9" } }, "execa": { @@ -970,13 +970,13 @@ "dev": true, "optional": true, "requires": { - "cross-spawn": "6.0.5", - "get-stream": "4.1.0", - "is-stream": "1.1.0", - "npm-run-path": "2.0.2", - "p-finally": "1.0.0", - "signal-exit": "3.0.3", - "strip-eof": "1.0.0" + "cross-spawn": "^6.0.0", + "get-stream": "^4.0.0", + "is-stream": "^1.1.0", + "npm-run-path": "^2.0.0", + "p-finally": "^1.0.0", + "signal-exit": "^3.0.0", + "strip-eof": "^1.0.0" } }, "get-stream": { @@ -986,7 +986,7 @@ "dev": true, "optional": true, "requires": { - "pump": "3.0.0" + "pump": "^3.0.0" } } } @@ -998,9 +998,9 @@ "dev": true, "optional": true, "requires": { - "bin-version": "3.1.0", - "semver": "5.7.1", - "semver-truncate": "1.1.2" + "bin-version": "^3.0.0", + "semver": "^5.6.0", + "semver-truncate": "^1.1.2" } }, "bin-wrapper": { @@ -1010,12 +1010,12 @@ "dev": true, "optional": true, "requires": { - "bin-check": "4.1.0", - "bin-version-check": "4.0.0", - "download": "7.1.0", - "import-lazy": "3.1.0", - "os-filter-obj": "2.0.0", - "pify": "4.0.1" + "bin-check": "^4.1.0", + "bin-version-check": "^4.0.0", + "download": "^7.1.0", + "import-lazy": "^3.1.0", + "os-filter-obj": "^2.0.0", + "pify": "^4.0.1" }, "dependencies": { "download": { @@ -1025,18 +1025,18 @@ "dev": true, "optional": true, "requires": { - "archive-type": "4.0.0", - "caw": "2.0.1", - "content-disposition": "0.5.3", - "decompress": "4.2.0", - "ext-name": "5.0.0", - "file-type": "8.1.0", - "filenamify": "2.1.0", - "get-stream": "3.0.0", - "got": "8.3.2", - "make-dir": "1.3.0", - "p-event": "2.3.1", - "pify": "3.0.0" + "archive-type": "^4.0.0", + "caw": "^2.0.1", + "content-disposition": "^0.5.2", + "decompress": "^4.2.0", + "ext-name": "^5.0.0", + "file-type": "^8.1.0", + "filenamify": "^2.0.0", + "get-stream": "^3.0.0", + "got": "^8.3.1", + "make-dir": "^1.2.0", + "p-event": "^2.1.0", + "pify": "^3.0.0" }, "dependencies": { "pify": { @@ -1062,23 +1062,23 @@ "dev": true, "optional": true, "requires": { - "@sindresorhus/is": "0.7.0", - "cacheable-request": "2.1.4", - "decompress-response": "3.3.0", - "duplexer3": "0.1.4", - "get-stream": "3.0.0", - "into-stream": "3.1.0", - "is-retry-allowed": "1.2.0", - "isurl": "1.0.0", - "lowercase-keys": "1.0.1", - "mimic-response": "1.0.1", - "p-cancelable": "0.4.1", - "p-timeout": "2.0.1", - "pify": "3.0.0", - "safe-buffer": "5.1.2", - "timed-out": "4.0.1", - "url-parse-lax": "3.0.0", - "url-to-options": "1.0.1" + "@sindresorhus/is": "^0.7.0", + "cacheable-request": "^2.1.1", + "decompress-response": "^3.3.0", + "duplexer3": "^0.1.4", + "get-stream": "^3.0.0", + "into-stream": "^3.1.0", + "is-retry-allowed": "^1.1.0", + "isurl": "^1.0.0-alpha5", + "lowercase-keys": "^1.0.0", + "mimic-response": "^1.0.0", + "p-cancelable": "^0.4.0", + "p-timeout": "^2.0.1", + "pify": "^3.0.0", + "safe-buffer": "^5.1.1", + "timed-out": "^4.0.1", + "url-parse-lax": "^3.0.0", + "url-to-options": "^1.0.1" }, "dependencies": { "pify": { @@ -1104,7 +1104,7 @@ "dev": true, "optional": true, "requires": { - "p-timeout": "2.0.1" + "p-timeout": "^2.0.1" } }, "p-timeout": { @@ -1113,7 +1113,7 @@ "integrity": "sha512-88em58dDVB/KzPEx1X0N3LwFfYZPyDc4B6eF38M1rk9VTZMbxXXgjugz8mmwpS9Ox4BDZ+t6t3QP5+/gazweIA==", "dev": true, "requires": { - "p-finally": "1.0.0" + "p-finally": "^1.0.0" } }, "pify": { @@ -1137,7 +1137,7 @@ "dev": true, "optional": true, "requires": { - "prepend-http": "2.0.0" + "prepend-http": "^2.0.0" } } } @@ -1163,9 +1163,9 @@ "resolved": "https://registry.npmjs.org/bl/-/bl-4.0.2.tgz", "integrity": "sha512-j4OH8f6Qg2bGuWfRiltT2HYGx0e1QcBTrK9KAHNMwMZdQnDZFk0ZSYIpADjYCB3U12nicC5tVJwSIhwOWjb4RQ==", "requires": { - "buffer": "5.5.0", - "inherits": "2.0.4", - "readable-stream": "3.6.0" + "buffer": "^5.5.0", + "inherits": "^2.0.4", + "readable-stream": "^3.4.0" } }, "blob": { @@ -1180,7 +1180,7 @@ "integrity": "sha1-E+v+d4oDIFz+A3UUgeu0szAMEmo=", "dev": true, "requires": { - "inherits": "2.0.4" + "inherits": "~2.0.0" } }, "bluebird": { @@ -1201,11 +1201,11 @@ "integrity": "sha1-hf2d82fCuNu9DKpMXyutQM2Ewsw=", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "mout": "1.2.2", - "optimist": "0.6.1", - "osenv": "0.1.5", - "untildify": "2.1.0" + "graceful-fs": "^4.1.3", + "mout": "^1.0.0", + "optimist": "^0.6.1", + "osenv": "^0.1.3", + "untildify": "^2.1.0" } }, "brace-expansion": { @@ -1213,7 +1213,7 @@ "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "requires": { - "balanced-match": "1.0.0", + "balanced-match": "^1.0.0", "concat-map": "0.0.1" } }, @@ -1223,16 +1223,16 @@ "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", "dev": true, "requires": { - "arr-flatten": "1.1.0", - "array-unique": "0.3.2", - "extend-shallow": "2.0.1", - "fill-range": "4.0.0", - "isobject": "3.0.1", - "repeat-element": "1.1.3", - "snapdragon": "0.8.2", - "snapdragon-node": "2.1.1", - "split-string": "3.1.0", - "to-regex": "3.0.2" + "arr-flatten": "^1.1.0", + "array-unique": "^0.3.2", + "extend-shallow": "^2.0.1", + "fill-range": "^4.0.0", + "isobject": "^3.0.1", + "repeat-element": "^1.1.2", + "snapdragon": "^0.8.1", + "snapdragon-node": "^2.0.1", + "split-string": "^3.0.2", + "to-regex": "^3.0.1" }, "dependencies": { "extend-shallow": { @@ -1241,7 +1241,7 @@ "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, "requires": { - "is-extendable": "0.1.1" + "is-extendable": "^0.1.0" } } } @@ -1258,27 +1258,27 @@ "integrity": "sha512-lY3emme0OyvA2ujEMpRmyRy9LY6gHLuTr2/ABxhIm3lADOiRXzP4dgekvnDrQqZ/Ec2Fz19lEjm6kglSG5766w==", "dev": true, "requires": { - "browser-sync-client": "2.26.6", - "browser-sync-ui": "2.26.4", + "browser-sync-client": "^2.26.6", + "browser-sync-ui": "^2.26.4", "bs-recipes": "1.3.4", - "bs-snippet-injector": "2.0.1", - "chokidar": "2.1.8", + "bs-snippet-injector": "^2.0.1", + "chokidar": "^2.0.4", "connect": "3.6.6", - "connect-history-api-fallback": "1.6.0", - "dev-ip": "1.0.1", - "easy-extender": "2.3.4", - "eazy-logger": "3.0.2", - "etag": "1.8.1", - "fresh": "0.5.2", + "connect-history-api-fallback": "^1", + "dev-ip": "^1.0.1", + "easy-extender": "^2.3.4", + "eazy-logger": "^3", + "etag": "^1.8.1", + "fresh": "^0.5.2", "fs-extra": "3.0.1", "http-proxy": "1.15.2", - "immutable": "3.8.2", + "immutable": "^3", "localtunnel": "1.9.2", - "micromatch": "3.1.10", + "micromatch": "^3.1.10", "opn": "5.3.0", "portscanner": "2.1.1", "qs": "6.2.3", - "raw-body": "2.4.1", + "raw-body": "^2.3.2", "resp-modifier": "6.0.2", "rx": "4.1.0", "send": "0.16.2", @@ -1296,9 +1296,9 @@ "integrity": "sha1-N5TzeMWLNC6n27sjCVEJxLO2IpE=", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "jsonfile": "3.0.1", - "universalify": "0.1.2" + "graceful-fs": "^4.1.2", + "jsonfile": "^3.0.0", + "universalify": "^0.1.0" } }, "jsonfile": { @@ -1307,7 +1307,7 @@ "integrity": "sha1-pezG9l9T9mLEQVx2daAzHQmS7GY=", "dev": true, "requires": { - "graceful-fs": "4.2.3" + "graceful-fs": "^4.1.6" } }, "qs": { @@ -1326,8 +1326,8 @@ "requires": { "etag": "1.8.1", "fresh": "0.5.2", - "mitt": "1.2.0", - "rxjs": "5.5.12" + "mitt": "^1.1.3", + "rxjs": "^5.5.6" } }, "browser-sync-ui": { @@ -1337,11 +1337,11 @@ "dev": true, "requires": { "async-each-series": "0.1.1", - "connect-history-api-fallback": "1.6.0", - "immutable": "3.8.2", + "connect-history-api-fallback": "^1", + "immutable": "^3", "server-destroy": "1.0.1", - "socket.io-client": "2.3.0", - "stream-throttle": "0.1.3" + "socket.io-client": "^2.0.4", + "stream-throttle": "^0.1.3" } }, "browserslist": { @@ -1350,10 +1350,10 @@ "integrity": "sha512-WqEC7Yr5wUH5sg6ruR++v2SGOQYpyUdYYd4tZoAq1F7y+QXoLoYGXVbxhtaIqWmAJjtNTRjVD3HuJc1OXTel2A==", "dev": true, "requires": { - "caniuse-lite": "1.0.30001038", - "electron-to-chromium": "1.3.390", - "node-releases": "1.1.53", - "pkg-up": "3.1.0" + "caniuse-lite": "^1.0.30001035", + "electron-to-chromium": "^1.3.380", + "node-releases": "^1.1.52", + "pkg-up": "^3.1.0" } }, "browserstack-local": { @@ -1362,10 +1362,10 @@ "integrity": "sha512-0/VdSv2YVXmcnwBb64XThMvjM1HnZJnPdv7CUgQbC5y/N9Wsr0Fu+j1oknE9fC/VPx9CpoSC6CJ0kza42skMSA==", "dev": true, "requires": { - "https-proxy-agent": "4.0.0", - "is-running": "2.1.0", - "ps-tree": "1.2.0", - "temp-fs": "0.9.9" + "https-proxy-agent": "^4.0.0", + "is-running": "^2.1.0", + "ps-tree": "=1.2.0", + "temp-fs": "^0.9.9" } }, "bs-recipes": { @@ -1385,8 +1385,8 @@ "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.5.0.tgz", "integrity": "sha512-9FTEDjLjwoAkEwyMGDjYJQN2gfRgOKBKRfiglhvibGbpeeU/pQn1bJxQqm32OD/AIeEuHxU9roxXxg34Byp/Ww==", "requires": { - "base64-js": "1.3.1", - "ieee754": "1.1.13" + "base64-js": "^1.0.2", + "ieee754": "^1.1.4" } }, "buffer-alloc": { @@ -1395,8 +1395,8 @@ "integrity": "sha512-CFsHQgjtW1UChdXgbyJGtnm+O/uLQeZdtbDo8mfUgYXCHSM1wgrVxXm6bSyrUuErEb+4sYVGCzASBRot7zyrow==", "dev": true, "requires": { - "buffer-alloc-unsafe": "1.1.0", - "buffer-fill": "1.0.0" + "buffer-alloc-unsafe": "^1.1.0", + "buffer-fill": "^1.0.0" } }, "buffer-alloc-unsafe": { @@ -1434,7 +1434,7 @@ "integrity": "sha1-z7GtlWjTujz+k1upq92VLeiKqyo=", "dev": true, "requires": { - "readable-stream": "1.1.14" + "readable-stream": "^1.0.33" }, "dependencies": { "isarray": { @@ -1449,10 +1449,10 @@ "integrity": "sha1-fPTFTvZI44EwhMY23SB54WbAgdk=", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", "isarray": "0.0.1", - "string_decoder": "0.10.31" + "string_decoder": "~0.10.x" } }, "string_decoder": { @@ -1475,15 +1475,15 @@ "integrity": "sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ==", "dev": true, "requires": { - "collection-visit": "1.0.0", - "component-emitter": "1.2.1", - "get-value": "2.0.6", - "has-value": "1.0.0", - "isobject": "3.0.1", - "set-value": "2.0.1", - "to-object-path": "0.3.0", - "union-value": "1.0.1", - "unset-value": "1.0.0" + "collection-visit": "^1.0.0", + "component-emitter": "^1.2.1", + "get-value": "^2.0.6", + "has-value": "^1.0.0", + "isobject": "^3.0.1", + "set-value": "^2.0.0", + "to-object-path": "^0.3.0", + "union-value": "^1.0.0", + "unset-value": "^1.0.0" } }, "cache-swap": { @@ -1492,10 +1492,10 @@ "integrity": "sha1-HFQaoQilAQb2ML3Zj+HeyLoTP1E=", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "mkdirp": "0.5.4", - "object-assign": "4.1.1", - "rimraf": "2.7.1" + "graceful-fs": "^4.1.2", + "mkdirp": "^0.5.1", + "object-assign": "^4.0.1", + "rimraf": "^2.4.0" } }, "cacheable-request": { @@ -1541,8 +1541,8 @@ "integrity": "sha1-yjw2iKTpzzpM2nd9xNy8cTJJz3M=", "dev": true, "requires": { - "no-case": "2.3.2", - "upper-case": "1.1.3" + "no-case": "^2.2.0", + "upper-case": "^1.1.1" } }, "camelcase": { @@ -1557,8 +1557,8 @@ "integrity": "sha1-MIvur/3ygRkFHvodkyITyRuPkuc=", "dev": true, "requires": { - "camelcase": "2.1.1", - "map-obj": "1.0.1" + "camelcase": "^2.0.0", + "map-obj": "^1.0.0" }, "dependencies": { "camelcase": { @@ -1586,10 +1586,10 @@ "integrity": "sha512-Cg8/ZSBEa8ZVY9HspcGUYaK63d/bN7rqS3CYCzEGUxuYv6UlmcjzDUz2fCFFHyTvUW5Pk0I+3hkA3iXlIj6guA==", "dev": true, "requires": { - "get-proxy": "2.1.0", - "isurl": "1.0.0", - "tunnel-agent": "0.6.0", - "url-to-options": "1.0.1" + "get-proxy": "^2.0.0", + "isurl": "^1.0.0-alpha5", + "tunnel-agent": "^0.6.0", + "url-to-options": "^1.0.1" } }, "chalk": { @@ -1597,8 +1597,8 @@ "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", "requires": { - "ansi-styles": "4.2.1", - "supports-color": "7.1.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, "chance": { @@ -1613,22 +1613,22 @@ "integrity": "sha1-qbqoYKP5tZWmuBsahocxIe06Jp4=", "dev": true, "requires": { - "css-select": "1.2.0", - "dom-serializer": "0.1.1", - "entities": "1.1.2", - "htmlparser2": "3.10.1", - "lodash.assignin": "4.2.0", - "lodash.bind": "4.2.1", - "lodash.defaults": "4.2.0", - "lodash.filter": "4.6.0", - "lodash.flatten": "4.4.0", - "lodash.foreach": "4.5.0", - "lodash.map": "4.6.0", - "lodash.merge": "4.6.2", - "lodash.pick": "4.4.0", - "lodash.reduce": "4.6.0", - "lodash.reject": "4.6.0", - "lodash.some": "4.6.0" + "css-select": "~1.2.0", + "dom-serializer": "~0.1.0", + "entities": "~1.1.1", + "htmlparser2": "^3.9.1", + "lodash.assignin": "^4.0.9", + "lodash.bind": "^4.1.4", + "lodash.defaults": "^4.0.1", + "lodash.filter": "^4.4.0", + "lodash.flatten": "^4.2.0", + "lodash.foreach": "^4.3.0", + "lodash.map": "^4.4.0", + "lodash.merge": "^4.4.0", + "lodash.pick": "^4.2.1", + "lodash.reduce": "^4.4.0", + "lodash.reject": "^4.4.0", + "lodash.some": "^4.4.0" }, "dependencies": { "css-select": { @@ -1637,10 +1637,10 @@ "integrity": "sha1-KzoRBTnFNV8c2NMUYj6HCxIeyFg=", "dev": true, "requires": { - "boolbase": "1.0.0", - "css-what": "2.1.3", + "boolbase": "~1.0.0", + "css-what": "2.1", "domutils": "1.5.1", - "nth-check": "1.0.2" + "nth-check": "~1.0.1" } }, "css-what": { @@ -1655,8 +1655,8 @@ "integrity": "sha512-l0IU0pPzLWSHBcieZbpOKgkIn3ts3vAh7ZuFyXNwJxJXk/c4Gwj9xaTJwIDVQCXawWD0qb3IzMGH5rglQaO0XA==", "dev": true, "requires": { - "domelementtype": "1.3.1", - "entities": "1.1.2" + "domelementtype": "^1.3.0", + "entities": "^1.1.1" } }, "domutils": { @@ -1665,8 +1665,8 @@ "integrity": "sha1-3NhIiib1Y9YQeeSMn3t+Mjc2gs8=", "dev": true, "requires": { - "dom-serializer": "0.1.1", - "domelementtype": "1.3.1" + "dom-serializer": "0", + "domelementtype": "1" } }, "entities": { @@ -1683,18 +1683,18 @@ "integrity": "sha512-ZmZUazfOzf0Nve7duiCKD23PFSCs4JPoYyccjUFF3aQkQadqBhfzhjkwBH2mNOG9cTBwhamM37EIsIkZw3nRgg==", "dev": true, "requires": { - "anymatch": "2.0.0", - "async-each": "1.0.3", - "braces": "2.3.2", - "fsevents": "1.2.12", - "glob-parent": "3.1.0", - "inherits": "2.0.4", - "is-binary-path": "1.0.1", - "is-glob": "4.0.1", - "normalize-path": "3.0.0", - "path-is-absolute": "1.0.1", - "readdirp": "2.2.1", - "upath": "1.2.0" + "anymatch": "^2.0.0", + "async-each": "^1.0.1", + "braces": "^2.3.2", + "fsevents": "^1.2.7", + "glob-parent": "^3.1.0", + "inherits": "^2.0.3", + "is-binary-path": "^1.0.0", + "is-glob": "^4.0.0", + "normalize-path": "^3.0.0", + "path-is-absolute": "^1.0.0", + "readdirp": "^2.2.1", + "upath": "^1.1.1" } }, "class-utils": { @@ -1703,10 +1703,10 @@ "integrity": "sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg==", "dev": true, "requires": { - "arr-union": "3.1.0", - "define-property": "0.2.5", - "isobject": "3.0.1", - "static-extend": "0.1.2" + "arr-union": "^3.1.0", + "define-property": "^0.2.5", + "isobject": "^3.0.0", + "static-extend": "^0.1.1" }, "dependencies": { "define-property": { @@ -1715,7 +1715,7 @@ "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, "requires": { - "is-descriptor": "0.1.6" + "is-descriptor": "^0.1.0" } } } @@ -1726,7 +1726,7 @@ "integrity": "sha512-VcMWDN54ZN/DS+g58HYL5/n4Zrqe8vHJpGA8KdgUXFU4fuP/aHNw8eld9SyEIyabIMJX/0RaY/fplOo5hYLSFA==", "dev": true, "requires": { - "source-map": "0.6.1" + "source-map": "~0.6.0" }, "dependencies": { "source-map": { @@ -1743,9 +1743,9 @@ "integrity": "sha1-EgYBU3qRbSmUD5NNo7SNWFo5IT0=", "dev": true, "requires": { - "string-width": "1.0.2", - "strip-ansi": "3.0.1", - "wrap-ansi": "2.1.0" + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wrap-ansi": "^2.0.0" }, "dependencies": { "ansi-regex": { @@ -1760,7 +1760,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } } } @@ -1784,7 +1784,7 @@ "dev": true, "optional": true, "requires": { - "mimic-response": "1.0.1" + "mimic-response": "^1.0.0" } }, "clone-stats": { @@ -1799,9 +1799,9 @@ "integrity": "sha512-2EF8zTQOxYq70Y4XKtorQupqF0m49MBz2/yf5Bj+MHjvpG3Hy7sImifnqD6UA+TKYxeSV+u6qqQPawN5UvnpKQ==", "dev": true, "requires": { - "inherits": "2.0.4", - "process-nextick-args": "2.0.1", - "readable-stream": "2.3.7" + "inherits": "^2.0.1", + "process-nextick-args": "^2.0.0", + "readable-stream": "^2.3.5" }, "dependencies": { "readable-stream": { @@ -1810,13 +1810,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -1827,9 +1827,9 @@ "integrity": "sha512-q5/jG+YQnSy4nRTV4F7lPepBJZ8qBNJJDBuJdoejDyLXgmL7IEo+Le2JDZudFTFt7mrCqIRaSjws4ygRCTCAXA==", "dev": true, "requires": { - "@types/q": "1.5.2", - "chalk": "2.4.2", - "q": "1.5.1" + "@types/q": "^1.5.1", + "chalk": "^2.4.1", + "q": "^1.1.2" }, "dependencies": { "ansi-styles": { @@ -1838,7 +1838,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -1847,9 +1847,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -1879,7 +1879,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -1896,8 +1896,8 @@ "integrity": "sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA=", "dev": true, "requires": { - "map-visit": "1.0.0", - "object-visit": "1.0.1" + "map-visit": "^1.0.0", + "object-visit": "^1.0.0" } }, "color-convert": { @@ -1905,7 +1905,7 @@ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "requires": { - "color-name": "1.1.4" + "color-name": "~1.1.4" } }, "color-name": { @@ -1924,7 +1924,7 @@ "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", "requires": { - "delayed-stream": "1.0.0" + "delayed-stream": "~1.0.0" } }, "commander": { @@ -1961,10 +1961,10 @@ "resolved": "https://registry.npmjs.org/compress-commons/-/compress-commons-2.1.1.tgz", "integrity": "sha512-eVw6n7CnEMFzc3duyFVrQEuY1BlHR3rYsSztyG32ibGMW722i3C6IizEGMFmfMU+A+fALvBIwxN3czffTcdA+Q==", "requires": { - "buffer-crc32": "0.2.13", - "crc32-stream": "3.0.1", - "normalize-path": "3.0.0", - "readable-stream": "2.3.7" + "buffer-crc32": "^0.2.13", + "crc32-stream": "^3.0.1", + "normalize-path": "^3.0.0", + "readable-stream": "^2.3.6" }, "dependencies": { "readable-stream": { @@ -1972,13 +1972,13 @@ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -1994,7 +1994,7 @@ "integrity": "sha512-4gEjHJFT9e+2W/77h/DS5SGUgwDaOwprX8L/gl5+3ixnzkVJJsZWDSelmN3Oilw3LNDZjZV0yqH1hLG3k6nghg==", "dev": true, "requires": { - "source-map": "0.6.1" + "source-map": "^0.6.1" }, "dependencies": { "source-map": { @@ -2011,8 +2011,8 @@ "integrity": "sha512-a1eOIcu8+7lUInge4Rpf/n4Krkf3Dd9lqhljRzII1/Zno/kRtUWnznPO3jOKBmTEktkt3fkxisUcivoj0ebzoA==", "dev": true, "requires": { - "ini": "1.3.5", - "proto-list": "1.2.4" + "ini": "^1.3.4", + "proto-list": "~1.2.1" } }, "connect": { @@ -2023,7 +2023,7 @@ "requires": { "debug": "2.6.9", "finalhandler": "1.1.0", - "parseurl": "1.3.3", + "parseurl": "~1.3.2", "utils-merge": "1.0.1" }, "dependencies": { @@ -2078,7 +2078,7 @@ "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", "dev": true, "requires": { - "safe-buffer": "5.1.2" + "safe-buffer": "~5.1.1" } }, "cookie": { @@ -2108,7 +2108,7 @@ "resolved": "https://registry.npmjs.org/crc/-/crc-3.8.0.tgz", "integrity": "sha512-iX3mfgcTMIq3ZKLIsVFAbv7+Mc10kxabAGQb8HvjA1o3T1PIYprbakQ65d3I+2HGHt6nSKkM9PYjgoJO2KcFBQ==", "requires": { - "buffer": "5.5.0" + "buffer": "^5.1.0" } }, "crc32-stream": { @@ -2116,8 +2116,8 @@ "resolved": "https://registry.npmjs.org/crc32-stream/-/crc32-stream-3.0.1.tgz", "integrity": "sha512-mctvpXlbzsvK+6z8kJwSJ5crm7yBwrQMTybJzMw1O4lLGJqjlDCXY2Zw7KheiA6XBEcBmfLx1D88mjRGVJtY9w==", "requires": { - "crc": "3.8.0", - "readable-stream": "3.6.0" + "crc": "^3.4.4", + "readable-stream": "^3.4.0" } }, "cross-spawn": { @@ -2126,9 +2126,9 @@ "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", "dev": true, "requires": { - "path-key": "3.1.1", - "shebang-command": "2.0.0", - "which": "2.0.2" + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" }, "dependencies": { "path-key": { @@ -2143,7 +2143,7 @@ "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", "dev": true, "requires": { - "shebang-regex": "3.0.0" + "shebang-regex": "^3.0.0" } }, "shebang-regex": { @@ -2158,7 +2158,7 @@ "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", "dev": true, "requires": { - "isexe": "2.0.0" + "isexe": "^2.0.0" } } } @@ -2169,10 +2169,10 @@ "integrity": "sha512-Dqk7LQKpwLoH3VovzZnkzegqNSuAziQyNZUcrdDM401iY+R5NkGBXGmtO05/yaXQziALuPogeG0b7UAgjnTJTQ==", "dev": true, "requires": { - "boolbase": "1.0.0", - "css-what": "3.2.1", - "domutils": "1.7.0", - "nth-check": "1.0.2" + "boolbase": "^1.0.0", + "css-what": "^3.2.1", + "domutils": "^1.7.0", + "nth-check": "^1.0.2" } }, "css-select-base-adapter": { @@ -2188,7 +2188,7 @@ "dev": true, "requires": { "mdn-data": "2.0.4", - "source-map": "0.6.1" + "source-map": "^0.6.1" }, "dependencies": { "source-map": { @@ -2226,7 +2226,7 @@ "dev": true, "requires": { "mdn-data": "2.0.6", - "source-map": "0.6.1" + "source-map": "^0.6.1" } }, "mdn-data": { @@ -2255,7 +2255,7 @@ "integrity": "sha1-mI3zP+qxke95mmE2nddsF635V+o=", "dev": true, "requires": { - "array-find-index": "1.0.2" + "array-find-index": "^1.0.1" } }, "dashdash": { @@ -2263,7 +2263,7 @@ "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", "requires": { - "assert-plus": "1.0.0" + "assert-plus": "^1.0.0" } }, "dateformat": { @@ -2278,7 +2278,7 @@ "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", "dev": true, "requires": { - "ms": "2.1.2" + "ms": "^2.1.1" } }, "decamelize": { @@ -2299,14 +2299,14 @@ "integrity": "sha1-eu3YVCflqS2s/lVnSnxQXpbQH50=", "dev": true, "requires": { - "decompress-tar": "4.1.1", - "decompress-tarbz2": "4.1.1", - "decompress-targz": "4.1.1", - "decompress-unzip": "4.0.1", - "graceful-fs": "4.2.3", - "make-dir": "1.3.0", - "pify": "2.3.0", - "strip-dirs": "2.1.0" + "decompress-tar": "^4.0.0", + "decompress-tarbz2": "^4.0.0", + "decompress-targz": "^4.0.0", + "decompress-unzip": "^4.0.1", + "graceful-fs": "^4.1.10", + "make-dir": "^1.0.0", + "pify": "^2.3.0", + "strip-dirs": "^2.0.0" } }, "decompress-response": { @@ -2315,7 +2315,7 @@ "integrity": "sha1-gKTdMjdIOEv6JICDYirt7Jgq3/M=", "dev": true, "requires": { - "mimic-response": "1.0.1" + "mimic-response": "^1.0.0" } }, "decompress-tar": { @@ -2324,9 +2324,9 @@ "integrity": "sha512-JdJMaCrGpB5fESVyxwpCx4Jdj2AagLmv3y58Qy4GE6HMVjWz1FeVQk1Ct4Kye7PftcdOo/7U7UKzYBJgqnGeUQ==", "dev": true, "requires": { - "file-type": "5.2.0", - "is-stream": "1.1.0", - "tar-stream": "1.6.2" + "file-type": "^5.2.0", + "is-stream": "^1.1.0", + "tar-stream": "^1.5.2" }, "dependencies": { "bl": { @@ -2335,8 +2335,8 @@ "integrity": "sha512-e8tQYnZodmebYDWGH7KMRvtzKXaJHx3BbilrgZCfvyLUYdKpK1t5PSPmpkny/SgiTSCnjfLW7v5rlONXVFkQEA==", "dev": true, "requires": { - "readable-stream": "2.3.7", - "safe-buffer": "5.1.2" + "readable-stream": "^2.3.5", + "safe-buffer": "^5.1.1" } }, "file-type": { @@ -2351,13 +2351,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } }, "tar-stream": { @@ -2366,13 +2366,13 @@ "integrity": "sha512-rzS0heiNf8Xn7/mpdSVVSMAWAoy9bfb1WOTYC78Z0UQKeKa/CWS8FOq0lKGNa8DWKAn9gxjCvMLYc5PGXYlK2A==", "dev": true, "requires": { - "bl": "1.2.2", - "buffer-alloc": "1.2.0", - "end-of-stream": "1.4.4", - "fs-constants": "1.0.0", - "readable-stream": "2.3.7", - "to-buffer": "1.1.1", - "xtend": "4.0.2" + "bl": "^1.0.0", + "buffer-alloc": "^1.2.0", + "end-of-stream": "^1.0.0", + "fs-constants": "^1.0.0", + "readable-stream": "^2.3.0", + "to-buffer": "^1.1.1", + "xtend": "^4.0.0" } } } @@ -2383,11 +2383,11 @@ "integrity": "sha512-s88xLzf1r81ICXLAVQVzaN6ZmX4A6U4z2nMbOwobxkLoIIfjVMBg7TeguTUXkKeXni795B6y5rnvDw7rxhAq9A==", "dev": true, "requires": { - "decompress-tar": "4.1.1", - "file-type": "6.2.0", - "is-stream": "1.1.0", - "seek-bzip": "1.0.5", - "unbzip2-stream": "1.3.3" + "decompress-tar": "^4.1.0", + "file-type": "^6.1.0", + "is-stream": "^1.1.0", + "seek-bzip": "^1.0.5", + "unbzip2-stream": "^1.0.9" }, "dependencies": { "file-type": { @@ -2404,9 +2404,9 @@ "integrity": "sha512-4z81Znfr6chWnRDNfFNqLwPvm4db3WuZkqV+UgXQzSngG3CEKdBkw5jrv3axjjL96glyiiKjsxJG3X6WBZwX3w==", "dev": true, "requires": { - "decompress-tar": "4.1.1", - "file-type": "5.2.0", - "is-stream": "1.1.0" + "decompress-tar": "^4.1.1", + "file-type": "^5.2.0", + "is-stream": "^1.1.0" }, "dependencies": { "file-type": { @@ -2423,10 +2423,10 @@ "integrity": "sha1-3qrM39FK6vhVePczroIQ+bSEj2k=", "dev": true, "requires": { - "file-type": "3.9.0", - "get-stream": "2.3.1", - "pify": "2.3.0", - "yauzl": "2.10.0" + "file-type": "^3.8.0", + "get-stream": "^2.2.0", + "pify": "^2.3.0", + "yauzl": "^2.4.2" }, "dependencies": { "file-type": { @@ -2441,8 +2441,8 @@ "integrity": "sha1-Xzj5PzRgCWZu4BUKBUFn+Rvdld4=", "dev": true, "requires": { - "object-assign": "4.1.1", - "pinkie-promise": "2.0.1" + "object-assign": "^4.0.1", + "pinkie-promise": "^2.0.0" } } } @@ -2458,7 +2458,7 @@ "integrity": "sha1-xlYFHpgX2f8I7YgUd/P+QBnz730=", "dev": true, "requires": { - "clone": "1.0.4" + "clone": "^1.0.2" } }, "define-properties": { @@ -2467,7 +2467,7 @@ "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", "dev": true, "requires": { - "object-keys": "1.1.1" + "object-keys": "^1.0.12" } }, "define-property": { @@ -2476,8 +2476,8 @@ "integrity": "sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ==", "dev": true, "requires": { - "is-descriptor": "1.0.2", - "isobject": "3.0.1" + "is-descriptor": "^1.0.2", + "isobject": "^3.0.1" }, "dependencies": { "is-accessor-descriptor": { @@ -2486,7 +2486,7 @@ "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.0" } }, "is-data-descriptor": { @@ -2495,7 +2495,7 @@ "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.0" } }, "is-descriptor": { @@ -2504,9 +2504,9 @@ "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, "requires": { - "is-accessor-descriptor": "1.0.0", - "is-data-descriptor": "1.0.0", - "kind-of": "6.0.3" + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" } } } @@ -2517,13 +2517,13 @@ "integrity": "sha512-QwGuEUouP2kVwQenAsOof5Fv8K9t3D8Ca8NxcXKrIpEHjTXK5J2nXLdP+ALI1cgv8wj7KuwBhTwBkOZSJKM5XQ==", "dev": true, "requires": { - "@types/glob": "7.1.1", - "globby": "6.1.0", - "is-path-cwd": "2.2.0", - "is-path-in-cwd": "2.1.0", - "p-map": "2.1.0", - "pify": "4.0.1", - "rimraf": "2.7.1" + "@types/glob": "^7.1.1", + "globby": "^6.1.0", + "is-path-cwd": "^2.0.0", + "is-path-in-cwd": "^2.0.0", + "p-map": "^2.0.0", + "pify": "^4.0.1", + "rimraf": "^2.6.3" }, "dependencies": { "pify": { @@ -2593,8 +2593,8 @@ "integrity": "sha512-37qirFDz8cA5fimp9feo43fSuRo2gHwaIn6dXL8Ber1dGwUosDrGZeCCXq57WnIqE4aQ+u3eQZzsk1yOzhdwag==", "dev": true, "requires": { - "arrify": "1.0.1", - "path-type": "3.0.0" + "arrify": "^1.0.1", + "path-type": "^3.0.0" }, "dependencies": { "path-type": { @@ -2603,7 +2603,7 @@ "integrity": "sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg==", "dev": true, "requires": { - "pify": "3.0.0" + "pify": "^3.0.0" } }, "pify": { @@ -2620,8 +2620,8 @@ "integrity": "sha512-2/xPb3ORsQ42nHYiSunXkDjPLBaEj/xTwUO4B7XCZQTRk7EBtTOPaygh10YAAh2OI1Qrp6NWfpAhzswj0ydt9g==", "dev": true, "requires": { - "domelementtype": "2.0.1", - "entities": "2.0.0" + "domelementtype": "^2.0.1", + "entities": "^2.0.0" }, "dependencies": { "domelementtype": { @@ -2644,7 +2644,7 @@ "integrity": "sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA==", "dev": true, "requires": { - "domelementtype": "1.3.1" + "domelementtype": "1" } }, "domutils": { @@ -2653,8 +2653,8 @@ "integrity": "sha512-Lgd2XcJ/NjEw+7tFvfKxOzCYKZsdct5lczQ2ZaQY8Djz7pfAD3Gbp8ySJWtreII/vDlMVmxwa6pHmdxIYgttDg==", "dev": true, "requires": { - "dom-serializer": "0.2.2", - "domelementtype": "1.3.1" + "dom-serializer": "0", + "domelementtype": "1" } }, "download": { @@ -2664,17 +2664,17 @@ "dev": true, "optional": true, "requires": { - "caw": "2.0.1", - "content-disposition": "0.5.3", - "decompress": "4.2.0", - "ext-name": "5.0.0", + "caw": "^2.0.0", + "content-disposition": "^0.5.2", + "decompress": "^4.0.0", + "ext-name": "^5.0.0", "file-type": "5.2.0", - "filenamify": "2.1.0", - "get-stream": "3.0.0", - "got": "7.1.0", - "make-dir": "1.3.0", - "p-event": "1.3.0", - "pify": "3.0.0" + "filenamify": "^2.0.0", + "get-stream": "^3.0.0", + "got": "^7.0.0", + "make-dir": "^1.0.0", + "p-event": "^1.0.0", + "pify": "^3.0.0" }, "dependencies": { "file-type": { @@ -2705,7 +2705,7 @@ "integrity": "sha1-xhTc9n4vsUmVqRcR5aYX6KYKMds=", "dev": true, "requires": { - "readable-stream": "1.1.14" + "readable-stream": "~1.1.9" }, "dependencies": { "isarray": { @@ -2720,10 +2720,10 @@ "integrity": "sha1-fPTFTvZI44EwhMY23SB54WbAgdk=", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", "isarray": "0.0.1", - "string_decoder": "0.10.31" + "string_decoder": "~0.10.x" } }, "string_decoder": { @@ -2746,10 +2746,10 @@ "integrity": "sha512-07z8uv2wMyS51kKhD1KsdXJg5WQ6t93RneqRxUHnskXVtlYYkLqM0gqStQZ3pj073g687jPCHrqNfCzawLYh5g==", "dev": true, "requires": { - "end-of-stream": "1.4.4", - "inherits": "2.0.4", - "readable-stream": "2.3.7", - "stream-shift": "1.0.1" + "end-of-stream": "^1.0.0", + "inherits": "^2.0.1", + "readable-stream": "^2.0.0", + "stream-shift": "^1.0.0" }, "dependencies": { "readable-stream": { @@ -2758,13 +2758,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -2775,7 +2775,7 @@ "integrity": "sha512-8cAwm6md1YTiPpOvDULYJL4ZS6WfM5/cTeVVh4JsvyYZAoqlRVUpHL9Gr5Fy7HA6xcSZicUia3DeAgO3Us8E+Q==", "dev": true, "requires": { - "lodash": "4.17.15" + "lodash": "^4.17.10" } }, "eazy-logger": { @@ -2784,7 +2784,7 @@ "integrity": "sha1-oyWqXlPROiIliJsqxBE7K5Y29Pw=", "dev": true, "requires": { - "tfunk": "3.1.0" + "tfunk": "^3.0.1" } }, "ecc-jsbn": { @@ -2792,8 +2792,8 @@ "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=", "requires": { - "jsbn": "0.1.1", - "safer-buffer": "2.1.2" + "jsbn": "~0.1.0", + "safer-buffer": "^2.1.0" } }, "ee-first": { @@ -2814,17 +2814,17 @@ "integrity": "sha512-4VbIyCRlCUm/py0E0AjMT3/mwd6DR4Y5Z5gEox6z5JII6ZdKIJmcQzjgWRI5qo5ERJiw9M/Nxhk7SGXFUbZsxQ==", "dev": true, "requires": { - "chalk": "4.1.1", - "chokidar": "3.5.1", - "commander": "7.2.0", - "cross-spawn": "7.0.3", - "elm-tooling": "1.3.0", - "glob": "7.1.6", - "graceful-fs": "4.2.6", - "rimraf": "3.0.2", - "split": "1.0.1", - "which": "2.0.2", - "xmlbuilder": "15.1.1" + "chalk": "^4.1.0", + "chokidar": "^3.5.1", + "commander": "^7.0.0", + "cross-spawn": "^7.0.3", + "elm-tooling": "^1.1.0", + "glob": "^7.1.6", + "graceful-fs": "^4.2.4", + "rimraf": "^3.0.2", + "split": "^1.0.1", + "which": "^2.0.2", + "xmlbuilder": "^15.1.0" }, "dependencies": { "anymatch": { @@ -2833,8 +2833,8 @@ "integrity": "sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==", "dev": true, "requires": { - "normalize-path": "3.0.0", - "picomatch": "2.2.3" + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" } }, "binary-extensions": { @@ -2849,7 +2849,7 @@ "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", "dev": true, "requires": { - "fill-range": "7.0.1" + "fill-range": "^7.0.1" } }, "chalk": { @@ -2858,8 +2858,8 @@ "integrity": "sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg==", "dev": true, "requires": { - "ansi-styles": "4.2.1", - "supports-color": "7.1.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, "chokidar": { @@ -2868,14 +2868,14 @@ "integrity": "sha512-9+s+Od+W0VJJzawDma/gvBNQqkTiqYTWLuZoyAsivsI4AaWTCzHG06/TMjsf1cYe9Cb97UCEhjz7HvnPk2p/tw==", "dev": true, "requires": { - "anymatch": "3.1.2", - "braces": "3.0.2", - "fsevents": "2.3.2", - "glob-parent": "5.1.2", - "is-binary-path": "2.1.0", - "is-glob": "4.0.1", - "normalize-path": "3.0.0", - "readdirp": "3.5.0" + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "fsevents": "~2.3.1", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.5.0" } }, "commander": { @@ -2890,7 +2890,7 @@ "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", "dev": true, "requires": { - "to-regex-range": "5.0.1" + "to-regex-range": "^5.0.1" } }, "fsevents": { @@ -2906,7 +2906,7 @@ "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", "dev": true, "requires": { - "is-glob": "4.0.1" + "is-glob": "^4.0.1" } }, "graceful-fs": { @@ -2921,7 +2921,7 @@ "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", "dev": true, "requires": { - "binary-extensions": "2.2.0" + "binary-extensions": "^2.0.0" } }, "is-number": { @@ -2936,7 +2936,7 @@ "integrity": "sha512-cMhu7c/8rdhkHXWsY+osBhfSy0JikwpHK/5+imo+LpeasTF8ouErHrlYkwT0++njiyuDvc7OFY5T3ukvZ8qmFQ==", "dev": true, "requires": { - "picomatch": "2.2.3" + "picomatch": "^2.2.1" } }, "rimraf": { @@ -2945,7 +2945,7 @@ "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", "dev": true, "requires": { - "glob": "7.1.6" + "glob": "^7.1.3" } }, "to-regex-range": { @@ -2954,7 +2954,7 @@ "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", "dev": true, "requires": { - "is-number": "7.0.0" + "is-number": "^7.0.0" } }, "which": { @@ -2963,7 +2963,7 @@ "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", "dev": true, "requires": { - "isexe": "2.0.0" + "isexe": "^2.0.0" } } } @@ -2985,7 +2985,7 @@ "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", "requires": { - "once": "1.4.0" + "once": "^1.4.0" } }, "engine.io": { @@ -2994,12 +2994,12 @@ "integrity": "sha512-+VlKzHzMhaU+GsCIg4AoXF1UdDFjHHwMmMKqMJNDNLlUlejz58FCy4LBqB2YVJskHGYl06BatYWKP2TVdVXE5w==", "dev": true, "requires": { - "accepts": "1.3.7", + "accepts": "~1.3.4", "base64id": "1.0.0", "cookie": "0.3.1", - "debug": "3.1.0", - "engine.io-parser": "2.1.3", - "ws": "3.3.3" + "debug": "~3.1.0", + "engine.io-parser": "~2.1.0", + "ws": "~3.3.1" }, "dependencies": { "debug": { @@ -3018,10 +3018,10 @@ "dev": true, "requires": { "after": "0.8.2", - "arraybuffer.slice": "0.0.7", + "arraybuffer.slice": "~0.0.7", "base64-arraybuffer": "0.1.5", "blob": "0.0.5", - "has-binary2": "1.0.3" + "has-binary2": "~1.0.2" } }, "ms": { @@ -3036,9 +3036,9 @@ "integrity": "sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA==", "dev": true, "requires": { - "async-limiter": "1.0.1", - "safe-buffer": "5.1.2", - "ultron": "1.1.1" + "async-limiter": "~1.0.0", + "safe-buffer": "~5.1.0", + "ultron": "~1.1.0" } } } @@ -3051,14 +3051,14 @@ "requires": { "component-emitter": "1.2.1", "component-inherit": "0.0.3", - "debug": "4.1.1", - "engine.io-parser": "2.2.0", + "debug": "~4.1.0", + "engine.io-parser": "~2.2.0", "has-cors": "1.1.0", "indexof": "0.0.1", "parseqs": "0.0.5", "parseuri": "0.0.5", - "ws": "6.1.4", - "xmlhttprequest-ssl": "1.5.5", + "ws": "~6.1.0", + "xmlhttprequest-ssl": "~1.5.4", "yeast": "0.1.2" } }, @@ -3069,10 +3069,10 @@ "dev": true, "requires": { "after": "0.8.2", - "arraybuffer.slice": "0.0.7", + "arraybuffer.slice": "~0.0.7", "base64-arraybuffer": "0.1.5", "blob": "0.0.5", - "has-binary2": "1.0.3" + "has-binary2": "~1.0.2" } }, "entities": { @@ -3087,7 +3087,7 @@ "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", "dev": true, "requires": { - "is-arrayish": "0.2.1" + "is-arrayish": "^0.2.1" } }, "es-abstract": { @@ -3096,17 +3096,17 @@ "integrity": "sha512-BR9auzDbySxOcfog0tLECW8l28eRGpDpU3Dm3Hp4q/N+VtLTmyj4EUN088XZWQDW/hzj6sYRDXeOFsaAODKvpg==", "dev": true, "requires": { - "es-to-primitive": "1.2.1", - "function-bind": "1.1.1", - "has": "1.0.3", - "has-symbols": "1.0.1", - "is-callable": "1.1.5", - "is-regex": "1.0.5", - "object-inspect": "1.7.0", - "object-keys": "1.1.1", - "object.assign": "4.1.0", - "string.prototype.trimleft": "2.1.1", - "string.prototype.trimright": "2.1.1" + "es-to-primitive": "^1.2.1", + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1", + "is-callable": "^1.1.5", + "is-regex": "^1.0.5", + "object-inspect": "^1.7.0", + "object-keys": "^1.1.1", + "object.assign": "^4.1.0", + "string.prototype.trimleft": "^2.1.1", + "string.prototype.trimright": "^2.1.1" } }, "es-to-primitive": { @@ -3115,9 +3115,9 @@ "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", "dev": true, "requires": { - "is-callable": "1.1.5", - "is-date-object": "1.0.2", - "is-symbol": "1.0.3" + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" } }, "es6-promise": { @@ -3156,13 +3156,13 @@ "integrity": "sha512-qACXdu/9VHPBzcyhdOWR5/IahhGMf0roTeZJfzz077GwylcDd90yOHLouhmv7GJ5XzPi6ekaQWd8AvPP2nOvpA==", "dev": true, "requires": { - "duplexer": "0.1.1", - "from": "0.1.7", + "duplexer": "^0.1.1", + "from": "^0.1.7", "map-stream": "0.0.7", - "pause-stream": "0.0.11", - "split": "1.0.1", - "stream-combiner": "0.2.2", - "through": "2.3.8" + "pause-stream": "^0.0.11", + "split": "^1.0.1", + "stream-combiner": "^0.2.2", + "through": "^2.3.8" } }, "eventemitter3": { @@ -3178,11 +3178,11 @@ "dev": true, "optional": true, "requires": { - "execa": "0.7.0", - "p-finally": "1.0.0", - "pify": "3.0.0", - "rimraf": "2.7.1", - "tempfile": "2.0.0" + "execa": "^0.7.0", + "p-finally": "^1.0.0", + "pify": "^3.0.0", + "rimraf": "^2.5.4", + "tempfile": "^2.0.0" }, "dependencies": { "pify": { @@ -3200,13 +3200,13 @@ "integrity": "sha1-lEvs00zEHuMqY6n68nrVpl/Fl3c=", "dev": true, "requires": { - "cross-spawn": "5.1.0", - "get-stream": "3.0.0", - "is-stream": "1.1.0", - "npm-run-path": "2.0.2", - "p-finally": "1.0.0", - "signal-exit": "3.0.3", - "strip-eof": "1.0.0" + "cross-spawn": "^5.0.1", + "get-stream": "^3.0.0", + "is-stream": "^1.1.0", + "npm-run-path": "^2.0.0", + "p-finally": "^1.0.0", + "signal-exit": "^3.0.0", + "strip-eof": "^1.0.0" }, "dependencies": { "cross-spawn": { @@ -3215,9 +3215,9 @@ "integrity": "sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk=", "dev": true, "requires": { - "lru-cache": "4.1.5", - "shebang-command": "1.2.0", - "which": "1.3.1" + "lru-cache": "^4.0.1", + "shebang-command": "^1.2.0", + "which": "^1.2.9" } } } @@ -3229,7 +3229,7 @@ "dev": true, "optional": true, "requires": { - "pify": "2.3.0" + "pify": "^2.2.0" } }, "expand-brackets": { @@ -3238,13 +3238,13 @@ "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", "dev": true, "requires": { - "debug": "2.6.9", - "define-property": "0.2.5", - "extend-shallow": "2.0.1", - "posix-character-classes": "0.1.1", - "regex-not": "1.0.2", - "snapdragon": "0.8.2", - "to-regex": "3.0.2" + "debug": "^2.3.3", + "define-property": "^0.2.5", + "extend-shallow": "^2.0.1", + "posix-character-classes": "^0.1.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" }, "dependencies": { "debug": { @@ -3262,7 +3262,7 @@ "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, "requires": { - "is-descriptor": "0.1.6" + "is-descriptor": "^0.1.0" } }, "extend-shallow": { @@ -3271,7 +3271,7 @@ "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, "requires": { - "is-extendable": "0.1.1" + "is-extendable": "^0.1.0" } }, "ms": { @@ -3288,7 +3288,7 @@ "integrity": "sha1-opnv/TNf4nIeuujiV+x5ZE/IUzc=", "dev": true, "requires": { - "fill-range": "2.2.4" + "fill-range": "^2.1.0" }, "dependencies": { "fill-range": { @@ -3297,11 +3297,11 @@ "integrity": "sha512-cnrcCbj01+j2gTG921VZPnHbjmdAf8oQV/iGeV2kZxGSyfYjjTyY79ErsK1WJWMpw6DaApEX72binqJE+/d+5Q==", "dev": true, "requires": { - "is-number": "2.1.0", - "isobject": "2.1.0", - "randomatic": "3.1.1", - "repeat-element": "1.1.3", - "repeat-string": "1.6.1" + "is-number": "^2.1.0", + "isobject": "^2.0.0", + "randomatic": "^3.0.0", + "repeat-element": "^1.1.2", + "repeat-string": "^1.5.2" } }, "is-number": { @@ -3310,7 +3310,7 @@ "integrity": "sha1-Afy7s5NGOlSPL0ZszhbezknbkI8=", "dev": true, "requires": { - "kind-of": "3.2.2" + "kind-of": "^3.0.2" } }, "isobject": { @@ -3328,7 +3328,7 @@ "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } } } @@ -3339,7 +3339,7 @@ "integrity": "sha1-l+gBqgUt8CRU3kawK/YhZCzchQI=", "dev": true, "requires": { - "homedir-polyfill": "1.0.3" + "homedir-polyfill": "^1.0.1" } }, "ext-list": { @@ -3348,7 +3348,7 @@ "integrity": "sha512-u+SQgsubraE6zItfVA0tBuCBhfU9ogSRnsvygI7wht9TS510oLkBRXBsqopeUG/GBOIQyKZO9wjTqIu/sf5zFA==", "dev": true, "requires": { - "mime-db": "1.43.0" + "mime-db": "^1.28.0" } }, "ext-name": { @@ -3357,8 +3357,8 @@ "integrity": "sha512-yblEwXAbGv1VQDmow7s38W77hzAgJAO50ztBLMcUyUBfxv1HC+LGwtiEN+Co6LtlqT/5uwVOxsD4TNIilWhwdQ==", "dev": true, "requires": { - "ext-list": "2.2.2", - "sort-keys-length": "1.0.1" + "ext-list": "^2.0.0", + "sort-keys-length": "^1.0.0" } }, "extend": { @@ -3372,8 +3372,8 @@ "integrity": "sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg=", "dev": true, "requires": { - "assign-symbols": "1.0.0", - "is-extendable": "1.0.1" + "assign-symbols": "^1.0.0", + "is-extendable": "^1.0.1" }, "dependencies": { "is-extendable": { @@ -3382,7 +3382,7 @@ "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", "dev": true, "requires": { - "is-plain-object": "2.0.4" + "is-plain-object": "^2.0.4" } } } @@ -3393,14 +3393,14 @@ "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", "dev": true, "requires": { - "array-unique": "0.3.2", - "define-property": "1.0.0", - "expand-brackets": "2.1.4", - "extend-shallow": "2.0.1", - "fragment-cache": "0.2.1", - "regex-not": "1.0.2", - "snapdragon": "0.8.2", - "to-regex": "3.0.2" + "array-unique": "^0.3.2", + "define-property": "^1.0.0", + "expand-brackets": "^2.1.4", + "extend-shallow": "^2.0.1", + "fragment-cache": "^0.2.1", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" }, "dependencies": { "define-property": { @@ -3409,7 +3409,7 @@ "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", "dev": true, "requires": { - "is-descriptor": "1.0.2" + "is-descriptor": "^1.0.0" } }, "extend-shallow": { @@ -3418,7 +3418,7 @@ "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, "requires": { - "is-extendable": "0.1.1" + "is-extendable": "^0.1.0" } }, "is-accessor-descriptor": { @@ -3427,7 +3427,7 @@ "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.0" } }, "is-data-descriptor": { @@ -3436,7 +3436,7 @@ "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.0" } }, "is-descriptor": { @@ -3445,9 +3445,9 @@ "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, "requires": { - "is-accessor-descriptor": "1.0.0", - "is-data-descriptor": "1.0.0", - "kind-of": "6.0.3" + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" } } } @@ -3463,10 +3463,10 @@ "integrity": "sha512-k9oEhlyc0FrVh25qYuSELjr8oxsCoc4/LEZfg2iJJrfEk/tZL9bCoJE47gqAvI2m/AUjluCS4+3I0eTx8n3AEw==", "dev": true, "requires": { - "ansi-gray": "0.1.1", - "color-support": "1.1.3", - "parse-node-version": "1.0.1", - "time-stamp": "1.1.0" + "ansi-gray": "^0.1.1", + "color-support": "^1.1.3", + "parse-node-version": "^1.0.0", + "time-stamp": "^1.0.0" } }, "fast-deep-equal": { @@ -3480,12 +3480,12 @@ "integrity": "sha512-g1KuQwHOZAmOZMuBtHdxDtju+T2RT8jgCC9aANsbpdiDDTSnjgfuVsIBNKbUeJI3oKMRExcfNDtJl4OhbffMsw==", "dev": true, "requires": { - "@mrmlnc/readdir-enhanced": "2.2.1", - "@nodelib/fs.stat": "1.1.3", - "glob-parent": "3.1.0", - "is-glob": "4.0.1", - "merge2": "1.3.0", - "micromatch": "3.1.10" + "@mrmlnc/readdir-enhanced": "^2.2.1", + "@nodelib/fs.stat": "^1.1.2", + "glob-parent": "^3.1.0", + "is-glob": "^4.0.0", + "merge2": "^1.2.3", + "micromatch": "^3.1.10" } }, "fast-json-stable-stringify": { @@ -3499,7 +3499,7 @@ "integrity": "sha1-JcfInLH5B3+IkbvmHY85Dq4lbx4=", "dev": true, "requires": { - "pend": "1.2.0" + "pend": "~1.2.0" } }, "fibers": { @@ -3508,7 +3508,7 @@ "integrity": "sha512-dl3Ukt08rHVQfY8xGD0ODwyjwrRALtaghuqGH2jByYX1wpY+nAnRQjJ6Dbqq0DnVgNVQ9yibObzbF4IlPyiwPw==", "dev": true, "requires": { - "detect-libc": "1.0.3" + "detect-libc": "^1.0.3" } }, "figures": { @@ -3518,8 +3518,8 @@ "dev": true, "optional": true, "requires": { - "escape-string-regexp": "1.0.5", - "object-assign": "4.1.1" + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" } }, "file-type": { @@ -3553,9 +3553,9 @@ "integrity": "sha512-ICw7NTT6RsDp2rnYKVd8Fu4cr6ITzGy3+u4vUujPkabyaz+03F24NWEX7fs5fp+kBonlaqPH8fAO2NM+SXt/JA==", "dev": true, "requires": { - "filename-reserved-regex": "2.0.0", - "strip-outer": "1.0.1", - "trim-repeated": "1.0.0" + "filename-reserved-regex": "^2.0.0", + "strip-outer": "^1.0.0", + "trim-repeated": "^1.0.0" } }, "fill-range": { @@ -3564,10 +3564,10 @@ "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", "dev": true, "requires": { - "extend-shallow": "2.0.1", - "is-number": "3.0.0", - "repeat-string": "1.6.1", - "to-regex-range": "2.1.1" + "extend-shallow": "^2.0.1", + "is-number": "^3.0.0", + "repeat-string": "^1.6.1", + "to-regex-range": "^2.1.0" }, "dependencies": { "extend-shallow": { @@ -3576,7 +3576,7 @@ "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, "requires": { - "is-extendable": "0.1.1" + "is-extendable": "^0.1.0" } } } @@ -3588,12 +3588,12 @@ "dev": true, "requires": { "debug": "2.6.9", - "encodeurl": "1.0.2", - "escape-html": "1.0.3", - "on-finished": "2.3.0", - "parseurl": "1.3.3", - "statuses": "1.3.1", - "unpipe": "1.0.0" + "encodeurl": "~1.0.1", + "escape-html": "~1.0.3", + "on-finished": "~2.3.0", + "parseurl": "~1.3.2", + "statuses": "~1.3.1", + "unpipe": "~1.0.0" }, "dependencies": { "debug": { @@ -3625,8 +3625,8 @@ "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=", "dev": true, "requires": { - "path-exists": "2.1.0", - "pinkie-promise": "2.0.1" + "path-exists": "^2.0.0", + "pinkie-promise": "^2.0.0" } }, "find-versions": { @@ -3636,7 +3636,7 @@ "dev": true, "optional": true, "requires": { - "semver-regex": "2.0.0" + "semver-regex": "^2.0.0" } }, "findup-sync": { @@ -3645,10 +3645,10 @@ "integrity": "sha1-kyaxSIwi0aYIhlCoaQGy2akKLLw=", "dev": true, "requires": { - "detect-file": "1.0.0", - "is-glob": "3.1.0", - "micromatch": "3.1.10", - "resolve-dir": "1.0.1" + "detect-file": "^1.0.0", + "is-glob": "^3.1.0", + "micromatch": "^3.0.4", + "resolve-dir": "^1.0.1" }, "dependencies": { "is-glob": { @@ -3657,7 +3657,7 @@ "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", "dev": true, "requires": { - "is-extglob": "2.1.1" + "is-extglob": "^2.1.0" } } } @@ -3668,11 +3668,11 @@ "integrity": "sha512-ZYDqPLGxDkDhDZBjZBb+oD1+j0rA4E0pXY50eplAAOPg2N/gUBSSk5IM1/QhPfyVo19lJ+CvXpqfvk+b2p/8Ng==", "dev": true, "requires": { - "expand-tilde": "2.0.2", - "is-plain-object": "2.0.4", - "object.defaults": "1.1.0", - "object.pick": "1.3.0", - "parse-filepath": "1.0.2" + "expand-tilde": "^2.0.2", + "is-plain-object": "^2.0.3", + "object.defaults": "^1.1.0", + "object.pick": "^1.2.0", + "parse-filepath": "^1.0.1" } }, "first-chunk-stream": { @@ -3693,8 +3693,8 @@ "integrity": "sha512-3Z4XhFZ3992uIq0XOqb9AreonueSYphE6oYbpt5+3u06JWklbsPkNv3ZKkP9Bz/r+1MWCaMoSQ28P85+1Yc77w==", "dev": true, "requires": { - "inherits": "2.0.4", - "readable-stream": "2.3.7" + "inherits": "^2.0.3", + "readable-stream": "^2.3.6" }, "dependencies": { "readable-stream": { @@ -3703,13 +3703,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -3720,7 +3720,7 @@ "integrity": "sha512-0V5l4Cizzvqt5D44aTXbFZz+FtyXV1vrDN6qrelxtfYQKW0KO0W2T/hkE8xvGa/540LkZlkaUjO4ailYTFtHVQ==", "dev": true, "requires": { - "debug": "3.1.0" + "debug": "=3.1.0" }, "dependencies": { "debug": { @@ -3752,7 +3752,7 @@ "integrity": "sha1-UmXGgaTylNq78XyVCbZ2OqhFEM4=", "dev": true, "requires": { - "for-in": "1.0.2" + "for-in": "^1.0.1" } }, "forever-agent": { @@ -3771,9 +3771,9 @@ "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.5.1.tgz", "integrity": "sha512-m21N3WOmEEURgk6B9GLOE4RuWOFf28Lhh9qGYeNlGq4VDXUlJy2th2slBNU8Gp8EzloYZOibZJ7t5ecIrFSjVA==", "requires": { - "asynckit": "0.4.0", - "combined-stream": "1.0.8", - "mime-types": "2.1.26" + "asynckit": "^0.4.0", + "combined-stream": "^1.0.6", + "mime-types": "^2.1.12" } }, "fragment-cache": { @@ -3782,7 +3782,7 @@ "integrity": "sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk=", "dev": true, "requires": { - "map-cache": "0.2.2" + "map-cache": "^0.2.2" } }, "fresh": { @@ -3804,8 +3804,8 @@ "dev": true, "optional": true, "requires": { - "inherits": "2.0.4", - "readable-stream": "2.3.7" + "inherits": "^2.0.1", + "readable-stream": "^2.0.0" }, "dependencies": { "readable-stream": { @@ -3815,13 +3815,13 @@ "dev": true, "optional": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -3836,9 +3836,9 @@ "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-4.0.3.tgz", "integrity": "sha512-q6rbdDd1o2mAnQreO7YADIxf/Whx4AHBiRf6d+/cVT8h44ss+lHgxf1FemcqDnQt9X3ct4McHr+JMGlYSsK7Cg==", "requires": { - "graceful-fs": "4.2.3", - "jsonfile": "4.0.0", - "universalify": "0.1.2" + "graceful-fs": "^4.1.2", + "jsonfile": "^4.0.0", + "universalify": "^0.1.0" } }, "fs-mkdirp-stream": { @@ -3847,8 +3847,8 @@ "integrity": "sha1-C3gV/DIBxqaeFNuYzgmMFpNSWes=", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "through2": "2.0.5" + "graceful-fs": "^4.1.11", + "through2": "^2.0.3" } }, "fs.realpath": { @@ -3863,9 +3863,9 @@ "dev": true, "optional": true, "requires": { - "bindings": "1.5.0", - "nan": "2.14.0", - "node-pre-gyp": "0.14.0" + "bindings": "^1.5.0", + "nan": "^2.12.1", + "node-pre-gyp": "*" }, "dependencies": { "abbrev": { @@ -3891,8 +3891,8 @@ "dev": true, "optional": true, "requires": { - "delegates": "1.0.0", - "readable-stream": "2.3.7" + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" } }, "balanced-match": { @@ -3905,7 +3905,7 @@ "bundled": true, "dev": true, "requires": { - "balanced-match": "1.0.0", + "balanced-match": "^1.0.0", "concat-map": "0.0.1" } }, @@ -3942,7 +3942,7 @@ "dev": true, "optional": true, "requires": { - "ms": "2.1.2" + "ms": "^2.1.1" } }, "deep-extend": { @@ -3969,7 +3969,7 @@ "dev": true, "optional": true, "requires": { - "minipass": "2.9.0" + "minipass": "^2.6.0" } }, "fs.realpath": { @@ -3984,14 +3984,14 @@ "dev": true, "optional": true, "requires": { - "aproba": "1.2.0", - "console-control-strings": "1.1.0", - "has-unicode": "2.0.1", - "object-assign": "4.1.1", - "signal-exit": "3.0.2", - "string-width": "1.0.2", - "strip-ansi": "3.0.1", - "wide-align": "1.1.3" + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" } }, "glob": { @@ -4000,12 +4000,12 @@ "dev": true, "optional": true, "requires": { - "fs.realpath": "1.0.0", - "inflight": "1.0.6", - "inherits": "2.0.4", - "minimatch": "3.0.4", - "once": "1.4.0", - "path-is-absolute": "1.0.1" + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" } }, "has-unicode": { @@ -4020,7 +4020,7 @@ "dev": true, "optional": true, "requires": { - "safer-buffer": "2.1.2" + "safer-buffer": ">= 2.1.2 < 3" } }, "ignore-walk": { @@ -4029,7 +4029,7 @@ "dev": true, "optional": true, "requires": { - "minimatch": "3.0.4" + "minimatch": "^3.0.4" } }, "inflight": { @@ -4038,8 +4038,8 @@ "dev": true, "optional": true, "requires": { - "once": "1.4.0", - "wrappy": "1.0.2" + "once": "^1.3.0", + "wrappy": "1" } }, "inherits": { @@ -4058,7 +4058,7 @@ "bundled": true, "dev": true, "requires": { - "number-is-nan": "1.0.1" + "number-is-nan": "^1.0.0" } }, "isarray": { @@ -4072,7 +4072,7 @@ "bundled": true, "dev": true, "requires": { - "brace-expansion": "1.1.11" + "brace-expansion": "^1.1.7" } }, "minimist": { @@ -4085,8 +4085,8 @@ "bundled": true, "dev": true, "requires": { - "safe-buffer": "5.1.2", - "yallist": "3.1.1" + "safe-buffer": "^5.1.2", + "yallist": "^3.0.0" } }, "minizlib": { @@ -4095,7 +4095,7 @@ "dev": true, "optional": true, "requires": { - "minipass": "2.9.0" + "minipass": "^2.9.0" } }, "mkdirp": { @@ -4103,7 +4103,7 @@ "bundled": true, "dev": true, "requires": { - "minimist": "1.2.5" + "minimist": "^1.2.5" } }, "ms": { @@ -4118,9 +4118,9 @@ "dev": true, "optional": true, "requires": { - "debug": "3.2.6", - "iconv-lite": "0.4.24", - "sax": "1.2.4" + "debug": "^3.2.6", + "iconv-lite": "^0.4.4", + "sax": "^1.2.4" } }, "node-pre-gyp": { @@ -4129,16 +4129,16 @@ "dev": true, "optional": true, "requires": { - "detect-libc": "1.0.3", - "mkdirp": "0.5.3", - "needle": "2.3.3", - "nopt": "4.0.3", - "npm-packlist": "1.4.8", - "npmlog": "4.1.2", - "rc": "1.2.8", - "rimraf": "2.7.1", - "semver": "5.7.1", - "tar": "4.4.13" + "detect-libc": "^1.0.2", + "mkdirp": "^0.5.1", + "needle": "^2.2.1", + "nopt": "^4.0.1", + "npm-packlist": "^1.1.6", + "npmlog": "^4.0.2", + "rc": "^1.2.7", + "rimraf": "^2.6.1", + "semver": "^5.3.0", + "tar": "^4.4.2" } }, "nopt": { @@ -4147,8 +4147,8 @@ "dev": true, "optional": true, "requires": { - "abbrev": "1.1.1", - "osenv": "0.1.5" + "abbrev": "1", + "osenv": "^0.1.4" } }, "npm-bundled": { @@ -4157,7 +4157,7 @@ "dev": true, "optional": true, "requires": { - "npm-normalize-package-bin": "1.0.1" + "npm-normalize-package-bin": "^1.0.1" } }, "npm-normalize-package-bin": { @@ -4171,9 +4171,9 @@ "dev": true, "optional": true, "requires": { - "ignore-walk": "3.0.3", - "npm-bundled": "1.1.1", - "npm-normalize-package-bin": "1.0.1" + "ignore-walk": "^3.0.1", + "npm-bundled": "^1.0.1", + "npm-normalize-package-bin": "^1.0.1" } }, "npmlog": { @@ -4182,10 +4182,10 @@ "dev": true, "optional": true, "requires": { - "are-we-there-yet": "1.1.5", - "console-control-strings": "1.1.0", - "gauge": "2.7.4", - "set-blocking": "2.0.0" + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" } }, "number-is-nan": { @@ -4204,7 +4204,7 @@ "bundled": true, "dev": true, "requires": { - "wrappy": "1.0.2" + "wrappy": "1" } }, "os-homedir": { @@ -4225,8 +4225,8 @@ "dev": true, "optional": true, "requires": { - "os-homedir": "1.0.2", - "os-tmpdir": "1.0.2" + "os-homedir": "^1.0.0", + "os-tmpdir": "^1.0.0" } }, "path-is-absolute": { @@ -4247,10 +4247,10 @@ "dev": true, "optional": true, "requires": { - "deep-extend": "0.6.0", - "ini": "1.3.5", - "minimist": "1.2.5", - "strip-json-comments": "2.0.1" + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" } }, "readable-stream": { @@ -4259,13 +4259,13 @@ "dev": true, "optional": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } }, "rimraf": { @@ -4274,7 +4274,7 @@ "dev": true, "optional": true, "requires": { - "glob": "7.1.6" + "glob": "^7.1.3" } }, "safe-buffer": { @@ -4317,9 +4317,9 @@ "bundled": true, "dev": true, "requires": { - "code-point-at": "1.1.0", - "is-fullwidth-code-point": "1.0.0", - "strip-ansi": "3.0.1" + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" } }, "string_decoder": { @@ -4328,7 +4328,7 @@ "dev": true, "optional": true, "requires": { - "safe-buffer": "5.1.2" + "safe-buffer": "~5.1.0" } }, "strip-ansi": { @@ -4336,7 +4336,7 @@ "bundled": true, "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "strip-json-comments": { @@ -4351,13 +4351,13 @@ "dev": true, "optional": true, "requires": { - "chownr": "1.1.4", - "fs-minipass": "1.2.7", - "minipass": "2.9.0", - "minizlib": "1.3.3", - "mkdirp": "0.5.3", - "safe-buffer": "5.1.2", - "yallist": "3.1.1" + "chownr": "^1.1.1", + "fs-minipass": "^1.2.5", + "minipass": "^2.8.6", + "minizlib": "^1.2.1", + "mkdirp": "^0.5.0", + "safe-buffer": "^5.1.2", + "yallist": "^3.0.3" } }, "util-deprecate": { @@ -4372,7 +4372,7 @@ "dev": true, "optional": true, "requires": { - "string-width": "1.0.2" + "string-width": "^1.0.2 || 2" } }, "wrappy": { @@ -4393,10 +4393,10 @@ "integrity": "sha512-WvJ193OHa0GHPEL+AycEJgxvBEwyfRkN1vhjca23OaPVMCaLCXTd5qAu82AjTcgP1UJmytkOKb63Ypde7raDIg==", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "inherits": "2.0.4", - "mkdirp": "0.5.4", - "rimraf": "2.7.1" + "graceful-fs": "^4.1.2", + "inherits": "~2.0.0", + "mkdirp": ">=0.5 0", + "rimraf": "2" } }, "function-bind": { @@ -4411,14 +4411,14 @@ "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", "dev": true, "requires": { - "aproba": "1.2.0", - "console-control-strings": "1.1.0", - "has-unicode": "2.0.1", - "object-assign": "4.1.1", - "signal-exit": "3.0.3", - "string-width": "1.0.2", - "strip-ansi": "3.0.1", - "wide-align": "1.1.3" + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" }, "dependencies": { "ansi-regex": { @@ -4433,7 +4433,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } } } @@ -4444,7 +4444,7 @@ "integrity": "sha1-QLcJU30k0dRXZ9takIaJ3+aaxE8=", "dev": true, "requires": { - "globule": "0.1.0" + "globule": "~0.1.0" } }, "get-caller-file": { @@ -4464,7 +4464,7 @@ "integrity": "sha512-zmZIaQTWnNQb4R4fJUEp/FC51eZsc6EkErspy3xtIYStaq8EB/hDIWipxsal+E8rz0qD7f2sL/NA9Xee4RInJw==", "dev": true, "requires": { - "npm-conf": "1.1.3" + "npm-conf": "^1.1.0" } }, "get-stdin": { @@ -4490,7 +4490,7 @@ "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", "requires": { - "assert-plus": "1.0.0" + "assert-plus": "^1.0.0" } }, "gifsicle": { @@ -4500,10 +4500,10 @@ "dev": true, "optional": true, "requires": { - "bin-build": "3.0.0", - "bin-wrapper": "4.1.0", - "execa": "1.0.0", - "logalot": "2.1.0" + "bin-build": "^3.0.0", + "bin-wrapper": "^4.0.0", + "execa": "^1.0.0", + "logalot": "^2.0.0" }, "dependencies": { "cross-spawn": { @@ -4513,11 +4513,11 @@ "dev": true, "optional": true, "requires": { - "nice-try": "1.0.5", - "path-key": "2.0.1", - "semver": "5.7.1", - "shebang-command": "1.2.0", - "which": "1.3.1" + "nice-try": "^1.0.4", + "path-key": "^2.0.1", + "semver": "^5.5.0", + "shebang-command": "^1.2.0", + "which": "^1.2.9" } }, "execa": { @@ -4527,13 +4527,13 @@ "dev": true, "optional": true, "requires": { - "cross-spawn": "6.0.5", - "get-stream": "4.1.0", - "is-stream": "1.1.0", - "npm-run-path": "2.0.2", - "p-finally": "1.0.0", - "signal-exit": "3.0.3", - "strip-eof": "1.0.0" + "cross-spawn": "^6.0.0", + "get-stream": "^4.0.0", + "is-stream": "^1.1.0", + "npm-run-path": "^2.0.0", + "p-finally": "^1.0.0", + "signal-exit": "^3.0.0", + "strip-eof": "^1.0.0" } }, "get-stream": { @@ -4543,7 +4543,7 @@ "dev": true, "optional": true, "requires": { - "pump": "3.0.0" + "pump": "^3.0.0" } } } @@ -4554,7 +4554,7 @@ "integrity": "sha1-wWmOa2iHFk7ZeKAQlUI8/2W4558=", "dev": true, "requires": { - "underscore": "1.9.2" + "underscore": "1.x.x" } }, "git-rev": { @@ -4568,12 +4568,12 @@ "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", "requires": { - "fs.realpath": "1.0.0", - "inflight": "1.0.6", - "inherits": "2.0.4", - "minimatch": "3.0.4", - "once": "1.4.0", - "path-is-absolute": "1.0.1" + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" } }, "glob-base": { @@ -4582,8 +4582,8 @@ "integrity": "sha1-27Fk9iIbHAscz4Kuoyi0l98Oo8Q=", "dev": true, "requires": { - "glob-parent": "2.0.0", - "is-glob": "2.0.1" + "glob-parent": "^2.0.0", + "is-glob": "^2.0.0" }, "dependencies": { "glob-parent": { @@ -4592,7 +4592,7 @@ "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", "dev": true, "requires": { - "is-glob": "2.0.1" + "is-glob": "^2.0.0" } }, "is-extglob": { @@ -4607,7 +4607,7 @@ "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", "dev": true, "requires": { - "is-extglob": "1.0.0" + "is-extglob": "^1.0.0" } } } @@ -4618,8 +4618,8 @@ "integrity": "sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4=", "dev": true, "requires": { - "is-glob": "3.1.0", - "path-dirname": "1.0.2" + "is-glob": "^3.1.0", + "path-dirname": "^1.0.0" }, "dependencies": { "is-glob": { @@ -4628,7 +4628,7 @@ "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", "dev": true, "requires": { - "is-extglob": "2.1.1" + "is-extglob": "^2.1.0" } } } @@ -4639,12 +4639,12 @@ "integrity": "sha1-kXCl8St5Awb9/lmPMT+PeVT9FDs=", "dev": true, "requires": { - "glob": "4.5.3", - "glob2base": "0.0.12", - "minimatch": "2.0.10", - "ordered-read-streams": "0.1.0", - "through2": "0.6.5", - "unique-stream": "1.0.0" + "glob": "^4.3.1", + "glob2base": "^0.0.12", + "minimatch": "^2.0.1", + "ordered-read-streams": "^0.1.0", + "through2": "^0.6.1", + "unique-stream": "^1.0.0" }, "dependencies": { "glob": { @@ -4653,10 +4653,10 @@ "integrity": "sha1-xstz0yJsHv7wTePFbQEvAzd+4V8=", "dev": true, "requires": { - "inflight": "1.0.6", - "inherits": "2.0.4", - "minimatch": "2.0.10", - "once": "1.4.0" + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^2.0.1", + "once": "^1.3.0" } }, "isarray": { @@ -4671,7 +4671,7 @@ "integrity": "sha1-jQh8OcazjAAbl/ynzm0OHoCvusc=", "dev": true, "requires": { - "brace-expansion": "1.1.11" + "brace-expansion": "^1.0.0" } }, "readable-stream": { @@ -4680,10 +4680,10 @@ "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", "isarray": "0.0.1", - "string_decoder": "0.10.31" + "string_decoder": "~0.10.x" } }, "string_decoder": { @@ -4698,8 +4698,8 @@ "integrity": "sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg=", "dev": true, "requires": { - "readable-stream": "1.0.34", - "xtend": "4.0.2" + "readable-stream": ">=1.0.33-1 <1.1.0-0", + "xtend": ">=4.0.0 <4.1.0-0" } } } @@ -4716,7 +4716,7 @@ "integrity": "sha1-uVtKjfdLOcgymLDAXJeLTZo7cQs=", "dev": true, "requires": { - "gaze": "0.5.2" + "gaze": "^0.5.1" } }, "glob2base": { @@ -4725,7 +4725,7 @@ "integrity": "sha1-nUGbPijxLoOjYhZKJ3BVkiycDVY=", "dev": true, "requires": { - "find-index": "0.1.1" + "find-index": "^0.1.1" } }, "global-modules": { @@ -4734,9 +4734,9 @@ "integrity": "sha512-sKzpEkf11GpOFuw0Zzjzmt4B4UZwjOcG757PPvrfhxcLFbq0wpsgpOqxpxtxFiCG4DtG93M6XRVbF2oGdev7bg==", "dev": true, "requires": { - "global-prefix": "1.0.2", - "is-windows": "1.0.2", - "resolve-dir": "1.0.1" + "global-prefix": "^1.0.1", + "is-windows": "^1.0.1", + "resolve-dir": "^1.0.0" } }, "global-prefix": { @@ -4745,11 +4745,11 @@ "integrity": "sha1-2/dDxsFJklk8ZVVoy2btMsASLr4=", "dev": true, "requires": { - "expand-tilde": "2.0.2", - "homedir-polyfill": "1.0.3", - "ini": "1.3.5", - "is-windows": "1.0.2", - "which": "1.3.1" + "expand-tilde": "^2.0.2", + "homedir-polyfill": "^1.0.1", + "ini": "^1.3.4", + "is-windows": "^1.0.1", + "which": "^1.2.14" } }, "globby": { @@ -4758,11 +4758,11 @@ "integrity": "sha1-9abXDoOV4hyFj7BInWTfAkJNUGw=", "dev": true, "requires": { - "array-union": "1.0.2", - "glob": "7.1.6", - "object-assign": "4.1.1", - "pify": "2.3.0", - "pinkie-promise": "2.0.1" + "array-union": "^1.0.1", + "glob": "^7.0.3", + "object-assign": "^4.0.1", + "pify": "^2.0.0", + "pinkie-promise": "^2.0.0" } }, "globule": { @@ -4771,9 +4771,9 @@ "integrity": "sha1-2cjt3h2nnRJaFRt5UzuXhnY0auU=", "dev": true, "requires": { - "glob": "3.1.21", - "lodash": "1.0.2", - "minimatch": "0.2.14" + "glob": "~3.1.21", + "lodash": "~1.0.1", + "minimatch": "~0.2.11" }, "dependencies": { "glob": { @@ -4782,9 +4782,9 @@ "integrity": "sha1-0p4KBV3qUTj00H7UDomC6DwgZs0=", "dev": true, "requires": { - "graceful-fs": "1.2.3", - "inherits": "1.0.2", - "minimatch": "0.2.14" + "graceful-fs": "~1.2.0", + "inherits": "1", + "minimatch": "~0.2.11" } }, "graceful-fs": { @@ -4817,8 +4817,8 @@ "integrity": "sha1-x054BXT2PG+aCQ6Q775u9TpqdWo=", "dev": true, "requires": { - "lru-cache": "2.7.3", - "sigmund": "1.0.1" + "lru-cache": "2", + "sigmund": "~1.0.0" } } } @@ -4829,7 +4829,7 @@ "integrity": "sha512-5mwUoSuBk44Y4EshyiqcH95ZntbDdTQqA3QYSrxmzj28Ai0vXBGMH1ApSANH14j2sIRtqCEyg6PfsuP7ElOEDA==", "dev": true, "requires": { - "sparkles": "1.0.1" + "sparkles": "^1.0.0" } }, "got": { @@ -4839,20 +4839,20 @@ "dev": true, "optional": true, "requires": { - "decompress-response": "3.3.0", - "duplexer3": "0.1.4", - "get-stream": "3.0.0", - "is-plain-obj": "1.1.0", - "is-retry-allowed": "1.2.0", - "is-stream": "1.1.0", - "isurl": "1.0.0", - "lowercase-keys": "1.0.1", - "p-cancelable": "0.3.0", - "p-timeout": "1.2.1", - "safe-buffer": "5.1.2", - "timed-out": "4.0.1", - "url-parse-lax": "1.0.0", - "url-to-options": "1.0.1" + "decompress-response": "^3.2.0", + "duplexer3": "^0.1.4", + "get-stream": "^3.0.0", + "is-plain-obj": "^1.1.0", + "is-retry-allowed": "^1.0.0", + "is-stream": "^1.0.0", + "isurl": "^1.0.0-alpha5", + "lowercase-keys": "^1.0.0", + "p-cancelable": "^0.3.0", + "p-timeout": "^1.1.1", + "safe-buffer": "^5.0.1", + "timed-out": "^4.0.0", + "url-parse-lax": "^1.0.0", + "url-to-options": "^1.0.1" } }, "graceful-fs": { @@ -4883,19 +4883,19 @@ "integrity": "sha1-VxzkWSjdQK9lFPxAEYZgFsE4RbQ=", "dev": true, "requires": { - "archy": "1.0.0", - "chalk": "1.1.3", - "deprecated": "0.0.1", - "gulp-util": "3.0.8", - "interpret": "1.2.0", - "liftoff": "2.5.0", - "minimist": "1.2.5", - "orchestrator": "0.3.8", - "pretty-hrtime": "1.0.3", - "semver": "4.3.6", - "tildify": "1.2.0", - "v8flags": "2.1.1", - "vinyl-fs": "0.3.14" + "archy": "^1.0.0", + "chalk": "^1.0.0", + "deprecated": "^0.0.1", + "gulp-util": "^3.0.0", + "interpret": "^1.0.0", + "liftoff": "^2.1.0", + "minimist": "^1.1.0", + "orchestrator": "^0.3.0", + "pretty-hrtime": "^1.0.0", + "semver": "^4.1.0", + "tildify": "^1.0.0", + "v8flags": "^2.0.2", + "vinyl-fs": "^0.3.0" }, "dependencies": { "ansi-regex": { @@ -4916,11 +4916,11 @@ "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "semver": { @@ -4935,7 +4935,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -4952,12 +4952,12 @@ "integrity": "sha512-Ti/BUFe+ekhbDJfspZIMiOsOvw51KhI9EncsDfK7NaxjqRm+v4xS9v99kPxEoiDavpWqQWvG8Y6xT1mMlB3aXA==", "dev": true, "requires": { - "autoprefixer": "9.7.5", - "fancy-log": "1.3.3", - "plugin-error": "1.0.1", - "postcss": "7.0.27", - "through2": "3.0.1", - "vinyl-sourcemaps-apply": "0.2.1" + "autoprefixer": "^9.5.1", + "fancy-log": "^1.3.2", + "plugin-error": "^1.0.1", + "postcss": "^7.0.2", + "through2": "^3.0.1", + "vinyl-sourcemaps-apply": "^0.2.1" }, "dependencies": { "through2": { @@ -4966,7 +4966,7 @@ "integrity": "sha512-M96dvTalPT3YbYLaKaCuwu+j06D/8Jfib0o/PxbVt6Amhv3dUAtW6rTV1jPgJSBG83I/e04Y6xkVdVhSRhi0ww==", "dev": true, "requires": { - "readable-stream": "3.6.0" + "readable-stream": "2 || 3" } } } @@ -4977,13 +4977,13 @@ "integrity": "sha512-NE814LdX1NWQn2sMzn+Rf673o4mqlgg7OyLf92oQ4KEl6DdPfduEGLNH+HexLVcFZXH93DBuxFOvpv4/Js5VaA==", "dev": true, "requires": { - "@babel/runtime": "7.9.2", - "cache-swap": "0.3.0", - "core-js": "3.6.4", - "object.pick": "1.3.0", - "plugin-error": "1.0.1", + "@babel/runtime": "^7.5.5", + "cache-swap": "^0.3.0", + "core-js": "3", + "object.pick": "^1.3.0", + "plugin-error": "^1.0.1", "through2": "3.0.1", - "vinyl": "2.2.0" + "vinyl": "^2.2.0" }, "dependencies": { "clone": { @@ -5016,7 +5016,7 @@ "integrity": "sha512-M96dvTalPT3YbYLaKaCuwu+j06D/8Jfib0o/PxbVt6Amhv3dUAtW6rTV1jPgJSBG83I/e04Y6xkVdVhSRhi0ww==", "dev": true, "requires": { - "readable-stream": "3.6.0" + "readable-stream": "2 || 3" } }, "vinyl": { @@ -5025,12 +5025,12 @@ "integrity": "sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg==", "dev": true, "requires": { - "clone": "2.1.2", - "clone-buffer": "1.0.0", - "clone-stats": "1.0.0", - "cloneable-readable": "1.1.3", - "remove-trailing-separator": "1.1.0", - "replace-ext": "1.0.0" + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" } } } @@ -5041,8 +5041,8 @@ "integrity": "sha1-/nzU+H83YB5gc8/t7lwr2vi2rM4=", "dev": true, "requires": { - "lodash.defaults": "4.2.0", - "through2": "2.0.5" + "lodash.defaults": "^4.2.0", + "through2": "^2.0.1" } }, "gulp-changed": { @@ -5051,12 +5051,12 @@ "integrity": "sha1-zumGbZSeCRh1IlI9bGVWX24yvXw=", "dev": true, "requires": { - "make-dir": "1.3.0", - "pify": "3.0.0", - "plugin-error": "0.1.2", - "replace-ext": "1.0.0", - "through2": "2.0.5", - "touch": "3.1.0" + "make-dir": "^1.1.0", + "pify": "^3.0.0", + "plugin-error": "^0.1.2", + "replace-ext": "^1.0.0", + "through2": "^2.0.0", + "touch": "^3.1.0" }, "dependencies": { "arr-diff": { @@ -5065,8 +5065,8 @@ "integrity": "sha1-aHwydYFjWI/vfeezb6vklesaOZo=", "dev": true, "requires": { - "arr-flatten": "1.1.0", - "array-slice": "0.2.3" + "arr-flatten": "^1.0.1", + "array-slice": "^0.2.3" } }, "arr-union": { @@ -5087,7 +5087,7 @@ "integrity": "sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE=", "dev": true, "requires": { - "kind-of": "1.1.0" + "kind-of": "^1.1.0" } }, "kind-of": { @@ -5108,11 +5108,11 @@ "integrity": "sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4=", "dev": true, "requires": { - "ansi-cyan": "0.1.1", - "ansi-red": "0.1.1", - "arr-diff": "1.1.0", - "arr-union": "2.1.0", - "extend-shallow": "1.1.4" + "ansi-cyan": "^0.1.1", + "ansi-red": "^0.1.1", + "arr-diff": "^1.0.1", + "arr-union": "^2.0.1", + "extend-shallow": "^1.1.2" } }, "replace-ext": { @@ -5129,9 +5129,9 @@ "integrity": "sha1-Yz0WyV2IUEYorQJmVmPO5aR5M1M=", "dev": true, "requires": { - "concat-with-sourcemaps": "1.1.0", - "through2": "2.0.5", - "vinyl": "2.2.0" + "concat-with-sourcemaps": "^1.0.0", + "through2": "^2.0.0", + "vinyl": "^2.0.0" }, "dependencies": { "clone": { @@ -5158,12 +5158,12 @@ "integrity": "sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg==", "dev": true, "requires": { - "clone": "2.1.2", - "clone-buffer": "1.0.0", - "clone-stats": "1.0.0", - "cloneable-readable": "1.1.3", - "remove-trailing-separator": "1.1.0", - "replace-ext": "1.0.0" + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" } } } @@ -5174,15 +5174,15 @@ "integrity": "sha512-1Kmporqv3jrlgSCpWJqdpziIYyssmPFLkOlyS1kJICgBbFGYZUEkiq8YUnGauW663zwolFLmO8DxBsrUBIszPA==", "dev": true, "requires": { - "ansi-colors": "3.2.4", - "cross-spawn": "6.0.5", - "fancy-log": "1.3.3", - "plugin-error": "1.0.1", - "q": "1.5.1", - "temp": "0.9.1", - "through2": "3.0.1", - "vinyl": "2.2.0", - "which": "1.3.1" + "ansi-colors": "^3.2.1", + "cross-spawn": "^6.0.5", + "fancy-log": "^1.3.2", + "plugin-error": "^1.0.1", + "q": "^1.1.2", + "temp": "^0.9.0", + "through2": "^3.0.0", + "vinyl": "^2.2.0", + "which": "^1.0.8" }, "dependencies": { "ansi-colors": { @@ -5209,11 +5209,11 @@ "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", "dev": true, "requires": { - "nice-try": "1.0.5", - "path-key": "2.0.1", - "semver": "5.7.1", - "shebang-command": "1.2.0", - "which": "1.3.1" + "nice-try": "^1.0.4", + "path-key": "^2.0.1", + "semver": "^5.5.0", + "shebang-command": "^1.2.0", + "which": "^1.2.9" } }, "replace-ext": { @@ -5228,7 +5228,7 @@ "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", "dev": true, "requires": { - "glob": "7.1.6" + "glob": "^7.1.3" } }, "temp": { @@ -5237,7 +5237,7 @@ "integrity": "sha512-WMuOgiua1xb5R56lE0eH6ivpVmg/lq2OHm4+LtT/xtEtPQ+sz6N3bBM6WZ5FvO1lO4IKIOb43qnhoc4qxP5OeA==", "dev": true, "requires": { - "rimraf": "2.6.3" + "rimraf": "~2.6.2" } }, "through2": { @@ -5246,7 +5246,7 @@ "integrity": "sha512-M96dvTalPT3YbYLaKaCuwu+j06D/8Jfib0o/PxbVt6Amhv3dUAtW6rTV1jPgJSBG83I/e04Y6xkVdVhSRhi0ww==", "dev": true, "requires": { - "readable-stream": "3.6.0" + "readable-stream": "2 || 3" } }, "vinyl": { @@ -5255,12 +5255,12 @@ "integrity": "sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg==", "dev": true, "requires": { - "clone": "2.1.2", - "clone-buffer": "1.0.0", - "clone-stats": "1.0.0", - "cloneable-readable": "1.1.3", - "remove-trailing-separator": "1.1.0", - "replace-ext": "1.0.0" + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" } } } @@ -5271,9 +5271,9 @@ "integrity": "sha1-oF4Rr/sHz33PQafeHLe2OsN4PnM=", "dev": true, "requires": { - "multimatch": "2.1.0", - "plugin-error": "0.1.2", - "streamfilter": "1.0.7" + "multimatch": "^2.0.0", + "plugin-error": "^0.1.2", + "streamfilter": "^1.0.5" }, "dependencies": { "arr-diff": { @@ -5282,8 +5282,8 @@ "integrity": "sha1-aHwydYFjWI/vfeezb6vklesaOZo=", "dev": true, "requires": { - "arr-flatten": "1.1.0", - "array-slice": "0.2.3" + "arr-flatten": "^1.0.1", + "array-slice": "^0.2.3" } }, "arr-union": { @@ -5304,7 +5304,7 @@ "integrity": "sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE=", "dev": true, "requires": { - "kind-of": "1.1.0" + "kind-of": "^1.1.0" } }, "kind-of": { @@ -5319,11 +5319,11 @@ "integrity": "sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4=", "dev": true, "requires": { - "ansi-cyan": "0.1.1", - "ansi-red": "0.1.1", - "arr-diff": "1.1.0", - "arr-union": "2.1.0", - "extend-shallow": "1.1.4" + "ansi-cyan": "^0.1.1", + "ansi-red": "^0.1.1", + "arr-diff": "^1.0.1", + "arr-union": "^2.0.1", + "extend-shallow": "^1.1.2" } } } @@ -5334,12 +5334,12 @@ "integrity": "sha1-pnMspHWrm1pTJTwcJHNMQMIbZUY=", "dev": true, "requires": { - "gift": "0.6.1", - "gulp-util": "3.0.8", - "readable-stream": "2.3.7", - "rimraf": "2.7.1", - "vinyl-fs": "2.4.4", - "wrap-promise": "1.0.1" + "gift": "^0.6.1", + "gulp-util": "^3.0.7", + "readable-stream": "^2.0.2", + "rimraf": "^2.4.3", + "vinyl-fs": "^2.2.1", + "wrap-promise": "^1.0.1" }, "dependencies": { "arr-diff": { @@ -5348,7 +5348,7 @@ "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", "dev": true, "requires": { - "arr-flatten": "1.1.0" + "arr-flatten": "^1.0.1" } }, "array-unique": { @@ -5363,9 +5363,9 @@ "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", "dev": true, "requires": { - "expand-range": "1.8.2", - "preserve": "0.2.0", - "repeat-element": "1.1.3" + "expand-range": "^1.8.1", + "preserve": "^0.2.0", + "repeat-element": "^1.1.2" } }, "expand-brackets": { @@ -5374,7 +5374,7 @@ "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", "dev": true, "requires": { - "is-posix-bracket": "0.1.1" + "is-posix-bracket": "^0.1.0" } }, "extglob": { @@ -5383,7 +5383,7 @@ "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", "dev": true, "requires": { - "is-extglob": "1.0.0" + "is-extglob": "^1.0.0" } }, "glob": { @@ -5392,11 +5392,11 @@ "integrity": "sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E=", "dev": true, "requires": { - "inflight": "1.0.6", - "inherits": "2.0.4", - "minimatch": "3.0.4", - "once": "1.4.0", - "path-is-absolute": "1.0.1" + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "2 || 3", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" } }, "glob-stream": { @@ -5405,14 +5405,14 @@ "integrity": "sha1-pVZlqajM3EGRWofHAeMtTgFvrSI=", "dev": true, "requires": { - "extend": "3.0.2", - "glob": "5.0.15", - "glob-parent": "3.1.0", - "micromatch": "2.3.11", - "ordered-read-streams": "0.3.0", - "through2": "0.6.5", - "to-absolute-glob": "0.1.1", - "unique-stream": "2.3.1" + "extend": "^3.0.0", + "glob": "^5.0.3", + "glob-parent": "^3.0.0", + "micromatch": "^2.3.7", + "ordered-read-streams": "^0.3.0", + "through2": "^0.6.0", + "to-absolute-glob": "^0.1.1", + "unique-stream": "^2.0.2" }, "dependencies": { "isarray": { @@ -5427,10 +5427,10 @@ "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", "isarray": "0.0.1", - "string_decoder": "0.10.31" + "string_decoder": "~0.10.x" } }, "string_decoder": { @@ -5445,8 +5445,8 @@ "integrity": "sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg=", "dev": true, "requires": { - "readable-stream": "1.0.34", - "xtend": "4.0.2" + "readable-stream": ">=1.0.33-1 <1.1.0-0", + "xtend": ">=4.0.0 <4.1.0-0" } } } @@ -5463,7 +5463,7 @@ "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", "dev": true, "requires": { - "is-extglob": "1.0.0" + "is-extglob": "^1.0.0" } }, "kind-of": { @@ -5472,7 +5472,7 @@ "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } }, "merge-stream": { @@ -5481,7 +5481,7 @@ "integrity": "sha1-QEEgLVCKNCugAXQAjfDCUbjBNeE=", "dev": true, "requires": { - "readable-stream": "2.3.7" + "readable-stream": "^2.0.1" } }, "micromatch": { @@ -5490,19 +5490,19 @@ "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", "dev": true, "requires": { - "arr-diff": "2.0.0", - "array-unique": "0.2.1", - "braces": "1.8.5", - "expand-brackets": "0.1.5", - "extglob": "0.3.2", - "filename-regex": "2.0.1", - "is-extglob": "1.0.0", - "is-glob": "2.0.1", - "kind-of": "3.2.2", - "normalize-path": "2.1.1", - "object.omit": "2.0.1", - "parse-glob": "3.0.4", - "regex-cache": "0.4.4" + "arr-diff": "^2.0.0", + "array-unique": "^0.2.1", + "braces": "^1.8.2", + "expand-brackets": "^0.1.4", + "extglob": "^0.3.1", + "filename-regex": "^2.0.0", + "is-extglob": "^1.0.0", + "is-glob": "^2.0.1", + "kind-of": "^3.0.2", + "normalize-path": "^2.0.1", + "object.omit": "^2.0.0", + "parse-glob": "^3.0.4", + "regex-cache": "^0.4.2" } }, "normalize-path": { @@ -5511,7 +5511,7 @@ "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", "dev": true, "requires": { - "remove-trailing-separator": "1.1.0" + "remove-trailing-separator": "^1.0.1" } }, "ordered-read-streams": { @@ -5520,8 +5520,8 @@ "integrity": "sha1-cTfmmzKYuzQiR6G77jiByA4v14s=", "dev": true, "requires": { - "is-stream": "1.1.0", - "readable-stream": "2.3.7" + "is-stream": "^1.0.1", + "readable-stream": "^2.0.1" } }, "readable-stream": { @@ -5530,13 +5530,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } }, "unique-stream": { @@ -5545,8 +5545,8 @@ "integrity": "sha512-2nY4TnBE70yoxHkDli7DMazpWiP7xMdCYqU2nBRO0UB+ZpEkGsSija7MvmvnZFUeC+mrgiUfcHSr3LmRFIg4+A==", "dev": true, "requires": { - "json-stable-stringify-without-jsonify": "1.0.1", - "through2-filter": "3.0.0" + "json-stable-stringify-without-jsonify": "^1.0.1", + "through2-filter": "^3.0.0" }, "dependencies": { "through2-filter": { @@ -5555,8 +5555,8 @@ "integrity": "sha512-jaRjI2WxN3W1V8/FMZ9HKIBXixtiqs3SQSX4/YGIiP3gL6djW48VoZq9tDqeCWs3MT8YY5wb/zli8VW8snY1CA==", "dev": true, "requires": { - "through2": "2.0.5", - "xtend": "4.0.2" + "through2": "~2.0.0", + "xtend": "~4.0.0" } } } @@ -5567,8 +5567,8 @@ "integrity": "sha1-XIgDbPVl5d8FVYv8kR+GVt8hiIQ=", "dev": true, "requires": { - "clone": "1.0.4", - "clone-stats": "0.0.1", + "clone": "^1.0.0", + "clone-stats": "^0.0.1", "replace-ext": "0.0.1" } }, @@ -5578,23 +5578,23 @@ "integrity": "sha1-vm/zJwy1Xf19MGNkDegfJddTIjk=", "dev": true, "requires": { - "duplexify": "3.7.1", - "glob-stream": "5.3.5", - "graceful-fs": "4.2.3", + "duplexify": "^3.2.0", + "glob-stream": "^5.3.2", + "graceful-fs": "^4.0.0", "gulp-sourcemaps": "1.6.0", - "is-valid-glob": "0.3.0", - "lazystream": "1.0.0", - "lodash.isequal": "4.5.0", - "merge-stream": "1.0.1", - "mkdirp": "0.5.4", - "object-assign": "4.1.1", - "readable-stream": "2.3.7", - "strip-bom": "2.0.0", - "strip-bom-stream": "1.0.0", - "through2": "2.0.5", - "through2-filter": "2.0.0", - "vali-date": "1.0.0", - "vinyl": "1.2.0" + "is-valid-glob": "^0.3.0", + "lazystream": "^1.0.0", + "lodash.isequal": "^4.0.0", + "merge-stream": "^1.0.0", + "mkdirp": "^0.5.0", + "object-assign": "^4.0.0", + "readable-stream": "^2.0.4", + "strip-bom": "^2.0.0", + "strip-bom-stream": "^1.0.0", + "through2": "^2.0.0", + "through2-filter": "^2.0.0", + "vali-date": "^1.0.0", + "vinyl": "^1.0.0" } } } @@ -5605,12 +5605,12 @@ "integrity": "sha512-ZIxfkUwk2XmZPTT9pPHrHUQlZMyp9nPhg2sfoeN27mBGpi7OaHnOD+WCN41NXjfJQ69lV1nQ9LLm1hYxx4h3UQ==", "dev": true, "requires": { - "ansi-colors": "1.1.0", - "bytes": "3.1.0", - "fancy-log": "1.3.3", - "plugin-error": "1.0.1", - "stream-to-array": "2.3.0", - "through2": "2.0.5" + "ansi-colors": "^1.0.1", + "bytes": "^3.0.0", + "fancy-log": "^1.3.2", + "plugin-error": "^1.0.0", + "stream-to-array": "^2.3.0", + "through2": "^2.0.3" } }, "gulp-htmlmin": { @@ -5619,9 +5619,9 @@ "integrity": "sha512-ASlyDPZOSKjHYUifYV0rf9JPDflN9IRIb8lw2vRqtYMC4ljU3zAmnnaVXwFQ3H+CfXxZSUesZ2x7jrnPJu93jA==", "dev": true, "requires": { - "html-minifier": "3.5.21", - "plugin-error": "1.0.1", - "through2": "2.0.5" + "html-minifier": "^3.5.20", + "plugin-error": "^1.0.1", + "through2": "^2.0.3" } }, "gulp-if": { @@ -5630,9 +5630,9 @@ "integrity": "sha1-pJe351cwBQQcqivIt92jyARE1ik=", "dev": true, "requires": { - "gulp-match": "1.1.0", - "ternary-stream": "2.1.1", - "through2": "2.0.5" + "gulp-match": "^1.0.3", + "ternary-stream": "^2.0.1", + "through2": "^2.0.1" } }, "gulp-imagemin": { @@ -5641,17 +5641,17 @@ "integrity": "sha512-bKJMix4r6EQPVV2u8sUglw6Rn0PSp6i70pSK2ECN7j0dRy0w/Lz5SBbynY3MfGBZ0cTMZlaUq+6LyKlZgP74Ew==", "dev": true, "requires": { - "chalk": "2.4.2", - "fancy-log": "1.3.3", - "imagemin": "6.1.0", - "imagemin-gifsicle": "6.0.1", - "imagemin-jpegtran": "6.0.0", - "imagemin-optipng": "6.0.0", - "imagemin-svgo": "7.1.0", - "plugin-error": "1.0.1", - "plur": "3.1.1", - "pretty-bytes": "5.3.0", - "through2-concurrent": "2.0.0" + "chalk": "^2.4.1", + "fancy-log": "^1.3.2", + "imagemin": "^6.0.0", + "imagemin-gifsicle": "^6.0.1", + "imagemin-jpegtran": "^6.0.0", + "imagemin-optipng": "^6.0.0", + "imagemin-svgo": "^7.0.0", + "plugin-error": "^1.0.1", + "plur": "^3.0.1", + "pretty-bytes": "^5.1.0", + "through2-concurrent": "^2.0.0" }, "dependencies": { "ansi-styles": { @@ -5660,7 +5660,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -5669,9 +5669,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -5701,7 +5701,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -5712,11 +5712,11 @@ "integrity": "sha512-sP3NK8Y/1e58O0PH9t6s7DAr/lKDSUbIY207oWSeufM6/VclB7jJrIBcPCsyhrFTCDUl9DauePbt6VqP2vPM5w==", "dev": true, "requires": { - "lodash": "4.17.15", - "minimatch": "3.0.4", - "plugin-error": "0.1.2", - "rcloader": "0.2.2", - "through2": "2.0.5" + "lodash": "^4.12.0", + "minimatch": "^3.0.3", + "plugin-error": "^0.1.2", + "rcloader": "^0.2.2", + "through2": "^2.0.0" }, "dependencies": { "arr-diff": { @@ -5725,8 +5725,8 @@ "integrity": "sha1-aHwydYFjWI/vfeezb6vklesaOZo=", "dev": true, "requires": { - "arr-flatten": "1.1.0", - "array-slice": "0.2.3" + "arr-flatten": "^1.0.1", + "array-slice": "^0.2.3" } }, "arr-union": { @@ -5747,7 +5747,7 @@ "integrity": "sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE=", "dev": true, "requires": { - "kind-of": "1.1.0" + "kind-of": "^1.1.0" } }, "kind-of": { @@ -5762,11 +5762,11 @@ "integrity": "sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4=", "dev": true, "requires": { - "ansi-cyan": "0.1.1", - "ansi-red": "0.1.1", - "arr-diff": "1.1.0", - "arr-union": "2.1.0", - "extend-shallow": "1.1.4" + "ansi-cyan": "^0.1.1", + "ansi-red": "^0.1.1", + "arr-diff": "^1.0.1", + "arr-union": "^2.0.1", + "extend-shallow": "^1.1.2" } } } @@ -5777,13 +5777,13 @@ "integrity": "sha512-HlCODki0WHJvQIgAsJYOTkyo0c7TsDCetvfhrdGz9JYPL6A4mFRMGmKfoi6JmXjA/vvzg+fkT91c9FBh7rnkyg==", "dev": true, "requires": { - "array-unique": "0.2.1", - "fancy-log": "1.3.3", - "findup-sync": "3.0.0", - "gulplog": "1.0.0", - "has-gulplog": "0.1.0", - "micromatch": "3.1.10", - "resolve": "1.15.1" + "array-unique": "^0.2.1", + "fancy-log": "^1.2.0", + "findup-sync": "^3.0.0", + "gulplog": "^1.0.0", + "has-gulplog": "^0.1.0", + "micromatch": "^3.1.10", + "resolve": "^1.1.7" }, "dependencies": { "array-unique": { @@ -5798,10 +5798,10 @@ "integrity": "sha512-YbffarhcicEhOrm4CtrwdKBdCuz576RLdhJDsIfvNtxUuhdRet1qZcsMjqbePtAseKdAnDyM/IyXbu7PRPRLYg==", "dev": true, "requires": { - "detect-file": "1.0.0", - "is-glob": "4.0.1", - "micromatch": "3.1.10", - "resolve-dir": "1.0.1" + "detect-file": "^1.0.0", + "is-glob": "^4.0.0", + "micromatch": "^3.0.4", + "resolve-dir": "^1.0.1" } } } @@ -5812,7 +5812,7 @@ "integrity": "sha512-DlyVxa1Gj24DitY2OjEsS+X6tDpretuxD6wTfhXE/Rw2hweqc1f6D/XtsJmoiCwLWfXgR87W9ozEityPCVzGtQ==", "dev": true, "requires": { - "minimatch": "3.0.4" + "minimatch": "^3.0.3" } }, "gulp-minify-css": { @@ -5821,12 +5821,12 @@ "integrity": "sha1-thZJV2Auon+eWtiCJ2ld0gV3jAY=", "dev": true, "requires": { - "clean-css": "3.4.28", - "gulp-util": "3.0.8", - "object-assign": "4.1.1", - "readable-stream": "2.3.7", - "vinyl-bufferstream": "1.0.1", - "vinyl-sourcemaps-apply": "0.2.1" + "clean-css": "^3.3.3", + "gulp-util": "^3.0.5", + "object-assign": "^4.0.1", + "readable-stream": "^2.0.0", + "vinyl-bufferstream": "^1.0.1", + "vinyl-sourcemaps-apply": "^0.2.0" }, "dependencies": { "clean-css": { @@ -5835,8 +5835,8 @@ "integrity": "sha1-vxlF6C/ICPVWlebd6uwBQA79A/8=", "dev": true, "requires": { - "commander": "2.8.1", - "source-map": "0.4.4" + "commander": "2.8.x", + "source-map": "0.4.x" } }, "commander": { @@ -5845,7 +5845,7 @@ "integrity": "sha1-Br42f+v9oMMwqh4qBy09yXYkJdQ=", "dev": true, "requires": { - "graceful-readlink": "1.0.1" + "graceful-readlink": ">= 1.0.0" } }, "readable-stream": { @@ -5854,13 +5854,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } }, "source-map": { @@ -5869,7 +5869,7 @@ "integrity": "sha1-66T12pwNyZneaAMti092FzZSA2s=", "dev": true, "requires": { - "amdefine": "1.0.1" + "amdefine": ">=0.0.4" } } } @@ -5880,10 +5880,10 @@ "integrity": "sha512-mctAi9msEAG7XzW5ytDVZ9PxWMzzi1pS2rBH7lA095DhMa6KEXjm+St0GOCc567pJKJ/oCvosVAZEpAey0q2eQ==", "dev": true, "requires": { - "chalk": "1.1.3", - "fancy-log": "1.3.3", - "plugin-error": "0.1.2", - "through2": "2.0.5" + "chalk": "^1.1.3", + "fancy-log": "^1.3.2", + "plugin-error": "^0.1.2", + "through2": "^2.0.3" }, "dependencies": { "ansi-regex": { @@ -5904,8 +5904,8 @@ "integrity": "sha1-aHwydYFjWI/vfeezb6vklesaOZo=", "dev": true, "requires": { - "arr-flatten": "1.1.0", - "array-slice": "0.2.3" + "arr-flatten": "^1.0.1", + "array-slice": "^0.2.3" } }, "arr-union": { @@ -5926,11 +5926,11 @@ "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "extend-shallow": { @@ -5939,7 +5939,7 @@ "integrity": "sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE=", "dev": true, "requires": { - "kind-of": "1.1.0" + "kind-of": "^1.1.0" } }, "kind-of": { @@ -5954,11 +5954,11 @@ "integrity": "sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4=", "dev": true, "requires": { - "ansi-cyan": "0.1.1", - "ansi-red": "0.1.1", - "arr-diff": "1.1.0", - "arr-union": "2.1.0", - "extend-shallow": "1.1.4" + "ansi-cyan": "^0.1.1", + "ansi-red": "^0.1.1", + "arr-diff": "^1.0.1", + "arr-union": "^2.0.1", + "extend-shallow": "^1.1.2" } }, "strip-ansi": { @@ -5967,7 +5967,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -5990,13 +5990,13 @@ "integrity": "sha512-/6SxY7jg87HRQKz9pJyA72BLxxpGSZh35T1Cxwdqys8s1hAh6V5vciAfAIDo/BkkIWnw6NvaCbxW2WsKeiQyDg==", "dev": true, "requires": { - "chalk": "2.4.2", - "fancy-log": "1.3.3", - "isbinaryfile": "3.0.3", - "merge": "1.2.1", - "plugin-error": "1.0.1", - "through2": "2.0.5", - "vinyl": "2.2.0" + "chalk": "^2.4.1", + "fancy-log": "^1.3.2", + "isbinaryfile": "^3.0.2", + "merge": "^1.2.0", + "plugin-error": "^1.0.1", + "through2": "^2.0.3", + "vinyl": "^2.1.0" }, "dependencies": { "ansi-styles": { @@ -6005,7 +6005,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -6014,9 +6014,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "clone": { @@ -6064,7 +6064,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } }, "vinyl": { @@ -6073,12 +6073,12 @@ "integrity": "sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg==", "dev": true, "requires": { - "clone": "2.1.2", - "clone-buffer": "1.0.0", - "clone-stats": "1.0.0", - "cloneable-readable": "1.1.3", - "remove-trailing-separator": "1.1.0", - "replace-ext": "1.0.0" + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" } } } @@ -6089,8 +6089,8 @@ "integrity": "sha512-2yiDel/TGamn/HgHyo8H1rYEEL2zLsOYODerItoX8batOo0gPAe7uX7t6NlaqB7FEHpS5tGzUr5CKUEmrgdHyQ==", "dev": true, "requires": { - "plugin-error": "0.1.2", - "through2": "2.0.5" + "plugin-error": "^0.1.2", + "through2": "^2.0.0" }, "dependencies": { "arr-diff": { @@ -6099,8 +6099,8 @@ "integrity": "sha1-aHwydYFjWI/vfeezb6vklesaOZo=", "dev": true, "requires": { - "arr-flatten": "1.1.0", - "array-slice": "0.2.3" + "arr-flatten": "^1.0.1", + "array-slice": "^0.2.3" } }, "arr-union": { @@ -6121,7 +6121,7 @@ "integrity": "sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE=", "dev": true, "requires": { - "kind-of": "1.1.0" + "kind-of": "^1.1.0" } }, "kind-of": { @@ -6136,11 +6136,11 @@ "integrity": "sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4=", "dev": true, "requires": { - "ansi-cyan": "0.1.1", - "ansi-red": "0.1.1", - "arr-diff": "1.1.0", - "arr-union": "2.1.0", - "extend-shallow": "1.1.4" + "ansi-cyan": "^0.1.1", + "ansi-red": "^0.1.1", + "arr-diff": "^1.0.1", + "arr-union": "^2.0.1", + "extend-shallow": "^1.1.2" } } } @@ -6151,14 +6151,14 @@ "integrity": "sha512-q8psj4+aDrblJMMtRxihNBdovfzGrXJp1l4JU0Sz4b/Mhsi2DPrKFYCGDwjIWRENs04ELVHxdOJQ7Vs98OFohg==", "dev": true, "requires": { - "chalk": "2.4.2", - "lodash.clonedeep": "4.5.0", - "node-sass": "4.13.1", - "plugin-error": "1.0.1", - "replace-ext": "1.0.0", - "strip-ansi": "4.0.0", - "through2": "2.0.5", - "vinyl-sourcemaps-apply": "0.2.1" + "chalk": "^2.3.0", + "lodash.clonedeep": "^4.3.2", + "node-sass": "^4.8.3", + "plugin-error": "^1.0.1", + "replace-ext": "^1.0.0", + "strip-ansi": "^4.0.0", + "through2": "^2.0.0", + "vinyl-sourcemaps-apply": "^0.2.0" }, "dependencies": { "ansi-regex": { @@ -6173,7 +6173,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -6182,9 +6182,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -6220,7 +6220,7 @@ "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", "dev": true, "requires": { - "ansi-regex": "3.0.0" + "ansi-regex": "^3.0.0" } }, "supports-color": { @@ -6229,7 +6229,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -6240,7 +6240,7 @@ "integrity": "sha512-c+p+EcyBl1UCpbfFA/vUD6MuC7uxoY6Y4g2lq9lLtzOHh9o1wijAQ4o0TIRQ14C7cG6zR6Zi+bpA0cW78CFt6g==", "dev": true, "requires": { - "thunks": "4.9.6" + "thunks": "^4.9.0" } }, "gulp-shell": { @@ -6249,12 +6249,12 @@ "integrity": "sha512-5dKf1eJDdBiUS4LKCt4tm9IkDnWeXKGCKjQG5EJj/bVeVOisAPse5RLxccGh1OtfbzQdOWCywu936DTB8isZRw==", "dev": true, "requires": { - "chalk": "2.4.2", - "fancy-log": "1.3.3", - "lodash.template": "4.5.0", - "plugin-error": "1.0.1", - "through2": "3.0.1", - "tslib": "1.11.1" + "chalk": "^2.4.2", + "fancy-log": "^1.3.3", + "lodash.template": "^4.4.0", + "plugin-error": "^1.0.1", + "through2": "^3.0.1", + "tslib": "^1.9.3" }, "dependencies": { "ansi-styles": { @@ -6263,7 +6263,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -6272,9 +6272,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -6304,7 +6304,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } }, "through2": { @@ -6313,7 +6313,7 @@ "integrity": "sha512-M96dvTalPT3YbYLaKaCuwu+j06D/8Jfib0o/PxbVt6Amhv3dUAtW6rTV1jPgJSBG83I/e04Y6xkVdVhSRhi0ww==", "dev": true, "requires": { - "readable-stream": "3.6.0" + "readable-stream": "2 || 3" } } } @@ -6324,13 +6324,13 @@ "integrity": "sha1-yxrI5rqD3t5SQwxH/QOTJPAD/4I=", "dev": true, "requires": { - "chalk": "2.4.2", - "fancy-log": "1.3.3", - "gzip-size": "4.1.0", - "plugin-error": "0.1.2", - "pretty-bytes": "4.0.2", - "stream-counter": "1.0.0", - "through2": "2.0.5" + "chalk": "^2.3.0", + "fancy-log": "^1.3.2", + "gzip-size": "^4.1.0", + "plugin-error": "^0.1.2", + "pretty-bytes": "^4.0.2", + "stream-counter": "^1.0.0", + "through2": "^2.0.0" }, "dependencies": { "ansi-styles": { @@ -6339,7 +6339,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "arr-diff": { @@ -6348,8 +6348,8 @@ "integrity": "sha1-aHwydYFjWI/vfeezb6vklesaOZo=", "dev": true, "requires": { - "arr-flatten": "1.1.0", - "array-slice": "0.2.3" + "arr-flatten": "^1.0.1", + "array-slice": "^0.2.3" } }, "arr-union": { @@ -6370,9 +6370,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -6396,7 +6396,7 @@ "integrity": "sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE=", "dev": true, "requires": { - "kind-of": "1.1.0" + "kind-of": "^1.1.0" } }, "has-flag": { @@ -6417,11 +6417,11 @@ "integrity": "sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4=", "dev": true, "requires": { - "ansi-cyan": "0.1.1", - "ansi-red": "0.1.1", - "arr-diff": "1.1.0", - "arr-union": "2.1.0", - "extend-shallow": "1.1.4" + "ansi-cyan": "^0.1.1", + "ansi-red": "^0.1.1", + "arr-diff": "^1.0.1", + "arr-union": "^2.0.1", + "extend-shallow": "^1.1.2" } }, "pretty-bytes": { @@ -6436,7 +6436,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -6447,11 +6447,11 @@ "integrity": "sha1-uG/zSdgBzrVuHZ59x7vLS33uYAw=", "dev": true, "requires": { - "convert-source-map": "1.7.0", - "graceful-fs": "4.2.3", - "strip-bom": "2.0.0", - "through2": "2.0.5", - "vinyl": "1.2.0" + "convert-source-map": "^1.1.1", + "graceful-fs": "^4.1.2", + "strip-bom": "^2.0.0", + "through2": "^2.0.0", + "vinyl": "^1.0.0" }, "dependencies": { "vinyl": { @@ -6460,8 +6460,8 @@ "integrity": "sha1-XIgDbPVl5d8FVYv8kR+GVt8hiIQ=", "dev": true, "requires": { - "clone": "1.0.4", - "clone-stats": "0.0.1", + "clone": "^1.0.0", + "clone-stats": "^0.0.1", "replace-ext": "0.0.1" } } @@ -6473,8 +6473,8 @@ "integrity": "sha512-MjfZ7DNlomplrhACwmdowPnAV3firF+3432chp1XQyy6OxbZmM7AyMwsITfglS6bGaE3msKiNeqIb0Sn3LHlyg==", "dev": true, "requires": { - "plugin-error": "1.0.1", - "svgo": "1.3.2" + "plugin-error": "^1.0.1", + "svgo": "^1.2.1" } }, "gulp-svgstore": { @@ -6483,10 +6483,10 @@ "integrity": "sha512-oiAXvkRnBBt6ZML+lit7W15ryClB45k0V9eCVW/i73EymunoQlzZal0Luj3NDrbPLbPIllL8/ltCXFa9Jv03Pg==", "dev": true, "requires": { - "cheerio": "0.22.0", - "fancy-log": "1.3.3", - "plugin-error": "0.1.2", - "vinyl": "2.2.0" + "cheerio": "0.*", + "fancy-log": "^1.3.2", + "plugin-error": "^0.1.2", + "vinyl": "^2.1.0" }, "dependencies": { "arr-diff": { @@ -6495,8 +6495,8 @@ "integrity": "sha1-aHwydYFjWI/vfeezb6vklesaOZo=", "dev": true, "requires": { - "arr-flatten": "1.1.0", - "array-slice": "0.2.3" + "arr-flatten": "^1.0.1", + "array-slice": "^0.2.3" } }, "arr-union": { @@ -6529,7 +6529,7 @@ "integrity": "sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE=", "dev": true, "requires": { - "kind-of": "1.1.0" + "kind-of": "^1.1.0" } }, "kind-of": { @@ -6544,11 +6544,11 @@ "integrity": "sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4=", "dev": true, "requires": { - "ansi-cyan": "0.1.1", - "ansi-red": "0.1.1", - "arr-diff": "1.1.0", - "arr-union": "2.1.0", - "extend-shallow": "1.1.4" + "ansi-cyan": "^0.1.1", + "ansi-red": "^0.1.1", + "arr-diff": "^1.0.1", + "arr-union": "^2.0.1", + "extend-shallow": "^1.1.2" } }, "replace-ext": { @@ -6563,12 +6563,12 @@ "integrity": "sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg==", "dev": true, "requires": { - "clone": "2.1.2", - "clone-buffer": "1.0.0", - "clone-stats": "1.0.0", - "cloneable-readable": "1.1.3", - "remove-trailing-separator": "1.1.0", - "replace-ext": "1.0.0" + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" } } } @@ -6579,10 +6579,10 @@ "integrity": "sha512-lf+jE2DALg2w32p0HRiYMlFYRYelKZPNunHp2pZccCYrrdCLOs0ItbZcN63yr2pbz116IyhUG9mD/QbtRO1FKA==", "dev": true, "requires": { - "plugin-error": "1.0.1", - "terser": "4.6.7", - "through2": "3.0.1", - "vinyl-sourcemaps-apply": "0.2.1" + "plugin-error": "^1.0.1", + "terser": "^4.0.0", + "through2": "^3.0.1", + "vinyl-sourcemaps-apply": "^0.2.1" }, "dependencies": { "through2": { @@ -6591,7 +6591,7 @@ "integrity": "sha512-M96dvTalPT3YbYLaKaCuwu+j06D/8Jfib0o/PxbVt6Amhv3dUAtW6rTV1jPgJSBG83I/e04Y6xkVdVhSRhi0ww==", "dev": true, "requires": { - "readable-stream": "3.6.0" + "readable-stream": "2 || 3" } } } @@ -6602,10 +6602,10 @@ "integrity": "sha1-aXJnSnfcMGcta3dGoXPvBQb+N7I=", "dev": true, "requires": { - "@types/gulp-util": "3.0.34", - "@types/node": "13.9.5", - "gulp-util": "3.0.8", - "tslib": "1.11.1" + "@types/gulp-util": "*", + "@types/node": "*", + "gulp-util": "^3.0.8", + "tslib": "^1.7.1" } }, "gulp-uglify": { @@ -6614,16 +6614,16 @@ "integrity": "sha512-gk1dhB74AkV2kzqPMQBLA3jPoIAPd/nlNzP2XMDSG8XZrqnlCiDGAqC+rZOumzFvB5zOphlFh6yr3lgcAb/OOg==", "dev": true, "requires": { - "array-each": "1.0.1", - "extend-shallow": "3.0.2", - "gulplog": "1.0.0", - "has-gulplog": "0.1.0", - "isobject": "3.0.1", - "make-error-cause": "1.2.2", - "safe-buffer": "5.1.2", - "through2": "2.0.5", - "uglify-js": "3.4.10", - "vinyl-sourcemaps-apply": "0.2.1" + "array-each": "^1.0.1", + "extend-shallow": "^3.0.2", + "gulplog": "^1.0.0", + "has-gulplog": "^0.1.0", + "isobject": "^3.0.1", + "make-error-cause": "^1.1.1", + "safe-buffer": "^5.1.2", + "through2": "^2.0.0", + "uglify-js": "^3.0.5", + "vinyl-sourcemaps-apply": "^0.2.0" } }, "gulp-useref": { @@ -6632,16 +6632,16 @@ "integrity": "sha512-CMntxNp9LSk0F7itgOgqGqrO5pQL7eyQt6zhWi533VMFyMch8MNrSqjR7JyxEbPkts38s++W4ZmFVjx0NLMv8g==", "dev": true, "requires": { - "event-stream": "4.0.1", - "extend": "3.0.2", - "glob": "7.1.6", - "gulp-concat": "2.6.1", - "gulp-if": "2.0.2", + "event-stream": "^4.0.1", + "extend": "^3.0.2", + "glob": "^7.1.3", + "gulp-concat": "^2.6.1", + "gulp-if": "^2.0.2", "is-relative-url": "1.0.0", - "plugin-error": "1.0.1", - "through2": "2.0.5", - "useref": "1.4.3", - "vinyl-fs": "3.0.3" + "plugin-error": "^1.0.1", + "through2": "^2.0.3", + "useref": "^1.4.1", + "vinyl-fs": "^3.0.3" }, "dependencies": { "clone": { @@ -6662,16 +6662,16 @@ "integrity": "sha1-cEXJlBOz65SIjYOrRtC0BMx73eQ=", "dev": true, "requires": { - "extend": "3.0.2", - "glob": "7.1.6", - "glob-parent": "3.1.0", - "is-negated-glob": "1.0.0", - "ordered-read-streams": "1.0.1", - "pumpify": "1.5.1", - "readable-stream": "2.3.7", - "remove-trailing-separator": "1.1.0", - "to-absolute-glob": "2.0.2", - "unique-stream": "2.3.1" + "extend": "^3.0.0", + "glob": "^7.1.1", + "glob-parent": "^3.1.0", + "is-negated-glob": "^1.0.0", + "ordered-read-streams": "^1.0.0", + "pumpify": "^1.3.5", + "readable-stream": "^2.1.5", + "remove-trailing-separator": "^1.0.1", + "to-absolute-glob": "^2.0.0", + "unique-stream": "^2.0.2" } }, "is-valid-glob": { @@ -6686,7 +6686,7 @@ "integrity": "sha1-d8DLN8QVJdZBZtmQ/61+xqDhNj4=", "dev": true, "requires": { - "readable-stream": "2.3.7" + "readable-stream": "^2.0.1" } }, "readable-stream": { @@ -6695,13 +6695,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } }, "replace-ext": { @@ -6716,8 +6716,8 @@ "integrity": "sha512-jaRjI2WxN3W1V8/FMZ9HKIBXixtiqs3SQSX4/YGIiP3gL6djW48VoZq9tDqeCWs3MT8YY5wb/zli8VW8snY1CA==", "dev": true, "requires": { - "through2": "2.0.5", - "xtend": "4.0.2" + "through2": "~2.0.0", + "xtend": "~4.0.0" } }, "to-absolute-glob": { @@ -6726,8 +6726,8 @@ "integrity": "sha1-GGX0PZ50sIItufFFt4z/fQ98hJs=", "dev": true, "requires": { - "is-absolute": "1.0.0", - "is-negated-glob": "1.0.0" + "is-absolute": "^1.0.0", + "is-negated-glob": "^1.0.0" } }, "unique-stream": { @@ -6736,8 +6736,8 @@ "integrity": "sha512-2nY4TnBE70yoxHkDli7DMazpWiP7xMdCYqU2nBRO0UB+ZpEkGsSija7MvmvnZFUeC+mrgiUfcHSr3LmRFIg4+A==", "dev": true, "requires": { - "json-stable-stringify-without-jsonify": "1.0.1", - "through2-filter": "3.0.0" + "json-stable-stringify-without-jsonify": "^1.0.1", + "through2-filter": "^3.0.0" } }, "vinyl": { @@ -6746,12 +6746,12 @@ "integrity": "sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg==", "dev": true, "requires": { - "clone": "2.1.2", - "clone-buffer": "1.0.0", - "clone-stats": "1.0.0", - "cloneable-readable": "1.1.3", - "remove-trailing-separator": "1.1.0", - "replace-ext": "1.0.0" + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" } }, "vinyl-fs": { @@ -6760,23 +6760,23 @@ "integrity": "sha512-vIu34EkyNyJxmP0jscNzWBSygh7VWhqun6RmqVfXePrOwi9lhvRs//dOaGOTRUQr4tx7/zd26Tk5WeSVZitgng==", "dev": true, "requires": { - "fs-mkdirp-stream": "1.0.0", - "glob-stream": "6.1.0", - "graceful-fs": "4.2.3", - "is-valid-glob": "1.0.0", - "lazystream": "1.0.0", - "lead": "1.0.0", - "object.assign": "4.1.0", - "pumpify": "1.5.1", - "readable-stream": "2.3.7", - "remove-bom-buffer": "3.0.0", - "remove-bom-stream": "1.2.0", - "resolve-options": "1.1.0", - "through2": "2.0.5", - "to-through": "2.0.0", - "value-or-function": "3.0.0", - "vinyl": "2.2.0", - "vinyl-sourcemap": "1.1.0" + "fs-mkdirp-stream": "^1.0.0", + "glob-stream": "^6.1.0", + "graceful-fs": "^4.0.0", + "is-valid-glob": "^1.0.0", + "lazystream": "^1.0.0", + "lead": "^1.0.0", + "object.assign": "^4.0.4", + "pumpify": "^1.3.5", + "readable-stream": "^2.3.3", + "remove-bom-buffer": "^3.0.0", + "remove-bom-stream": "^1.2.0", + "resolve-options": "^1.1.0", + "through2": "^2.0.0", + "to-through": "^2.0.0", + "value-or-function": "^3.0.0", + "vinyl": "^2.0.0", + "vinyl-sourcemap": "^1.1.0" } } } @@ -6787,24 +6787,24 @@ "integrity": "sha1-AFTh50RQLifATBh8PsxQXdVLu08=", "dev": true, "requires": { - "array-differ": "1.0.0", - "array-uniq": "1.0.3", - "beeper": "1.1.1", - "chalk": "1.1.3", - "dateformat": "2.2.0", - "fancy-log": "1.3.3", - "gulplog": "1.0.0", - "has-gulplog": "0.1.0", - "lodash._reescape": "3.0.0", - "lodash._reevaluate": "3.0.0", - "lodash._reinterpolate": "3.0.0", - "lodash.template": "3.6.2", - "minimist": "1.2.5", - "multipipe": "0.1.2", - "object-assign": "3.0.0", + "array-differ": "^1.0.0", + "array-uniq": "^1.0.2", + "beeper": "^1.0.0", + "chalk": "^1.0.0", + "dateformat": "^2.0.0", + "fancy-log": "^1.1.0", + "gulplog": "^1.0.0", + "has-gulplog": "^0.1.0", + "lodash._reescape": "^3.0.0", + "lodash._reevaluate": "^3.0.0", + "lodash._reinterpolate": "^3.0.0", + "lodash.template": "^3.0.0", + "minimist": "^1.1.0", + "multipipe": "^0.1.2", + "object-assign": "^3.0.0", "replace-ext": "0.0.1", - "through2": "2.0.5", - "vinyl": "0.5.3" + "through2": "^2.0.0", + "vinyl": "^0.5.0" }, "dependencies": { "ansi-regex": { @@ -6825,11 +6825,11 @@ "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "lodash.template": { @@ -6838,15 +6838,15 @@ "integrity": "sha1-+M3sxhaaJVvpCYrosMU9N4kx0U8=", "dev": true, "requires": { - "lodash._basecopy": "3.0.1", - "lodash._basetostring": "3.0.1", - "lodash._basevalues": "3.0.0", - "lodash._isiterateecall": "3.0.9", - "lodash._reinterpolate": "3.0.0", - "lodash.escape": "3.2.0", - "lodash.keys": "3.1.2", - "lodash.restparam": "3.6.1", - "lodash.templatesettings": "3.1.1" + "lodash._basecopy": "^3.0.0", + "lodash._basetostring": "^3.0.0", + "lodash._basevalues": "^3.0.0", + "lodash._isiterateecall": "^3.0.0", + "lodash._reinterpolate": "^3.0.0", + "lodash.escape": "^3.0.0", + "lodash.keys": "^3.0.0", + "lodash.restparam": "^3.0.0", + "lodash.templatesettings": "^3.0.0" } }, "lodash.templatesettings": { @@ -6855,8 +6855,8 @@ "integrity": "sha1-+zB4RHU7Zrnxr6VOJix0UwfbqOU=", "dev": true, "requires": { - "lodash._reinterpolate": "3.0.0", - "lodash.escape": "3.2.0" + "lodash._reinterpolate": "^3.0.0", + "lodash.escape": "^3.0.0" } }, "object-assign": { @@ -6871,7 +6871,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -6888,7 +6888,7 @@ "integrity": "sha1-4oxNRdBey77YGDY86PnFkmIp/+U=", "dev": true, "requires": { - "glogg": "1.0.2" + "glogg": "^1.0.0" } }, "gzip-size": { @@ -6897,8 +6897,8 @@ "integrity": "sha1-iuCWJX6r59acRb4rZ8RIEk/7UXw=", "dev": true, "requires": { - "duplexer": "0.1.1", - "pify": "3.0.0" + "duplexer": "^0.1.1", + "pify": "^3.0.0" }, "dependencies": { "pify": { @@ -6919,8 +6919,8 @@ "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz", "integrity": "sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g==", "requires": { - "ajv": "6.12.0", - "har-schema": "2.0.0" + "ajv": "^6.5.5", + "har-schema": "^2.0.0" } }, "has": { @@ -6929,7 +6929,7 @@ "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", "dev": true, "requires": { - "function-bind": "1.1.1" + "function-bind": "^1.1.1" } }, "has-ansi": { @@ -6938,7 +6938,7 @@ "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" }, "dependencies": { "ansi-regex": { @@ -6983,7 +6983,7 @@ "integrity": "sha1-ZBTIKRNpfaUVkDl9r7EvIpZ4Ec4=", "dev": true, "requires": { - "sparkles": "1.0.1" + "sparkles": "^1.0.0" } }, "has-symbol-support-x": { @@ -7004,7 +7004,7 @@ "integrity": "sha512-vdbKfmw+3LoOYVr+mtxHaX5a96+0f3DljYd8JOqvOLsf5mw2Otda2qCDT9qRqLAhrjyQ0h7ual5nOiASpsGNFw==", "dev": true, "requires": { - "has-symbol-support-x": "1.4.2" + "has-symbol-support-x": "^1.4.1" } }, "has-unicode": { @@ -7019,9 +7019,9 @@ "integrity": "sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc=", "dev": true, "requires": { - "get-value": "2.0.6", - "has-values": "1.0.0", - "isobject": "3.0.1" + "get-value": "^2.0.6", + "has-values": "^1.0.0", + "isobject": "^3.0.0" } }, "has-values": { @@ -7030,8 +7030,8 @@ "integrity": "sha1-lbC2P+whRmGab+V/51Yo1aOe/k8=", "dev": true, "requires": { - "is-number": "3.0.0", - "kind-of": "4.0.0" + "is-number": "^3.0.0", + "kind-of": "^4.0.0" }, "dependencies": { "kind-of": { @@ -7040,7 +7040,7 @@ "integrity": "sha1-IIE989cSkosgc3hpGkUGb65y3Vc=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } } } @@ -7057,7 +7057,7 @@ "integrity": "sha512-eSmmWE5bZTK2Nou4g0AI3zZ9rswp7GRKoKXS1BLUkvPviOqs4YTN1djQIqrXy9k5gEtdLPy86JjRwsNM9tnDcA==", "dev": true, "requires": { - "parse-passwd": "1.0.0" + "parse-passwd": "^1.0.0" } }, "hosted-git-info": { @@ -7079,13 +7079,13 @@ "integrity": "sha512-LKUKwuJDhxNa3uf/LPR/KVjm/l3rBqtYeCOAekvG8F1vItxMUpueGd94i/asDDr8/1u7InxzFA5EeGjhhG5mMA==", "dev": true, "requires": { - "camel-case": "3.0.0", - "clean-css": "4.2.3", - "commander": "2.17.1", - "he": "1.2.0", - "param-case": "2.1.1", - "relateurl": "0.2.7", - "uglify-js": "3.4.10" + "camel-case": "3.0.x", + "clean-css": "4.2.x", + "commander": "2.17.x", + "he": "1.2.x", + "param-case": "2.1.x", + "relateurl": "0.2.x", + "uglify-js": "3.4.x" }, "dependencies": { "commander": { @@ -7102,12 +7102,12 @@ "integrity": "sha512-IgieNijUMbkDovyoKObU1DUhm1iwNYE/fuifEoEHfd1oZKZDaONBSkal7Y01shxsM49R4XaMdGez3WnF9UfiCQ==", "dev": true, "requires": { - "domelementtype": "1.3.1", - "domhandler": "2.4.2", - "domutils": "1.7.0", - "entities": "1.1.2", - "inherits": "2.0.4", - "readable-stream": "3.6.0" + "domelementtype": "^1.3.1", + "domhandler": "^2.3.0", + "domutils": "^1.5.1", + "entities": "^1.1.1", + "inherits": "^2.0.1", + "readable-stream": "^3.1.1" }, "dependencies": { "entities": { @@ -7131,10 +7131,10 @@ "integrity": "sha512-ZTTX0MWrsQ2ZAhA1cejAwDLycFsd7I7nVtnkT3Ol0aqodaKW+0CTZDQ1uBv5whptCnc8e8HeRRJxRs0kmm/Qfw==", "dev": true, "requires": { - "depd": "1.1.2", + "depd": "~1.1.2", "inherits": "2.0.4", "setprototypeof": "1.1.1", - "statuses": "1.5.0", + "statuses": ">= 1.5.0 < 2", "toidentifier": "1.0.0" }, "dependencies": { @@ -7152,8 +7152,8 @@ "integrity": "sha1-ZC/cr/5S00SNK9o7AHnpQJBk2jE=", "dev": true, "requires": { - "eventemitter3": "1.2.0", - "requires-port": "1.0.0" + "eventemitter3": "1.x.x", + "requires-port": "1.x.x" } }, "http-signature": { @@ -7161,9 +7161,9 @@ "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", "requires": { - "assert-plus": "1.0.0", - "jsprim": "1.4.1", - "sshpk": "1.16.1" + "assert-plus": "^1.0.0", + "jsprim": "^1.2.2", + "sshpk": "^1.7.0" } }, "https-proxy-agent": { @@ -7172,8 +7172,8 @@ "integrity": "sha512-zoDhWrkR3of1l9QAL8/scJZyLu8j/gBkcwcaQOZh7Gyh/+uJQzGVETdgT30akuwkpL8HTRfssqI3BZuV18teDg==", "dev": true, "requires": { - "agent-base": "5.1.1", - "debug": "4.1.1" + "agent-base": "5", + "debug": "4" } }, "humanize-duration": { @@ -7188,7 +7188,7 @@ "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", "dev": true, "requires": { - "safer-buffer": "2.1.2" + "safer-buffer": ">= 2.1.2 < 3" } }, "ieee754": { @@ -7208,12 +7208,12 @@ "integrity": "sha512-8ryJBL1CN5uSHpiBMX0rJw79C9F9aJqMnjGnrd/1CafegpNuA81RBAAru/jQQEOWlOJJlpRnlcVFF6wq+Ist0A==", "dev": true, "requires": { - "file-type": "10.11.0", - "globby": "8.0.2", - "make-dir": "1.3.0", - "p-pipe": "1.2.0", - "pify": "4.0.1", - "replace-ext": "1.0.0" + "file-type": "^10.7.0", + "globby": "^8.0.1", + "make-dir": "^1.0.0", + "p-pipe": "^1.1.0", + "pify": "^4.0.1", + "replace-ext": "^1.0.0" }, "dependencies": { "globby": { @@ -7222,13 +7222,13 @@ "integrity": "sha512-yTzMmKygLp8RUpG1Ymu2VXPSJQZjNAZPD4ywgYEaG7e4tBJeUQBO8OpXrf1RCNcEs5alsoJYPAMiIHP0cmeC7w==", "dev": true, "requires": { - "array-union": "1.0.2", + "array-union": "^1.0.1", "dir-glob": "2.0.0", - "fast-glob": "2.2.7", - "glob": "7.1.6", - "ignore": "3.3.10", - "pify": "3.0.0", - "slash": "1.0.0" + "fast-glob": "^2.0.2", + "glob": "^7.1.2", + "ignore": "^3.3.5", + "pify": "^3.0.0", + "slash": "^1.0.0" }, "dependencies": { "pify": { @@ -7260,9 +7260,9 @@ "dev": true, "optional": true, "requires": { - "exec-buffer": "3.2.0", - "gifsicle": "4.0.1", - "is-gif": "3.0.0" + "exec-buffer": "^3.0.0", + "gifsicle": "^4.0.0", + "is-gif": "^3.0.0" } }, "imagemin-jpegtran": { @@ -7272,9 +7272,9 @@ "dev": true, "optional": true, "requires": { - "exec-buffer": "3.2.0", - "is-jpg": "2.0.0", - "jpegtran-bin": "4.0.0" + "exec-buffer": "^3.0.0", + "is-jpg": "^2.0.0", + "jpegtran-bin": "^4.0.0" } }, "imagemin-optipng": { @@ -7284,9 +7284,9 @@ "dev": true, "optional": true, "requires": { - "exec-buffer": "3.2.0", - "is-png": "1.1.0", - "optipng-bin": "5.1.0" + "exec-buffer": "^3.0.0", + "is-png": "^1.0.0", + "optipng-bin": "^5.0.0" } }, "imagemin-svgo": { @@ -7296,8 +7296,8 @@ "dev": true, "optional": true, "requires": { - "is-svg": "4.2.1", - "svgo": "1.3.2" + "is-svg": "^4.2.1", + "svgo": "^1.3.2" } }, "immutable": { @@ -7330,7 +7330,7 @@ "integrity": "sha1-ji1INIdCEhtKghi3oTfppSBJ3IA=", "dev": true, "requires": { - "repeating": "2.0.1" + "repeating": "^2.0.0" } }, "indexof": { @@ -7344,8 +7344,8 @@ "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "requires": { - "once": "1.4.0", - "wrappy": "1.0.2" + "once": "^1.3.0", + "wrappy": "1" } }, "inherits": { @@ -7378,8 +7378,8 @@ "dev": true, "optional": true, "requires": { - "from2": "2.3.0", - "p-is-promise": "1.1.0" + "from2": "^2.1.1", + "p-is-promise": "^1.1.0" } }, "invert-kv": { @@ -7400,8 +7400,8 @@ "integrity": "sha512-dOWoqflvcydARa360Gvv18DZ/gRuHKi2NU/wU5X1ZFzdYfH29nkiNZsF3mp4OJ3H4yo9Mx8A/uAGNzpzPN3yBA==", "dev": true, "requires": { - "is-relative": "1.0.0", - "is-windows": "1.0.2" + "is-relative": "^1.0.0", + "is-windows": "^1.0.1" } }, "is-absolute-url": { @@ -7416,7 +7416,7 @@ "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", "dev": true, "requires": { - "kind-of": "3.2.2" + "kind-of": "^3.0.2" }, "dependencies": { "kind-of": { @@ -7425,7 +7425,7 @@ "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } } } @@ -7442,7 +7442,7 @@ "integrity": "sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg=", "dev": true, "requires": { - "binary-extensions": "1.13.1" + "binary-extensions": "^1.0.0" } }, "is-buffer": { @@ -7463,7 +7463,7 @@ "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", "dev": true, "requires": { - "kind-of": "3.2.2" + "kind-of": "^3.0.2" }, "dependencies": { "kind-of": { @@ -7472,7 +7472,7 @@ "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } } } @@ -7489,9 +7489,9 @@ "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", "dev": true, "requires": { - "is-accessor-descriptor": "0.1.6", - "is-data-descriptor": "0.1.4", - "kind-of": "5.1.0" + "is-accessor-descriptor": "^0.1.6", + "is-data-descriptor": "^0.1.4", + "kind-of": "^5.0.0" }, "dependencies": { "kind-of": { @@ -7514,7 +7514,7 @@ "integrity": "sha1-IjgJj8Ih3gvPpdnqxMRdY4qhxTQ=", "dev": true, "requires": { - "is-primitive": "2.0.0" + "is-primitive": "^2.0.0" } }, "is-extendable": { @@ -7541,7 +7541,7 @@ "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", "dev": true, "requires": { - "number-is-nan": "1.0.1" + "number-is-nan": "^1.0.0" } }, "is-gif": { @@ -7551,7 +7551,7 @@ "dev": true, "optional": true, "requires": { - "file-type": "10.11.0" + "file-type": "^10.4.0" } }, "is-glob": { @@ -7560,7 +7560,7 @@ "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", "dev": true, "requires": { - "is-extglob": "2.1.1" + "is-extglob": "^2.1.1" } }, "is-jpg": { @@ -7588,7 +7588,7 @@ "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", "dev": true, "requires": { - "kind-of": "3.2.2" + "kind-of": "^3.0.2" }, "dependencies": { "kind-of": { @@ -7597,7 +7597,7 @@ "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } } } @@ -7608,7 +7608,7 @@ "integrity": "sha512-6rZi3ezCyFcn5L71ywzz2bS5b2Igl1En3eTlZlvKjpz1n3IZLAYMbKYAIQgFmEu0GENg92ziU/faEOA/aixjbA==", "dev": true, "requires": { - "lodash.isfinite": "3.3.2" + "lodash.isfinite": "^3.3.2" } }, "is-obj": { @@ -7634,7 +7634,7 @@ "integrity": "sha512-rNocXHgipO+rvnP6dk3zI20RpOtrAM/kzbB258Uw5BWr3TpXi861yzjo16Dn4hUox07iw5AyeMLHWsujkjzvRQ==", "dev": true, "requires": { - "is-path-inside": "2.1.0" + "is-path-inside": "^2.1.0" } }, "is-path-inside": { @@ -7643,7 +7643,7 @@ "integrity": "sha512-wiyhTzfDWsvwAW53OBWF5zuvaOGlZ6PwYxAbPVDhpm+gM09xKQGjBq/8uYN12aDvMxnAnq3dxTyoSoRNmg5YFg==", "dev": true, "requires": { - "path-is-inside": "1.0.2" + "path-is-inside": "^1.0.2" } }, "is-plain-obj": { @@ -7658,7 +7658,7 @@ "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", "dev": true, "requires": { - "isobject": "3.0.1" + "isobject": "^3.0.1" } }, "is-png": { @@ -7686,7 +7686,7 @@ "integrity": "sha512-vlKW17SNq44owv5AQR3Cq0bQPEb8+kF3UKZ2fiZNOWtztYE5i0CzCZxFDwO58qAOWtxdBRVO/V5Qin1wjCqFYQ==", "dev": true, "requires": { - "has": "1.0.3" + "has": "^1.0.3" } }, "is-regexp": { @@ -7700,7 +7700,7 @@ "integrity": "sha512-Kw/ReK0iqwKeu0MITLFuj0jbPAmEiOsIwyIXvvbfa6QfmN9pkD1M+8pdk7Rl/dTKbH34/XBFMbgD4iMJhLQbGA==", "dev": true, "requires": { - "is-unc-path": "1.0.0" + "is-unc-path": "^1.0.0" } }, "is-relative-url": { @@ -7709,7 +7709,7 @@ "integrity": "sha1-h6nTXop4m0ngebTX1p1kYS6ODh8=", "dev": true, "requires": { - "is-absolute-url": "1.0.0" + "is-absolute-url": "^1.0.0" } }, "is-retry-allowed": { @@ -7737,7 +7737,7 @@ "dev": true, "optional": true, "requires": { - "html-comment-regex": "1.1.2" + "html-comment-regex": "^1.1.2" } }, "is-symbol": { @@ -7746,7 +7746,7 @@ "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", "dev": true, "requires": { - "has-symbols": "1.0.1" + "has-symbols": "^1.0.1" } }, "is-typedarray": { @@ -7760,7 +7760,7 @@ "integrity": "sha512-mrGpVd0fs7WWLfVsStvgF6iEJnbjDFZh9/emhRDcGWTduTfNHd9CHeUwH3gYIjdbwo4On6hunkztwOaAw0yllQ==", "dev": true, "requires": { - "unc-path-regex": "0.1.2" + "unc-path-regex": "^0.1.2" } }, "is-utf8": { @@ -7798,7 +7798,7 @@ "integrity": "sha512-8cJBL5tTd2OS0dM4jz07wQd5g0dCCqIhUxPIGtZfa5L6hWlvV5MHTITy/DBAsF+Oe2LS1X3krBUhNwaGUWpWxw==", "dev": true, "requires": { - "buffer-alloc": "1.2.0" + "buffer-alloc": "^1.2.0" } }, "isexe": { @@ -7824,8 +7824,8 @@ "integrity": "sha512-1P/yWsxPlDtn7QeRD+ULKQPaIaN6yF368GZ2vDfv0AL0NwpStafjWCDDdn0k8wgFMWpVAqG7oJhxHnlud42i9w==", "dev": true, "requires": { - "has-to-string-tag-x": "1.4.1", - "is-object": "1.0.1" + "has-to-string-tag-x": "^1.2.0", + "is-object": "^1.0.1" } }, "jpegtran-bin": { @@ -7835,9 +7835,9 @@ "dev": true, "optional": true, "requires": { - "bin-build": "3.0.0", - "bin-wrapper": "4.1.0", - "logalot": "2.1.0" + "bin-build": "^3.0.0", + "bin-wrapper": "^4.0.0", + "logalot": "^2.0.0" } }, "js-base64": { @@ -7852,8 +7852,8 @@ "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", "dev": true, "requires": { - "argparse": "1.0.10", - "esprima": "4.0.1" + "argparse": "^1.0.7", + "esprima": "^4.0.0" } }, "jsbn": { @@ -7867,12 +7867,12 @@ "integrity": "sha1-JCCCosA1rgP9gQROBXDMQgjPbmE=", "dev": true, "requires": { - "beeper": "1.1.1", - "chalk": "1.1.3", - "log-symbols": "1.0.2", - "plur": "2.1.2", - "string-length": "1.0.1", - "text-table": "0.2.0" + "beeper": "^1.1.0", + "chalk": "^1.0.0", + "log-symbols": "^1.0.0", + "plur": "^2.1.0", + "string-length": "^1.0.0", + "text-table": "^0.2.0" }, "dependencies": { "ansi-regex": { @@ -7893,11 +7893,11 @@ "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "irregular-plurals": { @@ -7912,7 +7912,7 @@ "integrity": "sha1-dIJFLBoPUI4+NE6uwxLJHCncZVo=", "dev": true, "requires": { - "irregular-plurals": "1.4.0" + "irregular-plurals": "^1.0.0" } }, "strip-ansi": { @@ -7921,7 +7921,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -7965,7 +7965,7 @@ "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", "integrity": "sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss=", "requires": { - "graceful-fs": "4.2.3" + "graceful-fs": "^4.1.6" } }, "jsprim": { @@ -8001,7 +8001,7 @@ "integrity": "sha1-QIhDO0azsbolnXh4XY6W9zugJDk=", "dev": true, "requires": { - "graceful-fs": "4.2.3" + "graceful-fs": "^4.1.9" } }, "lazystream": { @@ -8009,7 +8009,7 @@ "resolved": "https://registry.npmjs.org/lazystream/-/lazystream-1.0.0.tgz", "integrity": "sha1-9plf4PggOS9hOWvolGJAe7dxaOQ=", "requires": { - "readable-stream": "2.3.7" + "readable-stream": "^2.0.5" }, "dependencies": { "readable-stream": { @@ -8017,13 +8017,13 @@ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -8034,7 +8034,7 @@ "integrity": "sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU=", "dev": true, "requires": { - "invert-kv": "1.0.0" + "invert-kv": "^1.0.0" } }, "lead": { @@ -8043,7 +8043,7 @@ "integrity": "sha1-bxT5mje+Op3XhPVJVpDlkDRm7kI=", "dev": true, "requires": { - "flush-write-stream": "1.1.1" + "flush-write-stream": "^1.0.2" } }, "liftoff": { @@ -8052,14 +8052,14 @@ "integrity": "sha1-IAkpG7Mc6oYbvxCnwVooyvdcMew=", "dev": true, "requires": { - "extend": "3.0.2", - "findup-sync": "2.0.0", - "fined": "1.2.0", - "flagged-respawn": "1.0.1", - "is-plain-object": "2.0.4", - "object.map": "1.0.1", - "rechoir": "0.6.2", - "resolve": "1.15.1" + "extend": "^3.0.0", + "findup-sync": "^2.0.0", + "fined": "^1.0.1", + "flagged-respawn": "^1.0.0", + "is-plain-object": "^2.0.4", + "object.map": "^1.0.0", + "rechoir": "^0.6.2", + "resolve": "^1.1.7" } }, "limiter": { @@ -8074,11 +8074,11 @@ "integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "parse-json": "2.2.0", - "pify": "2.3.0", - "pinkie-promise": "2.0.1", - "strip-bom": "2.0.0" + "graceful-fs": "^4.1.2", + "parse-json": "^2.2.0", + "pify": "^2.0.0", + "pinkie-promise": "^2.0.0", + "strip-bom": "^2.0.0" } }, "localtunnel": { @@ -8099,19 +8099,19 @@ "integrity": "sha1-eC7CHvQDNF+DCoCMo9UTr1YGUgg=", "dev": true, "requires": { - "camelcase": "3.0.0", - "cliui": "3.2.0", - "decamelize": "1.2.0", - "get-caller-file": "1.0.3", - "os-locale": "1.4.0", - "read-pkg-up": "1.0.1", - "require-directory": "2.1.1", - "require-main-filename": "1.0.1", - "set-blocking": "2.0.0", - "string-width": "1.0.2", - "which-module": "1.0.0", - "y18n": "3.2.1", - "yargs-parser": "4.2.1" + "camelcase": "^3.0.0", + "cliui": "^3.2.0", + "decamelize": "^1.1.1", + "get-caller-file": "^1.0.1", + "os-locale": "^1.4.0", + "read-pkg-up": "^1.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^1.0.1", + "set-blocking": "^2.0.0", + "string-width": "^1.0.2", + "which-module": "^1.0.0", + "y18n": "^3.2.1", + "yargs-parser": "^4.2.0" } } } @@ -8122,8 +8122,8 @@ "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", "dev": true, "requires": { - "p-locate": "3.0.0", - "path-exists": "3.0.0" + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" }, "dependencies": { "path-exists": { @@ -8231,7 +8231,7 @@ "integrity": "sha1-mV7g3BjBtIzJLv+ucaEKq1tIdpg=", "dev": true, "requires": { - "lodash._root": "3.0.1" + "lodash._root": "^3.0.0" } }, "lodash.filter": { @@ -8291,9 +8291,9 @@ "integrity": "sha1-TbwEcrFWvlCgsoaFXRvQsMZWCYo=", "dev": true, "requires": { - "lodash._getnative": "3.9.1", - "lodash.isarguments": "3.1.0", - "lodash.isarray": "3.0.4" + "lodash._getnative": "^3.0.0", + "lodash.isarguments": "^3.0.0", + "lodash.isarray": "^3.0.0" } }, "lodash.map": { @@ -8342,8 +8342,8 @@ "resolved": "https://registry.npmjs.org/lodash.template/-/lodash.template-4.5.0.tgz", "integrity": "sha512-84vYFxIkmidUiFxidA/KjjH9pAycqW+h980j7Fuz5qxRtO9pgB7MDFTdys1N7A5mcucRiDyEq4fusljItR1T/A==", "requires": { - "lodash._reinterpolate": "3.0.0", - "lodash.templatesettings": "4.2.0" + "lodash._reinterpolate": "^3.0.0", + "lodash.templatesettings": "^4.0.0" } }, "lodash.templatesettings": { @@ -8351,7 +8351,7 @@ "resolved": "https://registry.npmjs.org/lodash.templatesettings/-/lodash.templatesettings-4.2.0.tgz", "integrity": "sha512-stgLz+i3Aa9mZgnjr/O+v9ruKZsPsndy7qPZOchbqk2cnTU1ZaldKK+v7m54WoKIyxiuMZTKT2H81F8BeAc3ZQ==", "requires": { - "lodash._reinterpolate": "3.0.0" + "lodash._reinterpolate": "^3.0.0" } }, "lodash.union": { @@ -8370,7 +8370,7 @@ "integrity": "sha1-N2/3tY6jCGoPCfrMdGF+ylAeGhg=", "dev": true, "requires": { - "chalk": "1.1.3" + "chalk": "^1.0.0" }, "dependencies": { "ansi-regex": { @@ -8391,11 +8391,11 @@ "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "strip-ansi": { @@ -8404,7 +8404,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -8422,8 +8422,8 @@ "dev": true, "optional": true, "requires": { - "figures": "1.7.0", - "squeak": "1.3.0" + "figures": "^1.3.5", + "squeak": "^1.0.0" } }, "loglevel": { @@ -8449,8 +8449,8 @@ "integrity": "sha1-W0b4AUft7leIcPCG0Eghz5mOVR8=", "dev": true, "requires": { - "currently-unhandled": "0.4.1", - "signal-exit": "3.0.3" + "currently-unhandled": "^0.4.1", + "signal-exit": "^3.0.0" } }, "lower-case": { @@ -8472,10 +8472,10 @@ "dev": true, "optional": true, "requires": { - "get-stdin": "4.0.1", - "indent-string": "2.1.0", - "longest": "1.0.1", - "meow": "3.7.0" + "get-stdin": "^4.0.1", + "indent-string": "^2.1.0", + "longest": "^1.0.0", + "meow": "^3.3.0" } }, "lru-cache": { @@ -8484,8 +8484,8 @@ "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", "dev": true, "requires": { - "pseudomap": "1.0.2", - "yallist": "2.1.2" + "pseudomap": "^1.0.2", + "yallist": "^2.1.2" } }, "make-dir": { @@ -8494,7 +8494,7 @@ "integrity": "sha512-2w31R7SJtieJJnQtGc7RVL2StM2vGYVfqUOvUDxH6bC6aJTxPxTF0GnIgCyu7tjockiUWAYQRbxa7vKn34s5sQ==", "dev": true, "requires": { - "pify": "3.0.0" + "pify": "^3.0.0" }, "dependencies": { "pify": { @@ -8517,7 +8517,7 @@ "integrity": "sha1-3wOI/NCzeBbf8KX7gQiTl3fcvJ0=", "dev": true, "requires": { - "make-error": "1.3.6" + "make-error": "^1.2.0" } }, "make-iterator": { @@ -8526,7 +8526,7 @@ "integrity": "sha512-pxiuXh0iVEq7VM7KMIhs5gxsfxCux2URptUQaXo4iZZJxBAzTPOLE2BumO5dbfVYq/hBJFBR/a1mFDmOx5AGmw==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.2" } }, "map-cache": { @@ -8553,7 +8553,7 @@ "integrity": "sha1-7Nyo8TFE5mDxtb1B8S80edmN+48=", "dev": true, "requires": { - "object-visit": "1.0.1" + "object-visit": "^1.0.0" } }, "math-random": { @@ -8574,16 +8574,16 @@ "integrity": "sha1-cstmi0JSKCkKu/qFaJJYcwioAfs=", "dev": true, "requires": { - "camelcase-keys": "2.1.0", - "decamelize": "1.2.0", - "loud-rejection": "1.6.0", - "map-obj": "1.0.1", - "minimist": "1.2.5", - "normalize-package-data": "2.5.0", - "object-assign": "4.1.1", - "read-pkg-up": "1.0.1", - "redent": "1.0.0", - "trim-newlines": "1.0.0" + "camelcase-keys": "^2.0.0", + "decamelize": "^1.1.2", + "loud-rejection": "^1.0.0", + "map-obj": "^1.0.1", + "minimist": "^1.1.3", + "normalize-package-data": "^2.3.4", + "object-assign": "^4.0.1", + "read-pkg-up": "^1.0.1", + "redent": "^1.0.0", + "trim-newlines": "^1.0.0" } }, "merge": { @@ -8610,19 +8610,19 @@ "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", "dev": true, "requires": { - "arr-diff": "4.0.0", - "array-unique": "0.3.2", - "braces": "2.3.2", - "define-property": "2.0.2", - "extend-shallow": "3.0.2", - "extglob": "2.0.4", - "fragment-cache": "0.2.1", - "kind-of": "6.0.3", - "nanomatch": "1.2.13", - "object.pick": "1.3.0", - "regex-not": "1.0.2", - "snapdragon": "0.8.2", - "to-regex": "3.0.2" + "arr-diff": "^4.0.0", + "array-unique": "^0.3.2", + "braces": "^2.3.1", + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "extglob": "^2.0.4", + "fragment-cache": "^0.2.1", + "kind-of": "^6.0.2", + "nanomatch": "^1.2.9", + "object.pick": "^1.3.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.2" } }, "mime": { @@ -8655,7 +8655,7 @@ "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "requires": { - "brace-expansion": "1.1.11" + "brace-expansion": "^1.1.7" } }, "minimist": { @@ -8676,8 +8676,8 @@ "integrity": "sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA==", "dev": true, "requires": { - "for-in": "1.0.2", - "is-extendable": "1.0.1" + "for-in": "^1.0.2", + "is-extendable": "^1.0.1" }, "dependencies": { "is-extendable": { @@ -8686,7 +8686,7 @@ "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", "dev": true, "requires": { - "is-plain-object": "2.0.4" + "is-plain-object": "^2.0.4" } } } @@ -8697,7 +8697,7 @@ "integrity": "sha512-iG9AK/dJLtJ0XNgTuDbSyNS3zECqDlAhnQW4CsNxBG3LQJBbHmRX1egw39DmtOdCAqY+dKXV+sgPgilNWUKMVw==", "dev": true, "requires": { - "minimist": "1.2.5" + "minimist": "^1.2.5" } }, "mocha": { @@ -8740,12 +8740,12 @@ "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", "dev": true, "requires": { - "fs.realpath": "1.0.0", - "inflight": "1.0.6", - "inherits": "2.0.4", - "minimatch": "3.0.4", - "once": "1.4.0", - "path-is-absolute": "1.0.1" + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" } }, "has-flag": { @@ -8787,7 +8787,7 @@ "integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -8810,10 +8810,10 @@ "integrity": "sha1-nHkGoi+0wCkZ4vX3UWG0zb1LKis=", "dev": true, "requires": { - "array-differ": "1.0.0", - "array-union": "1.0.2", - "arrify": "1.0.1", - "minimatch": "3.0.4" + "array-differ": "^1.0.0", + "array-union": "^1.0.1", + "arrify": "^1.0.0", + "minimatch": "^3.0.0" } }, "multipipe": { @@ -8837,17 +8837,17 @@ "integrity": "sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==", "dev": true, "requires": { - "arr-diff": "4.0.0", - "array-unique": "0.3.2", - "define-property": "2.0.2", - "extend-shallow": "3.0.2", - "fragment-cache": "0.2.1", - "is-windows": "1.0.2", - "kind-of": "6.0.3", - "object.pick": "1.3.0", - "regex-not": "1.0.2", - "snapdragon": "0.8.2", - "to-regex": "3.0.2" + "arr-diff": "^4.0.0", + "array-unique": "^0.3.2", + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "fragment-cache": "^0.2.1", + "is-windows": "^1.0.2", + "kind-of": "^6.0.2", + "object.pick": "^1.3.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" } }, "natives": { @@ -8874,7 +8874,7 @@ "integrity": "sha512-rmTZ9kz+f3rCvK2TD1Ue/oZlns7OGoIWP4fc3llxxRXlOkHKoWPPWJOfFYpITabSow43QJbRIoHQXtt10VldyQ==", "dev": true, "requires": { - "lower-case": "1.1.4" + "lower-case": "^1.1.1" } }, "node-gyp": { @@ -8883,18 +8883,18 @@ "integrity": "sha512-3g8lYefrRRzvGeSowdJKAKyks8oUpLEd/DyPV4eMhVlhJ0aNaZqIrNUIPuEWWTAoPqyFkfGrM67MC69baqn6vA==", "dev": true, "requires": { - "fstream": "1.0.12", - "glob": "7.1.6", - "graceful-fs": "4.2.3", - "mkdirp": "0.5.4", - "nopt": "3.0.6", - "npmlog": "4.1.2", - "osenv": "0.1.5", - "request": "2.88.2", - "rimraf": "2.7.1", - "semver": "5.3.0", - "tar": "2.2.1", - "which": "1.3.1" + "fstream": "^1.0.0", + "glob": "^7.0.3", + "graceful-fs": "^4.1.2", + "mkdirp": "^0.5.0", + "nopt": "2 || 3", + "npmlog": "0 || 1 || 2 || 3 || 4", + "osenv": "0", + "request": "^2.87.0", + "rimraf": "2", + "semver": "~5.3.0", + "tar": "^2.0.0", + "which": "1" }, "dependencies": { "nopt": { @@ -8903,7 +8903,7 @@ "integrity": "sha1-xkZdvwirzU2zWTF/eaxopkayj/k=", "dev": true, "requires": { - "abbrev": "1.1.1" + "abbrev": "1" } }, "semver": { @@ -8926,23 +8926,23 @@ "integrity": "sha512-TTWFx+ZhyDx1Biiez2nB0L3YrCZ/8oHagaDalbuBSlqXgUPsdkUSzJsVxeDO9LtPB49+Fh3WQl3slABo6AotNw==", "dev": true, "requires": { - "async-foreach": "0.1.3", - "chalk": "1.1.3", - "cross-spawn": "3.0.1", - "gaze": "1.1.3", - "get-stdin": "4.0.1", - "glob": "7.1.6", - "in-publish": "2.0.1", - "lodash": "4.17.15", - "meow": "3.7.0", - "mkdirp": "0.5.4", - "nan": "2.14.0", - "node-gyp": "3.8.0", - "npmlog": "4.1.2", - "request": "2.88.2", - "sass-graph": "2.2.4", - "stdout-stream": "1.4.1", - "true-case-path": "1.0.3" + "async-foreach": "^0.1.3", + "chalk": "^1.1.1", + "cross-spawn": "^3.0.0", + "gaze": "^1.0.0", + "get-stdin": "^4.0.1", + "glob": "^7.0.3", + "in-publish": "^2.0.0", + "lodash": "^4.17.15", + "meow": "^3.7.0", + "mkdirp": "^0.5.1", + "nan": "^2.13.2", + "node-gyp": "^3.8.0", + "npmlog": "^4.0.0", + "request": "^2.88.0", + "sass-graph": "^2.2.4", + "stdout-stream": "^1.4.0", + "true-case-path": "^1.0.2" }, "dependencies": { "ansi-regex": { @@ -8963,11 +8963,11 @@ "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "cross-spawn": { @@ -8976,8 +8976,8 @@ "integrity": "sha1-ElYDfsufDF9549bvE14wdwGEuYI=", "dev": true, "requires": { - "lru-cache": "4.1.5", - "which": "1.3.1" + "lru-cache": "^4.0.1", + "which": "^1.2.9" } }, "gaze": { @@ -8986,7 +8986,7 @@ "integrity": "sha512-BRdNm8hbWzFzWHERTrejLqwHDfS4GibPoq5wjTPIoJHoBtKGPg3xAFfxmM+9ztbXelxcf2hwQcaz1PtmFeue8g==", "dev": true, "requires": { - "globule": "1.3.1" + "globule": "^1.0.0" } }, "globule": { @@ -8995,9 +8995,9 @@ "integrity": "sha512-OVyWOHgw29yosRHCHo7NncwR1hW5ew0W/UrvtwvjefVJeQ26q4/8r8FmPsSF1hJ93IgWkyv16pCTz6WblMzm/g==", "dev": true, "requires": { - "glob": "7.1.6", - "lodash": "4.17.15", - "minimatch": "3.0.4" + "glob": "~7.1.1", + "lodash": "~4.17.12", + "minimatch": "~3.0.2" } }, "strip-ansi": { @@ -9006,7 +9006,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -9023,7 +9023,7 @@ "integrity": "sha1-bd0hvSoxQXuScn3Vhfim83YI6+4=", "dev": true, "requires": { - "abbrev": "1.1.1" + "abbrev": "1" } }, "normalize-package-data": { @@ -9032,10 +9032,10 @@ "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", "dev": true, "requires": { - "hosted-git-info": "2.8.8", - "resolve": "1.15.1", - "semver": "5.7.1", - "validate-npm-package-license": "3.0.4" + "hosted-git-info": "^2.1.4", + "resolve": "^1.10.0", + "semver": "2 || 3 || 4 || 5", + "validate-npm-package-license": "^3.0.1" } }, "normalize-path": { @@ -9056,9 +9056,9 @@ "dev": true, "optional": true, "requires": { - "prepend-http": "2.0.0", - "query-string": "5.1.1", - "sort-keys": "2.0.0" + "prepend-http": "^2.0.0", + "query-string": "^5.0.1", + "sort-keys": "^2.0.0" }, "dependencies": { "prepend-http": { @@ -9075,7 +9075,7 @@ "dev": true, "optional": true, "requires": { - "is-plain-obj": "1.1.0" + "is-plain-obj": "^1.0.0" } } } @@ -9086,7 +9086,7 @@ "integrity": "sha512-KGvQ0cB70AQfg107Xvs/Fbu+dGmZoTRJp2TaPwcwQm3/7PteUyN2BCgk8KBMPGBUXZdVwyWS8fDCGFygBm19UQ==", "dev": true, "requires": { - "once": "1.4.0" + "once": "^1.3.2" } }, "npm-conf": { @@ -9095,8 +9095,8 @@ "integrity": "sha512-Yic4bZHJOt9RCFbRP3GgpqhScOY4HH3V2P8yBj6CeYq118Qr+BLXqT2JvpJ00mryLESpgOxf5XlFv4ZjXxLScw==", "dev": true, "requires": { - "config-chain": "1.1.12", - "pify": "3.0.0" + "config-chain": "^1.1.11", + "pify": "^3.0.0" }, "dependencies": { "pify": { @@ -9113,7 +9113,7 @@ "integrity": "sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8=", "dev": true, "requires": { - "path-key": "2.0.1" + "path-key": "^2.0.0" } }, "npmlog": { @@ -9122,10 +9122,10 @@ "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", "dev": true, "requires": { - "are-we-there-yet": "1.1.5", - "console-control-strings": "1.1.0", - "gauge": "2.7.4", - "set-blocking": "2.0.0" + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" } }, "nth-check": { @@ -9134,7 +9134,7 @@ "integrity": "sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg==", "dev": true, "requires": { - "boolbase": "1.0.0" + "boolbase": "~1.0.0" } }, "num2fraction": { @@ -9172,9 +9172,9 @@ "integrity": "sha1-fn2Fi3gb18mRpBupde04EnVOmYw=", "dev": true, "requires": { - "copy-descriptor": "0.1.1", - "define-property": "0.2.5", - "kind-of": "3.2.2" + "copy-descriptor": "^0.1.0", + "define-property": "^0.2.5", + "kind-of": "^3.0.3" }, "dependencies": { "define-property": { @@ -9183,7 +9183,7 @@ "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, "requires": { - "is-descriptor": "0.1.6" + "is-descriptor": "^0.1.0" } }, "kind-of": { @@ -9192,7 +9192,7 @@ "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } } } @@ -9221,7 +9221,7 @@ "integrity": "sha1-95xEk68MU3e1n+OdOV5BBC3QRbs=", "dev": true, "requires": { - "isobject": "3.0.1" + "isobject": "^3.0.0" } }, "object.assign": { @@ -9230,10 +9230,10 @@ "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", "dev": true, "requires": { - "define-properties": "1.1.3", - "function-bind": "1.1.1", - "has-symbols": "1.0.1", - "object-keys": "1.1.1" + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" } }, "object.defaults": { @@ -9242,10 +9242,10 @@ "integrity": "sha1-On+GgzS0B96gbaFtiNXNKeQ1/s8=", "dev": true, "requires": { - "array-each": "1.0.1", - "array-slice": "1.1.0", - "for-own": "1.0.0", - "isobject": "3.0.1" + "array-each": "^1.0.1", + "array-slice": "^1.0.0", + "for-own": "^1.0.0", + "isobject": "^3.0.0" }, "dependencies": { "for-own": { @@ -9254,7 +9254,7 @@ "integrity": "sha1-xjMy9BXO3EsE2/5wz4NklMU8tEs=", "dev": true, "requires": { - "for-in": "1.0.2" + "for-in": "^1.0.1" } } } @@ -9265,8 +9265,8 @@ "integrity": "sha512-Z53Oah9A3TdLoblT7VKJaTDdXdT+lQO+cNpKVnya5JDe9uLvzu1YyY1yFDFrcxrlRgWrEFH0jJtD/IbuwjcEVg==", "dev": true, "requires": { - "define-properties": "1.1.3", - "es-abstract": "1.17.5" + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1" } }, "object.map": { @@ -9275,8 +9275,8 @@ "integrity": "sha1-z4Plncj8wK1fQlDh94s7gb2AHTc=", "dev": true, "requires": { - "for-own": "1.0.0", - "make-iterator": "1.0.1" + "for-own": "^1.0.0", + "make-iterator": "^1.0.0" }, "dependencies": { "for-own": { @@ -9285,7 +9285,7 @@ "integrity": "sha1-xjMy9BXO3EsE2/5wz4NklMU8tEs=", "dev": true, "requires": { - "for-in": "1.0.2" + "for-in": "^1.0.1" } } } @@ -9296,8 +9296,8 @@ "integrity": "sha1-Gpx0SCnznbuFjHbKNXmuKlTr0fo=", "dev": true, "requires": { - "for-own": "0.1.5", - "is-extendable": "0.1.1" + "for-own": "^0.1.4", + "is-extendable": "^0.1.1" } }, "object.pick": { @@ -9306,7 +9306,7 @@ "integrity": "sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c=", "dev": true, "requires": { - "isobject": "3.0.1" + "isobject": "^3.0.1" } }, "object.values": { @@ -9315,10 +9315,10 @@ "integrity": "sha512-WTa54g2K8iu0kmS/us18jEmdv1a4Wi//BZ/DTVYEcH0XhLM5NYdpDHja3gt57VrZLcNAO2WGA+KpWsDBaHt6eA==", "dev": true, "requires": { - "define-properties": "1.1.3", - "es-abstract": "1.17.5", - "function-bind": "1.1.1", - "has": "1.0.3" + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "has": "^1.0.3" } }, "on-finished": { @@ -9335,7 +9335,7 @@ "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "requires": { - "wrappy": "1.0.2" + "wrappy": "1" } }, "openurl": { @@ -9350,7 +9350,7 @@ "integrity": "sha512-bYJHo/LOmoTd+pfiYhfZDnf9zekVJrY+cnS2a5F2x+w5ppvTqObojTP7WiFG+kVZs9Inw+qQ/lw7TroWwhdd2g==", "dev": true, "requires": { - "is-wsl": "1.1.0" + "is-wsl": "^1.1.0" } }, "optimist": { @@ -9359,8 +9359,8 @@ "integrity": "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=", "dev": true, "requires": { - "minimist": "0.0.10", - "wordwrap": "0.0.3" + "minimist": "~0.0.1", + "wordwrap": "~0.0.2" }, "dependencies": { "minimist": { @@ -9378,9 +9378,9 @@ "dev": true, "optional": true, "requires": { - "bin-build": "3.0.0", - "bin-wrapper": "4.1.0", - "logalot": "2.1.0" + "bin-build": "^3.0.0", + "bin-wrapper": "^4.0.0", + "logalot": "^2.0.0" } }, "orchestrator": { @@ -9389,9 +9389,9 @@ "integrity": "sha1-FOfp4nZPcxX7rBhOUGx6pt+UrX4=", "dev": true, "requires": { - "end-of-stream": "0.1.5", - "sequencify": "0.0.7", - "stream-consume": "0.1.1" + "end-of-stream": "~0.1.5", + "sequencify": "~0.0.7", + "stream-consume": "~0.1.0" }, "dependencies": { "end-of-stream": { @@ -9400,7 +9400,7 @@ "integrity": "sha1-jhdyBsPICDfYVjLouTWd/osvbq8=", "dev": true, "requires": { - "once": "1.3.3" + "once": "~1.3.0" } }, "once": { @@ -9409,7 +9409,7 @@ "integrity": "sha1-suJhVXzkwxTsgwTz+oJmPkKXyiA=", "dev": true, "requires": { - "wrappy": "1.0.2" + "wrappy": "1" } } } @@ -9427,7 +9427,7 @@ "dev": true, "optional": true, "requires": { - "arch": "2.1.1" + "arch": "^2.1.0" } }, "os-homedir": { @@ -9442,7 +9442,7 @@ "integrity": "sha1-IPnxeuKe00XoveWDsT0gCYA8FNk=", "dev": true, "requires": { - "lcid": "1.0.0" + "lcid": "^1.0.0" } }, "os-tmpdir": { @@ -9457,8 +9457,8 @@ "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==", "dev": true, "requires": { - "os-homedir": "1.0.2", - "os-tmpdir": "1.0.2" + "os-homedir": "^1.0.0", + "os-tmpdir": "^1.0.0" } }, "p-cancelable": { @@ -9475,7 +9475,7 @@ "dev": true, "optional": true, "requires": { - "p-timeout": "1.2.1" + "p-timeout": "^1.1.1" } }, "p-finally": { @@ -9497,7 +9497,7 @@ "integrity": "sha512-WGR+xHecKTr7EbUEhyLSh5Dube9JtdiG78ufaeLxTgpudf/20KqyMioIUZJAezlTIi6evxuoUs9YXc11cU+yzQ==", "dev": true, "requires": { - "p-try": "2.2.0" + "p-try": "^2.0.0" } }, "p-locate": { @@ -9506,7 +9506,7 @@ "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", "dev": true, "requires": { - "p-limit": "2.2.2" + "p-limit": "^2.0.0" } }, "p-map": { @@ -9522,7 +9522,7 @@ "dev": true, "optional": true, "requires": { - "p-reduce": "1.0.0" + "p-reduce": "^1.0.0" } }, "p-pipe": { @@ -9544,7 +9544,7 @@ "integrity": "sha1-XrOzU7f86Z8QGhA4iAuwVOu+o4Y=", "dev": true, "requires": { - "p-finally": "1.0.0" + "p-finally": "^1.0.0" } }, "p-try": { @@ -9559,7 +9559,7 @@ "integrity": "sha1-35T9jPZTHs915r75oIWPvHK+Ikc=", "dev": true, "requires": { - "no-case": "2.3.2" + "no-case": "^2.2.0" } }, "parse-filepath": { @@ -9568,9 +9568,9 @@ "integrity": "sha1-pjISf1Oq89FYdvWHLz/6x2PWyJE=", "dev": true, "requires": { - "is-absolute": "1.0.0", - "map-cache": "0.2.2", - "path-root": "0.1.1" + "is-absolute": "^1.0.0", + "map-cache": "^0.2.0", + "path-root": "^0.1.1" } }, "parse-glob": { @@ -9579,10 +9579,10 @@ "integrity": "sha1-ssN2z7EfNVE7rdFz7wu246OIORw=", "dev": true, "requires": { - "glob-base": "0.3.0", - "is-dotfile": "1.0.3", - "is-extglob": "1.0.0", - "is-glob": "2.0.1" + "glob-base": "^0.3.0", + "is-dotfile": "^1.0.0", + "is-extglob": "^1.0.0", + "is-glob": "^2.0.0" }, "dependencies": { "is-extglob": { @@ -9597,7 +9597,7 @@ "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", "dev": true, "requires": { - "is-extglob": "1.0.0" + "is-extglob": "^1.0.0" } } } @@ -9608,7 +9608,7 @@ "integrity": "sha1-9ID0BDTvgHQfhGkJn43qGPVaTck=", "dev": true, "requires": { - "error-ex": "1.3.2" + "error-ex": "^1.2.0" } }, "parse-node-version": { @@ -9629,7 +9629,7 @@ "integrity": "sha1-1SCKNzjkZ2bikbouoXNoSSGouJ0=", "dev": true, "requires": { - "better-assert": "1.0.2" + "better-assert": "~1.0.0" } }, "parseuri": { @@ -9638,7 +9638,7 @@ "integrity": "sha1-gCBKUNTbt3m/3G6+J3jZDkvOMgo=", "dev": true, "requires": { - "better-assert": "1.0.2" + "better-assert": "~1.0.0" } }, "parseurl": { @@ -9665,7 +9665,7 @@ "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=", "dev": true, "requires": { - "pinkie-promise": "2.0.1" + "pinkie-promise": "^2.0.0" } }, "path-is-absolute": { @@ -9697,7 +9697,7 @@ "integrity": "sha1-mkpoFMrBwM1zNgqV8yCDyOpHRbc=", "dev": true, "requires": { - "path-root-regex": "0.1.2" + "path-root-regex": "^0.1.0" } }, "path-root-regex": { @@ -9712,9 +9712,9 @@ "integrity": "sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE=", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "pify": "2.3.0", - "pinkie-promise": "2.0.1" + "graceful-fs": "^4.1.2", + "pify": "^2.0.0", + "pinkie-promise": "^2.0.0" } }, "pause-stream": { @@ -9723,7 +9723,7 @@ "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", "dev": true, "requires": { - "through": "2.3.8" + "through": "~2.3" } }, "pend": { @@ -9761,7 +9761,7 @@ "integrity": "sha1-ITXW36ejWMBprJsXh3YogihFD/o=", "dev": true, "requires": { - "pinkie": "2.0.4" + "pinkie": "^2.0.0" } }, "pkg-up": { @@ -9770,7 +9770,7 @@ "integrity": "sha512-nDywThFk1i4BQK4twPQ6TA4RT8bDY96yeuCVBWL3ePARCiEKDRSrNGbFIgUJpLp+XeIR65v8ra7WuJOFUBtkMA==", "dev": true, "requires": { - "find-up": "3.0.0" + "find-up": "^3.0.0" }, "dependencies": { "find-up": { @@ -9779,7 +9779,7 @@ "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", "dev": true, "requires": { - "locate-path": "3.0.0" + "locate-path": "^3.0.0" } } } @@ -9790,10 +9790,10 @@ "integrity": "sha512-L1zP0dk7vGweZME2i+EeakvUNqSrdiI3F91TwEoYiGrAfUXmVv6fJIq4g82PAXxNsWOp0J7ZqQy/3Szz0ajTxA==", "dev": true, "requires": { - "ansi-colors": "1.1.0", - "arr-diff": "4.0.0", - "arr-union": "3.1.0", - "extend-shallow": "3.0.2" + "ansi-colors": "^1.0.1", + "arr-diff": "^4.0.0", + "arr-union": "^3.1.0", + "extend-shallow": "^3.0.2" } }, "plur": { @@ -9802,7 +9802,7 @@ "integrity": "sha512-t1Ax8KUvV3FFII8ltczPn2tJdjqbd1sIzu6t4JL7nQ3EyeL/lTrj5PWKb06ic5/6XYDr65rQ4uzQEGN70/6X5w==", "dev": true, "requires": { - "irregular-plurals": "2.0.0" + "irregular-plurals": "^2.0.0" } }, "portscanner": { @@ -9812,7 +9812,7 @@ "dev": true, "requires": { "async": "1.5.2", - "is-number-like": "1.0.8" + "is-number-like": "^1.0.3" }, "dependencies": { "async": { @@ -9835,9 +9835,9 @@ "integrity": "sha512-WuQETPMcW9Uf1/22HWUWP9lgsIC+KEHg2kozMflKjbeUtw9ujvFX6QmIfozaErDkmLWS9WEnEdEe6Uo9/BNTdQ==", "dev": true, "requires": { - "chalk": "2.4.2", - "source-map": "0.6.1", - "supports-color": "6.1.0" + "chalk": "^2.4.2", + "source-map": "^0.6.1", + "supports-color": "^6.1.0" }, "dependencies": { "ansi-styles": { @@ -9846,7 +9846,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -9855,9 +9855,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" }, "dependencies": { "supports-color": { @@ -9866,7 +9866,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -9904,7 +9904,7 @@ "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -9968,7 +9968,7 @@ "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", "dev": true, "requires": { - "event-stream": "3.3.4" + "event-stream": "=3.3.4" }, "dependencies": { "event-stream": { @@ -9977,13 +9977,13 @@ "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", "dev": true, "requires": { - "duplexer": "0.1.1", - "from": "0.1.7", - "map-stream": "0.1.0", + "duplexer": "~0.1.1", + "from": "~0", + "map-stream": "~0.1.0", "pause-stream": "0.0.11", - "split": "0.3.3", - "stream-combiner": "0.0.4", - "through": "2.3.8" + "split": "0.3", + "stream-combiner": "~0.0.4", + "through": "~2.3.1" } }, "map-stream": { @@ -9998,7 +9998,7 @@ "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", "dev": true, "requires": { - "through": "2.3.8" + "through": "2" } }, "stream-combiner": { @@ -10007,7 +10007,7 @@ "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", "dev": true, "requires": { - "duplexer": "0.1.1" + "duplexer": "~0.1.1" } } } @@ -10029,8 +10029,8 @@ "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", "dev": true, "requires": { - "end-of-stream": "1.4.4", - "once": "1.4.0" + "end-of-stream": "^1.1.0", + "once": "^1.3.1" } }, "pumpify": { @@ -10039,9 +10039,9 @@ "integrity": "sha512-oClZI37HvuUJJxSKKrC17bZ9Cu0ZYhEAGPsPUy9KlMUmv9dKX2o77RUmq7f3XjIxbwyGwYzbzQ1L2Ks8sIradQ==", "dev": true, "requires": { - "duplexify": "3.7.1", - "inherits": "2.0.4", - "pump": "2.0.1" + "duplexify": "^3.6.0", + "inherits": "^2.0.3", + "pump": "^2.0.0" }, "dependencies": { "pump": { @@ -10050,8 +10050,8 @@ "integrity": "sha512-ruPMNRkN3MHP1cWJc9OWr+T/xDP0jhXYCLfJcBuX54hhfIBnaQmAUMfDcG4DM5UMWByBbJY69QSphm3jtDKIkA==", "dev": true, "requires": { - "end-of-stream": "1.4.4", - "once": "1.4.0" + "end-of-stream": "^1.1.0", + "once": "^1.3.1" } } } @@ -10079,9 +10079,9 @@ "dev": true, "optional": true, "requires": { - "decode-uri-component": "0.2.0", - "object-assign": "4.1.1", - "strict-uri-encode": "1.1.0" + "decode-uri-component": "^0.2.0", + "object-assign": "^4.1.0", + "strict-uri-encode": "^1.0.0" } }, "randomatic": { @@ -10090,9 +10090,9 @@ "integrity": "sha512-TuDE5KxZ0J461RVjrJZCJc+J+zCkTb1MbH9AQUq68sMhOMcy9jLcb3BrZKgp9q9Ncltdg4QVqWrH02W2EFFVYw==", "dev": true, "requires": { - "is-number": "4.0.0", - "kind-of": "6.0.3", - "math-random": "1.0.4" + "is-number": "^4.0.0", + "kind-of": "^6.0.0", + "math-random": "^1.0.1" }, "dependencies": { "is-number": { @@ -10127,7 +10127,7 @@ "integrity": "sha1-8+gPOH3fmugK4wpBADKWQuroERU=", "dev": true, "requires": { - "lodash.clonedeep": "4.5.0" + "lodash.clonedeep": "^4.3.2" } }, "rcloader": { @@ -10136,10 +10136,10 @@ "integrity": "sha1-WNIpi0YtC5v9ITPSoex0+9cFxxc=", "dev": true, "requires": { - "lodash.assign": "4.2.0", - "lodash.isobject": "3.0.2", - "lodash.merge": "4.6.2", - "rcfinder": "0.1.9" + "lodash.assign": "^4.2.0", + "lodash.isobject": "^3.0.2", + "lodash.merge": "^4.6.0", + "rcfinder": "^0.1.6" } }, "read-pkg": { @@ -10148,9 +10148,9 @@ "integrity": "sha1-9f+qXs0pyzHAR0vKfXVra7KePyg=", "dev": true, "requires": { - "load-json-file": "1.1.0", - "normalize-package-data": "2.5.0", - "path-type": "1.1.0" + "load-json-file": "^1.0.0", + "normalize-package-data": "^2.3.2", + "path-type": "^1.0.0" } }, "read-pkg-up": { @@ -10159,8 +10159,8 @@ "integrity": "sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI=", "dev": true, "requires": { - "find-up": "1.1.2", - "read-pkg": "1.1.0" + "find-up": "^1.0.0", + "read-pkg": "^1.0.0" } }, "readable-stream": { @@ -10168,9 +10168,9 @@ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.0.tgz", "integrity": "sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==", "requires": { - "inherits": "2.0.4", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" } }, "readdirp": { @@ -10179,9 +10179,9 @@ "integrity": "sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ==", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "micromatch": "3.1.10", - "readable-stream": "2.3.7" + "graceful-fs": "^4.1.11", + "micromatch": "^3.1.10", + "readable-stream": "^2.0.2" }, "dependencies": { "readable-stream": { @@ -10190,13 +10190,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -10207,7 +10207,7 @@ "integrity": "sha1-hSBLVNuoLVdC4oyWdW70OvUOM4Q=", "dev": true, "requires": { - "resolve": "1.15.1" + "resolve": "^1.1.6" } }, "redent": { @@ -10216,8 +10216,8 @@ "integrity": "sha1-z5Fqsf1fHxbfsggi3W7H9zDCr94=", "dev": true, "requires": { - "indent-string": "2.1.0", - "strip-indent": "1.0.1" + "indent-string": "^2.1.0", + "strip-indent": "^1.0.1" } }, "regenerator-runtime": { @@ -10231,7 +10231,7 @@ "integrity": "sha512-nVIZwtCjkC9YgvWkpM55B5rBhBYRZhAaJbgcFYXXsHnbZ9UZI9nnVWYZpBlCqv9ho2eZryPnWrZGsOdPwVWXWQ==", "dev": true, "requires": { - "is-equal-shallow": "0.1.3" + "is-equal-shallow": "^0.1.3" } }, "regex-not": { @@ -10240,8 +10240,8 @@ "integrity": "sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A==", "dev": true, "requires": { - "extend-shallow": "3.0.2", - "safe-regex": "1.1.0" + "extend-shallow": "^3.0.2", + "safe-regex": "^1.1.0" } }, "relateurl": { @@ -10256,8 +10256,8 @@ "integrity": "sha512-8v2rWhaakv18qcvNeli2mZ/TMTL2nEyAKRvzo1WtnZBl15SHyEhrCu2/xKlJyUFKHiHgfXIyuY6g2dObJJycXQ==", "dev": true, "requires": { - "is-buffer": "1.1.6", - "is-utf8": "0.2.1" + "is-buffer": "^1.1.5", + "is-utf8": "^0.2.1" } }, "remove-bom-stream": { @@ -10266,9 +10266,9 @@ "integrity": "sha1-BfGlk/FuQuH7kOv1nejlaVJflSM=", "dev": true, "requires": { - "remove-bom-buffer": "3.0.0", - "safe-buffer": "5.1.2", - "through2": "2.0.5" + "remove-bom-buffer": "^3.0.0", + "safe-buffer": "^5.1.0", + "through2": "^2.0.3" } }, "remove-trailing-separator": { @@ -10295,7 +10295,7 @@ "integrity": "sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo=", "dev": true, "requires": { - "is-finite": "1.1.0" + "is-finite": "^1.0.0" } }, "replace-ext": { @@ -10309,26 +10309,26 @@ "resolved": "https://registry.npmjs.org/request/-/request-2.88.2.tgz", "integrity": "sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==", "requires": { - "aws-sign2": "0.7.0", - "aws4": "1.9.1", - "caseless": "0.12.0", - "combined-stream": "1.0.8", - "extend": "3.0.2", - "forever-agent": "0.6.1", - "form-data": "2.3.3", - "har-validator": "5.1.3", - "http-signature": "1.2.0", - "is-typedarray": "1.0.0", - "isstream": "0.1.2", - "json-stringify-safe": "5.0.1", - "mime-types": "2.1.26", - "oauth-sign": "0.9.0", - "performance-now": "2.1.0", - "qs": "6.5.2", - "safe-buffer": "5.1.2", - "tough-cookie": "2.5.0", - "tunnel-agent": "0.6.0", - "uuid": "3.4.0" + "aws-sign2": "~0.7.0", + "aws4": "^1.8.0", + "caseless": "~0.12.0", + "combined-stream": "~1.0.6", + "extend": "~3.0.2", + "forever-agent": "~0.6.1", + "form-data": "~2.3.2", + "har-validator": "~5.1.3", + "http-signature": "~1.2.0", + "is-typedarray": "~1.0.0", + "isstream": "~0.1.2", + "json-stringify-safe": "~5.0.1", + "mime-types": "~2.1.19", + "oauth-sign": "~0.9.0", + "performance-now": "^2.1.0", + "qs": "~6.5.2", + "safe-buffer": "^5.1.2", + "tough-cookie": "~2.5.0", + "tunnel-agent": "^0.6.0", + "uuid": "^3.3.2" }, "dependencies": { "form-data": { @@ -10336,9 +10336,9 @@ "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", "requires": { - "asynckit": "0.4.0", - "combined-stream": "1.0.8", - "mime-types": "2.1.26" + "asynckit": "^0.4.0", + "combined-stream": "^1.0.6", + "mime-types": "^2.1.12" } } } @@ -10349,10 +10349,10 @@ "integrity": "sha512-ZgnepCykFdmpq86fKGwqntyTiUrHycALuGggpyCZwMvGaZWgxW6yagT0FHkgo5LzYvOaCNvxYwWYIjevSH1EDg==", "dev": true, "requires": { - "bluebird": "3.7.2", + "bluebird": "^3.5.0", "request-promise-core": "1.1.3", - "stealthy-require": "1.1.1", - "tough-cookie": "2.5.0" + "stealthy-require": "^1.1.1", + "tough-cookie": "^2.3.3" } }, "request-promise-core": { @@ -10361,7 +10361,7 @@ "integrity": "sha512-QIs2+ArIGQVp5ZYbWD5ZLCY29D5CfWizP8eWnm8FoGD1TX61veauETVQbrV60662V0oFBkrDOuaBI8XgtuyYAQ==", "dev": true, "requires": { - "lodash": "4.17.15" + "lodash": "^4.17.15" } }, "require-directory": { @@ -10388,7 +10388,7 @@ "integrity": "sha512-84oo6ZTtoTUpjgNEr5SJyzQhzL72gaRodsSfyxC/AXRvwu0Yse9H8eF9IpGo7b8YetZhlI6v7ZQ6bKBFV/6S7w==", "dev": true, "requires": { - "path-parse": "1.0.6" + "path-parse": "^1.0.6" } }, "resolve-dir": { @@ -10397,8 +10397,8 @@ "integrity": "sha1-eaQGRMNivoLybv/nOcm7U4IEb0M=", "dev": true, "requires": { - "expand-tilde": "2.0.2", - "global-modules": "1.0.0" + "expand-tilde": "^2.0.0", + "global-modules": "^1.0.0" } }, "resolve-options": { @@ -10407,7 +10407,7 @@ "integrity": "sha1-MrueOcBtZzONyTeMDW1gdFZq0TE=", "dev": true, "requires": { - "value-or-function": "3.0.0" + "value-or-function": "^3.0.0" } }, "resolve-url": { @@ -10422,8 +10422,8 @@ "integrity": "sha1-sSTeXE+6/LpUH0j/pzlw9KpFa08=", "dev": true, "requires": { - "debug": "2.6.9", - "minimatch": "3.0.4" + "debug": "^2.2.0", + "minimatch": "^3.0.2" }, "dependencies": { "debug": { @@ -10450,7 +10450,7 @@ "dev": true, "optional": true, "requires": { - "lowercase-keys": "1.0.1" + "lowercase-keys": "^1.0.0" } }, "resq": { @@ -10458,7 +10458,7 @@ "resolved": "https://registry.npmjs.org/resq/-/resq-1.7.1.tgz", "integrity": "sha512-09u9Q5SAuJfAW5UoVAmvRtLvCOMaKP+djiixTXsZvPaojGKhuvc0Nfvp84U1rIfopJWEOXi5ywpCFwCk7mj8Xw==", "requires": { - "fast-deep-equal": "2.0.1" + "fast-deep-equal": "^2.0.1" } }, "ret": { @@ -10478,7 +10478,7 @@ "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", "dev": true, "requires": { - "glob": "7.1.6" + "glob": "^7.1.3" } }, "rx": { @@ -10507,7 +10507,7 @@ "integrity": "sha1-QKNmnzsHfR6UPURinhV91IAjvy4=", "dev": true, "requires": { - "ret": "0.1.15" + "ret": "~0.1.10" } }, "safer-buffer": { @@ -10521,10 +10521,10 @@ "integrity": "sha1-E/vWPNHK8JCLn9k0dq1DpR0eC0k=", "dev": true, "requires": { - "glob": "7.1.6", - "lodash": "4.17.15", - "scss-tokenizer": "0.2.3", - "yargs": "7.1.0" + "glob": "^7.0.0", + "lodash": "^4.0.0", + "scss-tokenizer": "^0.2.3", + "yargs": "^7.0.0" }, "dependencies": { "yargs": { @@ -10533,19 +10533,19 @@ "integrity": "sha1-a6MY6xaWFyf10oT46gA+jWFU0Mg=", "dev": true, "requires": { - "camelcase": "3.0.0", - "cliui": "3.2.0", - "decamelize": "1.2.0", - "get-caller-file": "1.0.3", - "os-locale": "1.4.0", - "read-pkg-up": "1.0.1", - "require-directory": "2.1.1", - "require-main-filename": "1.0.1", - "set-blocking": "2.0.0", - "string-width": "1.0.2", - "which-module": "1.0.0", - "y18n": "3.2.1", - "yargs-parser": "5.0.0" + "camelcase": "^3.0.0", + "cliui": "^3.2.0", + "decamelize": "^1.1.1", + "get-caller-file": "^1.0.1", + "os-locale": "^1.4.0", + "read-pkg-up": "^1.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^1.0.1", + "set-blocking": "^2.0.0", + "string-width": "^1.0.2", + "which-module": "^1.0.0", + "y18n": "^3.2.1", + "yargs-parser": "^5.0.0" } }, "yargs-parser": { @@ -10554,7 +10554,7 @@ "integrity": "sha1-J17PDX/+Bcd+ZOfIbkzZS/DhIoo=", "dev": true, "requires": { - "camelcase": "3.0.0" + "camelcase": "^3.0.0" } } } @@ -10571,8 +10571,8 @@ "integrity": "sha1-jrBtualyMzOCTT9VMGQRSYR85dE=", "dev": true, "requires": { - "js-base64": "2.5.2", - "source-map": "0.4.4" + "js-base64": "^2.1.8", + "source-map": "^0.4.2" }, "dependencies": { "source-map": { @@ -10581,7 +10581,7 @@ "integrity": "sha1-66T12pwNyZneaAMti092FzZSA2s=", "dev": true, "requires": { - "amdefine": "1.0.1" + "amdefine": ">=0.0.4" } } } @@ -10592,7 +10592,7 @@ "integrity": "sha1-z+kXyz0nS8/6x5J1ivUxc+sfq9w=", "dev": true, "requires": { - "commander": "2.8.1" + "commander": "~2.8.1" }, "dependencies": { "commander": { @@ -10601,7 +10601,7 @@ "integrity": "sha1-Br42f+v9oMMwqh4qBy09yXYkJdQ=", "dev": true, "requires": { - "graceful-readlink": "1.0.1" + "graceful-readlink": ">= 1.0.0" } } } @@ -10612,19 +10612,19 @@ "integrity": "sha512-5PSnDHwMiq+OCiAGlhwQ8BM9xuwFfvBOZ7Tfbw+ifkTnOy0PWbZmI1B9gPGuyGHpbQ/3J3CzIK7BYwrQ7EjtWQ==", "dev": true, "requires": { - "async": "2.6.3", - "commander": "2.20.3", - "cross-spawn": "6.0.5", - "debug": "4.1.1", - "lodash": "4.17.15", - "minimist": "1.2.5", - "mkdirp": "0.5.4", + "async": "^2.6.2", + "commander": "^2.19.0", + "cross-spawn": "^6.0.5", + "debug": "^4.1.1", + "lodash": "^4.17.11", + "minimist": "^1.2.0", + "mkdirp": "^0.5.1", "progress": "2.0.3", "request": "2.88.0", "tar-stream": "2.0.0", - "urijs": "1.19.2", - "which": "1.3.1", - "yauzl": "2.10.0" + "urijs": "^1.19.1", + "which": "^1.3.1", + "yauzl": "^2.10.0" }, "dependencies": { "bl": { @@ -10633,8 +10633,8 @@ "integrity": "sha512-wbgvOpqopSr7uq6fJrLH8EsvYMJf9gzfo2jCsL2eTy75qXPukA4pCgHamOQkZtY5vmfVtjB+P3LNlMHW5CEZXA==", "dev": true, "requires": { - "readable-stream": "2.3.7", - "safe-buffer": "5.1.2" + "readable-stream": "^2.3.5", + "safe-buffer": "^5.1.1" }, "dependencies": { "readable-stream": { @@ -10643,13 +10643,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -10660,11 +10660,11 @@ "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", "dev": true, "requires": { - "nice-try": "1.0.5", - "path-key": "2.0.1", - "semver": "5.7.1", - "shebang-command": "1.2.0", - "which": "1.3.1" + "nice-try": "^1.0.4", + "path-key": "^2.0.1", + "semver": "^5.5.0", + "shebang-command": "^1.2.0", + "which": "^1.2.9" } }, "form-data": { @@ -10673,9 +10673,9 @@ "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", "dev": true, "requires": { - "asynckit": "0.4.0", - "combined-stream": "1.0.8", - "mime-types": "2.1.26" + "asynckit": "^0.4.0", + "combined-stream": "^1.0.6", + "mime-types": "^2.1.12" } }, "punycode": { @@ -10690,26 +10690,26 @@ "integrity": "sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==", "dev": true, "requires": { - "aws-sign2": "0.7.0", - "aws4": "1.9.1", - "caseless": "0.12.0", - "combined-stream": "1.0.8", - "extend": "3.0.2", - "forever-agent": "0.6.1", - "form-data": "2.3.3", - "har-validator": "5.1.3", - "http-signature": "1.2.0", - "is-typedarray": "1.0.0", - "isstream": "0.1.2", - "json-stringify-safe": "5.0.1", - "mime-types": "2.1.26", - "oauth-sign": "0.9.0", - "performance-now": "2.1.0", - "qs": "6.5.2", - "safe-buffer": "5.1.2", - "tough-cookie": "2.4.3", - "tunnel-agent": "0.6.0", - "uuid": "3.4.0" + "aws-sign2": "~0.7.0", + "aws4": "^1.8.0", + "caseless": "~0.12.0", + "combined-stream": "~1.0.6", + "extend": "~3.0.2", + "forever-agent": "~0.6.1", + "form-data": "~2.3.2", + "har-validator": "~5.1.0", + "http-signature": "~1.2.0", + "is-typedarray": "~1.0.0", + "isstream": "~0.1.2", + "json-stringify-safe": "~5.0.1", + "mime-types": "~2.1.19", + "oauth-sign": "~0.9.0", + "performance-now": "^2.1.0", + "qs": "~6.5.2", + "safe-buffer": "^5.1.2", + "tough-cookie": "~2.4.3", + "tunnel-agent": "^0.6.0", + "uuid": "^3.3.2" } }, "tar-stream": { @@ -10718,11 +10718,11 @@ "integrity": "sha512-n2vtsWshZOVr/SY4KtslPoUlyNh06I2SGgAOCZmquCEjlbV/LjY2CY80rDtdQRHFOYXNlgBDo6Fr3ww2CWPOtA==", "dev": true, "requires": { - "bl": "2.2.0", - "end-of-stream": "1.4.4", - "fs-constants": "1.0.0", - "inherits": "2.0.4", - "readable-stream": "3.6.0" + "bl": "^2.2.0", + "end-of-stream": "^1.4.1", + "fs-constants": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^3.1.1" } }, "tough-cookie": { @@ -10731,8 +10731,8 @@ "integrity": "sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==", "dev": true, "requires": { - "psl": "1.8.0", - "punycode": "1.4.1" + "psl": "^1.1.24", + "punycode": "^1.4.1" } } } @@ -10757,7 +10757,7 @@ "dev": true, "optional": true, "requires": { - "semver": "5.7.1" + "semver": "^5.3.0" } }, "send": { @@ -10767,18 +10767,18 @@ "dev": true, "requires": { "debug": "2.6.9", - "depd": "1.1.2", - "destroy": "1.0.4", - "encodeurl": "1.0.2", - "escape-html": "1.0.3", - "etag": "1.8.1", + "depd": "~1.1.2", + "destroy": "~1.0.4", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", "fresh": "0.5.2", - "http-errors": "1.6.3", + "http-errors": "~1.6.2", "mime": "1.4.1", "ms": "2.0.0", - "on-finished": "2.3.0", - "range-parser": "1.2.1", - "statuses": "1.4.0" + "on-finished": "~2.3.0", + "range-parser": "~1.2.0", + "statuses": "~1.4.0" }, "dependencies": { "debug": { @@ -10796,10 +10796,10 @@ "integrity": "sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0=", "dev": true, "requires": { - "depd": "1.1.2", + "depd": "~1.1.2", "inherits": "2.0.3", "setprototypeof": "1.1.0", - "statuses": "1.4.0" + "statuses": ">= 1.4.0 < 2" } }, "inherits": { @@ -10839,7 +10839,7 @@ "resolved": "https://registry.npmjs.org/serialize-error/-/serialize-error-5.0.0.tgz", "integrity": "sha512-/VtpuyzYf82mHYTtI4QKtwHa79vAdU5OQpNPAmE/0UDdlGT0ZxHwC+J6gXkw29wwoVI8fMPsfcVHOwXtUQYYQA==", "requires": { - "type-fest": "0.8.1" + "type-fest": "^0.8.0" } }, "serve-index": { @@ -10848,13 +10848,13 @@ "integrity": "sha1-03aNabHn2C5c4FD/9bRTvqEqkjk=", "dev": true, "requires": { - "accepts": "1.3.7", + "accepts": "~1.3.4", "batch": "0.6.1", "debug": "2.6.9", - "escape-html": "1.0.3", - "http-errors": "1.6.3", - "mime-types": "2.1.26", - "parseurl": "1.3.3" + "escape-html": "~1.0.3", + "http-errors": "~1.6.2", + "mime-types": "~2.1.17", + "parseurl": "~1.3.2" }, "dependencies": { "debug": { @@ -10872,10 +10872,10 @@ "integrity": "sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0=", "dev": true, "requires": { - "depd": "1.1.2", + "depd": "~1.1.2", "inherits": "2.0.3", "setprototypeof": "1.1.0", - "statuses": "1.5.0" + "statuses": ">= 1.4.0 < 2" } }, "inherits": { @@ -10910,9 +10910,9 @@ "integrity": "sha512-p/tdJrO4U387R9oMjb1oj7qSMaMfmOyd4j9hOFoxZe2baQszgHcSWjuya/CiT5kgZZKRudHNOA0pYXOl8rQ5nw==", "dev": true, "requires": { - "encodeurl": "1.0.2", - "escape-html": "1.0.3", - "parseurl": "1.3.3", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "parseurl": "~1.3.2", "send": "0.16.2" } }, @@ -10934,10 +10934,10 @@ "integrity": "sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw==", "dev": true, "requires": { - "extend-shallow": "2.0.1", - "is-extendable": "0.1.1", - "is-plain-object": "2.0.4", - "split-string": "3.1.0" + "extend-shallow": "^2.0.1", + "is-extendable": "^0.1.1", + "is-plain-object": "^2.0.3", + "split-string": "^3.0.1" }, "dependencies": { "extend-shallow": { @@ -10946,7 +10946,7 @@ "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, "requires": { - "is-extendable": "0.1.1" + "is-extendable": "^0.1.0" } } } @@ -10963,7 +10963,7 @@ "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", "dev": true, "requires": { - "shebang-regex": "1.0.0" + "shebang-regex": "^1.0.0" } }, "shebang-regex": { @@ -10996,14 +10996,14 @@ "integrity": "sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg==", "dev": true, "requires": { - "base": "0.11.2", - "debug": "2.6.9", - "define-property": "0.2.5", - "extend-shallow": "2.0.1", - "map-cache": "0.2.2", - "source-map": "0.5.7", - "source-map-resolve": "0.5.3", - "use": "3.1.1" + "base": "^0.11.1", + "debug": "^2.2.0", + "define-property": "^0.2.5", + "extend-shallow": "^2.0.1", + "map-cache": "^0.2.2", + "source-map": "^0.5.6", + "source-map-resolve": "^0.5.0", + "use": "^3.1.0" }, "dependencies": { "debug": { @@ -11021,7 +11021,7 @@ "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, "requires": { - "is-descriptor": "0.1.6" + "is-descriptor": "^0.1.0" } }, "extend-shallow": { @@ -11030,7 +11030,7 @@ "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, "requires": { - "is-extendable": "0.1.1" + "is-extendable": "^0.1.0" } }, "ms": { @@ -11047,9 +11047,9 @@ "integrity": "sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw==", "dev": true, "requires": { - "define-property": "1.0.0", - "isobject": "3.0.1", - "snapdragon-util": "3.0.1" + "define-property": "^1.0.0", + "isobject": "^3.0.0", + "snapdragon-util": "^3.0.1" }, "dependencies": { "define-property": { @@ -11058,7 +11058,7 @@ "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", "dev": true, "requires": { - "is-descriptor": "1.0.2" + "is-descriptor": "^1.0.0" } }, "is-accessor-descriptor": { @@ -11067,7 +11067,7 @@ "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.0" } }, "is-data-descriptor": { @@ -11076,7 +11076,7 @@ "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, "requires": { - "kind-of": "6.0.3" + "kind-of": "^6.0.0" } }, "is-descriptor": { @@ -11085,9 +11085,9 @@ "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, "requires": { - "is-accessor-descriptor": "1.0.0", - "is-data-descriptor": "1.0.0", - "kind-of": "6.0.3" + "is-accessor-descriptor": "^1.0.0", + "is-data-descriptor": "^1.0.0", + "kind-of": "^6.0.2" } } } @@ -11098,7 +11098,7 @@ "integrity": "sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ==", "dev": true, "requires": { - "kind-of": "3.2.2" + "kind-of": "^3.2.0" }, "dependencies": { "kind-of": { @@ -11107,7 +11107,7 @@ "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } } } @@ -11118,12 +11118,12 @@ "integrity": "sha512-rORqq9c+7W0DAK3cleWNSyfv/qKXV99hV4tZe+gGLfBECw3XEhBy7x85F3wypA9688LKjtwO9pX9L33/xQI8yA==", "dev": true, "requires": { - "debug": "3.1.0", - "engine.io": "3.2.1", - "has-binary2": "1.0.3", - "socket.io-adapter": "1.1.2", + "debug": "~3.1.0", + "engine.io": "~3.2.0", + "has-binary2": "~1.0.2", + "socket.io-adapter": "~1.1.0", "socket.io-client": "2.1.1", - "socket.io-parser": "3.2.0" + "socket.io-parser": "~3.2.0" }, "dependencies": { "debug": { @@ -11143,14 +11143,14 @@ "requires": { "component-emitter": "1.2.1", "component-inherit": "0.0.3", - "debug": "3.1.0", - "engine.io-parser": "2.1.3", + "debug": "~3.1.0", + "engine.io-parser": "~2.1.1", "has-cors": "1.1.0", "indexof": "0.0.1", "parseqs": "0.0.5", "parseuri": "0.0.5", - "ws": "3.3.3", - "xmlhttprequest-ssl": "1.5.5", + "ws": "~3.3.1", + "xmlhttprequest-ssl": "~1.5.4", "yeast": "0.1.2" } }, @@ -11161,10 +11161,10 @@ "dev": true, "requires": { "after": "0.8.2", - "arraybuffer.slice": "0.0.7", + "arraybuffer.slice": "~0.0.7", "base64-arraybuffer": "0.1.5", "blob": "0.0.5", - "has-binary2": "1.0.3" + "has-binary2": "~1.0.2" } }, "isarray": { @@ -11189,15 +11189,15 @@ "base64-arraybuffer": "0.1.5", "component-bind": "1.0.0", "component-emitter": "1.2.1", - "debug": "3.1.0", - "engine.io-client": "3.2.1", - "has-binary2": "1.0.3", + "debug": "~3.1.0", + "engine.io-client": "~3.2.0", + "has-binary2": "~1.0.2", "has-cors": "1.1.0", "indexof": "0.0.1", "object-component": "0.0.3", "parseqs": "0.0.5", "parseuri": "0.0.5", - "socket.io-parser": "3.2.0", + "socket.io-parser": "~3.2.0", "to-array": "0.1.4" } }, @@ -11208,7 +11208,7 @@ "dev": true, "requires": { "component-emitter": "1.2.1", - "debug": "3.1.0", + "debug": "~3.1.0", "isarray": "2.0.1" } }, @@ -11218,9 +11218,9 @@ "integrity": "sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA==", "dev": true, "requires": { - "async-limiter": "1.0.1", - "safe-buffer": "5.1.2", - "ultron": "1.1.1" + "async-limiter": "~1.0.0", + "safe-buffer": "~5.1.0", + "ultron": "~1.1.0" } } } @@ -11241,15 +11241,15 @@ "base64-arraybuffer": "0.1.5", "component-bind": "1.0.0", "component-emitter": "1.2.1", - "debug": "4.1.1", - "engine.io-client": "3.4.0", - "has-binary2": "1.0.3", + "debug": "~4.1.0", + "engine.io-client": "~3.4.0", + "has-binary2": "~1.0.2", "has-cors": "1.1.0", "indexof": "0.0.1", "object-component": "0.0.3", "parseqs": "0.0.5", "parseuri": "0.0.5", - "socket.io-parser": "3.3.0", + "socket.io-parser": "~3.3.0", "to-array": "0.1.4" } }, @@ -11260,7 +11260,7 @@ "dev": true, "requires": { "component-emitter": "1.2.1", - "debug": "3.1.0", + "debug": "~3.1.0", "isarray": "2.0.1" }, "dependencies": { @@ -11293,7 +11293,7 @@ "integrity": "sha1-RBttTTRnmPG05J6JIK37oOVD+a0=", "dev": true, "requires": { - "is-plain-obj": "1.1.0" + "is-plain-obj": "^1.0.0" } }, "sort-keys-length": { @@ -11302,7 +11302,7 @@ "integrity": "sha1-nLb09OnkgVWmqgZx7dM2/xR5oYg=", "dev": true, "requires": { - "sort-keys": "1.1.2" + "sort-keys": "^1.0.0" } }, "source-map": { @@ -11317,11 +11317,11 @@ "integrity": "sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw==", "dev": true, "requires": { - "atob": "2.1.2", - "decode-uri-component": "0.2.0", - "resolve-url": "0.2.1", - "source-map-url": "0.4.0", - "urix": "0.1.0" + "atob": "^2.1.2", + "decode-uri-component": "^0.2.0", + "resolve-url": "^0.2.1", + "source-map-url": "^0.4.0", + "urix": "^0.1.0" } }, "source-map-support": { @@ -11330,8 +11330,8 @@ "integrity": "sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ==", "dev": true, "requires": { - "buffer-from": "1.1.1", - "source-map": "0.6.1" + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" }, "dependencies": { "source-map": { @@ -11360,8 +11360,8 @@ "integrity": "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==", "dev": true, "requires": { - "spdx-expression-parse": "3.0.0", - "spdx-license-ids": "3.0.5" + "spdx-expression-parse": "^3.0.0", + "spdx-license-ids": "^3.0.0" } }, "spdx-exceptions": { @@ -11376,8 +11376,8 @@ "integrity": "sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==", "dev": true, "requires": { - "spdx-exceptions": "2.2.0", - "spdx-license-ids": "3.0.5" + "spdx-exceptions": "^2.1.0", + "spdx-license-ids": "^3.0.0" } }, "spdx-license-ids": { @@ -11392,7 +11392,7 @@ "integrity": "sha512-mTyOoPbrivtXnwnIxZRFYRrPNtEFKlpB2fvjSnCQUiAA6qAZzqwna5envK4uk6OIeP17CsdF3rSBGYVBsU0Tkg==", "dev": true, "requires": { - "through": "2.3.8" + "through": "2" } }, "split-string": { @@ -11401,7 +11401,7 @@ "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", "dev": true, "requires": { - "extend-shallow": "3.0.2" + "extend-shallow": "^3.0.0" } }, "sprintf-js": { @@ -11417,9 +11417,9 @@ "dev": true, "optional": true, "requires": { - "chalk": "1.1.3", - "console-stream": "0.1.1", - "lpad-align": "1.1.2" + "chalk": "^1.0.0", + "console-stream": "^0.1.1", + "lpad-align": "^1.0.1" }, "dependencies": { "ansi-regex": { @@ -11443,11 +11443,11 @@ "dev": true, "optional": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "strip-ansi": { @@ -11457,7 +11457,7 @@ "dev": true, "optional": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -11474,15 +11474,15 @@ "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", "integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==", "requires": { - "asn1": "0.2.4", - "assert-plus": "1.0.0", - "bcrypt-pbkdf": "1.0.2", - "dashdash": "1.14.1", - "ecc-jsbn": "0.1.2", - "getpass": "0.1.7", - "jsbn": "0.1.1", - "safer-buffer": "2.1.2", - "tweetnacl": "0.14.5" + "asn1": "~0.2.3", + "assert-plus": "^1.0.0", + "bcrypt-pbkdf": "^1.0.0", + "dashdash": "^1.12.0", + "ecc-jsbn": "~0.1.1", + "getpass": "^0.1.1", + "jsbn": "~0.1.0", + "safer-buffer": "^2.0.2", + "tweetnacl": "~0.14.0" } }, "stable": { @@ -11497,8 +11497,8 @@ "integrity": "sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY=", "dev": true, "requires": { - "define-property": "0.2.5", - "object-copy": "0.1.0" + "define-property": "^0.2.5", + "object-copy": "^0.1.0" }, "dependencies": { "define-property": { @@ -11507,7 +11507,7 @@ "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, "requires": { - "is-descriptor": "0.1.6" + "is-descriptor": "^0.1.0" } } } @@ -11524,7 +11524,7 @@ "integrity": "sha512-j4emi03KXqJWcIeF8eIXkjMFN1Cmb8gUlDYGeBALLPo5qdyTfA9bOtl8m33lRoC+vFMkP3gl0WsDr6+gzxbbTA==", "dev": true, "requires": { - "readable-stream": "2.3.7" + "readable-stream": "^2.0.1" }, "dependencies": { "readable-stream": { @@ -11533,13 +11533,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -11556,8 +11556,8 @@ "integrity": "sha1-rsjLrBd7Vrb0+kec7YwZEs7lKFg=", "dev": true, "requires": { - "duplexer": "0.1.1", - "through": "2.3.8" + "duplexer": "~0.1.1", + "through": "~2.3.4" } }, "stream-consume": { @@ -11584,8 +11584,8 @@ "integrity": "sha1-rdV8jXzHOoFjDTHNVdOWHPr7qcM=", "dev": true, "requires": { - "commander": "2.20.3", - "limiter": "1.1.5" + "commander": "^2.2.0", + "limiter": "^1.0.5" } }, "stream-to-array": { @@ -11594,7 +11594,7 @@ "integrity": "sha1-u/azn19D7DC8cbq8s3VXrOzzQ1M=", "dev": true, "requires": { - "any-promise": "1.3.0" + "any-promise": "^1.1.0" } }, "streamfilter": { @@ -11603,7 +11603,7 @@ "integrity": "sha512-Gk6KZM+yNA1JpW0KzlZIhjo3EaBJDkYfXtYSbOwNIQ7Zd6006E6+sCFlW1NDvFG/vnXhKmw6TJJgiEQg/8lXfQ==", "dev": true, "requires": { - "readable-stream": "2.3.7" + "readable-stream": "^2.0.2" }, "dependencies": { "readable-stream": { @@ -11612,13 +11612,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -11636,7 +11636,7 @@ "integrity": "sha1-VpcPscOFWOnnC3KL894mmsRa36w=", "dev": true, "requires": { - "strip-ansi": "3.0.1" + "strip-ansi": "^3.0.0" }, "dependencies": { "ansi-regex": { @@ -11651,7 +11651,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } } } @@ -11662,9 +11662,9 @@ "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", "dev": true, "requires": { - "code-point-at": "1.1.0", - "is-fullwidth-code-point": "1.0.0", - "strip-ansi": "3.0.1" + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" }, "dependencies": { "ansi-regex": { @@ -11679,7 +11679,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } } } @@ -11690,8 +11690,8 @@ "integrity": "sha512-iu2AGd3PuP5Rp7x2kEZCrB2Nf41ehzh+goo8TV7z8/XDBbsvc6HQIlUl9RjkZ4oyrW1XM5UwlGl1oVEaDjg6Ag==", "dev": true, "requires": { - "define-properties": "1.1.3", - "function-bind": "1.1.1" + "define-properties": "^1.1.3", + "function-bind": "^1.1.1" } }, "string.prototype.trimright": { @@ -11700,8 +11700,8 @@ "integrity": "sha512-qFvWL3/+QIgZXVmJBfpHmxLB7xsUXz6HsUmP8+5dRaC3Q7oKUv9Vo6aMCRZC1smrtyECFsIT30PqBJ1gTjAs+g==", "dev": true, "requires": { - "define-properties": "1.1.3", - "function-bind": "1.1.1" + "define-properties": "^1.1.3", + "function-bind": "^1.1.1" } }, "string_decoder": { @@ -11709,7 +11709,7 @@ "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "requires": { - "safe-buffer": "5.1.2" + "safe-buffer": "~5.1.0" } }, "stringify-object": { @@ -11717,9 +11717,9 @@ "resolved": "https://registry.npmjs.org/stringify-object/-/stringify-object-3.3.0.tgz", "integrity": "sha512-rHqiFh1elqCQ9WPLIC8I0Q/g/wj5J1eMkyoiD6eoQApWHP0FtlK7rqnhmabL5VUY9JQCcqwwvlOaSuutekgyrw==", "requires": { - "get-own-enumerable-property-symbols": "3.0.2", - "is-obj": "1.0.1", - "is-regexp": "1.0.0" + "get-own-enumerable-property-symbols": "^3.0.0", + "is-obj": "^1.0.1", + "is-regexp": "^1.0.0" } }, "strip-ansi": { @@ -11727,7 +11727,7 @@ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", "requires": { - "ansi-regex": "5.0.0" + "ansi-regex": "^5.0.0" } }, "strip-bom": { @@ -11736,7 +11736,7 @@ "integrity": "sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4=", "dev": true, "requires": { - "is-utf8": "0.2.1" + "is-utf8": "^0.2.0" } }, "strip-bom-stream": { @@ -11745,8 +11745,8 @@ "integrity": "sha1-5xRDmFd9Uaa+0PoZlPoF9D/ZiO4=", "dev": true, "requires": { - "first-chunk-stream": "1.0.0", - "strip-bom": "2.0.0" + "first-chunk-stream": "^1.0.0", + "strip-bom": "^2.0.0" } }, "strip-comments": { @@ -11754,8 +11754,8 @@ "resolved": "https://registry.npmjs.org/strip-comments/-/strip-comments-1.0.2.tgz", "integrity": "sha512-kL97alc47hoyIQSV165tTt9rG5dn4w1dNnBhOQ3bOU1Nc1hel09jnXANaHJ7vzHLd4Ju8kseDGzlev96pghLFw==", "requires": { - "babel-extract-comments": "1.0.0", - "babel-plugin-transform-object-rest-spread": "6.26.0" + "babel-extract-comments": "^1.0.0", + "babel-plugin-transform-object-rest-spread": "^6.26.0" } }, "strip-dirs": { @@ -11764,7 +11764,7 @@ "integrity": "sha512-JOCxOeKLm2CAS73y/U4ZeZPTkE+gNVCzKt7Eox84Iej1LT/2pTWYpZKJuxwQpvX1LiZb1xokNR7RLfuBAa7T3g==", "dev": true, "requires": { - "is-natural-number": "4.0.1" + "is-natural-number": "^4.0.1" } }, "strip-eof": { @@ -11779,7 +11779,7 @@ "integrity": "sha1-DHlipq3vp7vUrDZkYKY4VSrhoKI=", "dev": true, "requires": { - "get-stdin": "4.0.1" + "get-stdin": "^4.0.1" } }, "strip-outer": { @@ -11788,7 +11788,7 @@ "integrity": "sha512-k55yxKHwaXnpYGsOzg4Vl8+tDrWylxDEpknGjhTiZB8dFRU5rTo9CAzeycivxV3s+zlTKwrs6WxMxR95n26kwg==", "dev": true, "requires": { - "escape-string-regexp": "1.0.5" + "escape-string-regexp": "^1.0.2" } }, "supports-color": { @@ -11796,7 +11796,7 @@ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", "requires": { - "has-flag": "4.0.0" + "has-flag": "^4.0.0" } }, "svgo": { @@ -11805,19 +11805,19 @@ "integrity": "sha512-yhy/sQYxR5BkC98CY7o31VGsg014AKLEPxdfhora76l36hD9Rdy5NZA/Ocn6yayNPgSamYdtX2rFJdcv07AYVw==", "dev": true, "requires": { - "chalk": "2.4.2", - "coa": "2.0.2", - "css-select": "2.1.0", - "css-select-base-adapter": "0.1.1", + "chalk": "^2.4.1", + "coa": "^2.0.2", + "css-select": "^2.0.0", + "css-select-base-adapter": "^0.1.1", "css-tree": "1.0.0-alpha.37", - "csso": "4.0.3", - "js-yaml": "3.13.1", - "mkdirp": "0.5.4", - "object.values": "1.1.1", - "sax": "1.2.4", - "stable": "0.1.8", - "unquote": "1.1.1", - "util.promisify": "1.0.1" + "csso": "^4.0.2", + "js-yaml": "^3.13.1", + "mkdirp": "~0.5.1", + "object.values": "^1.1.0", + "sax": "~1.2.4", + "stable": "^0.1.8", + "unquote": "~1.1.1", + "util.promisify": "~1.0.0" }, "dependencies": { "ansi-styles": { @@ -11826,7 +11826,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -11835,9 +11835,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -11867,7 +11867,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -11884,9 +11884,9 @@ "integrity": "sha1-jk0qJWwOIYXGsYrWlK7JaLg8sdE=", "dev": true, "requires": { - "block-stream": "0.0.9", - "fstream": "1.0.12", - "inherits": "2.0.4" + "block-stream": "*", + "fstream": "^1.0.2", + "inherits": "2" } }, "tar-stream": { @@ -11894,11 +11894,11 @@ "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.1.2.tgz", "integrity": "sha512-UaF6FoJ32WqALZGOIAApXx+OdxhekNMChu6axLJR85zMMjXKWFGjbIRe+J6P4UnRGg9rAwWvbTT0oI7hD/Un7Q==", "requires": { - "bl": "4.0.2", - "end-of-stream": "1.4.4", - "fs-constants": "1.0.0", - "inherits": "2.0.4", - "readable-stream": "3.6.0" + "bl": "^4.0.1", + "end-of-stream": "^1.4.1", + "fs-constants": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^3.1.1" } }, "temp-dir": { @@ -11913,7 +11913,7 @@ "integrity": "sha1-gHFzBDeHByDpQxUy/igUNk+IA9c=", "dev": true, "requires": { - "rimraf": "2.5.4" + "rimraf": "~2.5.2" }, "dependencies": { "rimraf": { @@ -11922,7 +11922,7 @@ "integrity": "sha1-loAAk8vxoMhr2VtGJUZ1NcKd+gQ=", "dev": true, "requires": { - "glob": "7.1.6" + "glob": "^7.0.5" } } } @@ -11933,8 +11933,8 @@ "integrity": "sha1-awRGhWqbERTRhW/8vlCczLCXcmU=", "dev": true, "requires": { - "temp-dir": "1.0.0", - "uuid": "3.4.0" + "temp-dir": "^1.0.0", + "uuid": "^3.0.1" } }, "ternary-stream": { @@ -11943,10 +11943,10 @@ "integrity": "sha512-j6ei9hxSoyGlqTmoMjOm+QNvUKDOIY6bNl4Uh1lhBvl6yjPW2iLqxDUYyfDPZknQ4KdRziFl+ec99iT4l7g0cw==", "dev": true, "requires": { - "duplexify": "3.7.1", - "fork-stream": "0.0.4", - "merge-stream": "1.0.1", - "through2": "2.0.5" + "duplexify": "^3.5.0", + "fork-stream": "^0.0.4", + "merge-stream": "^1.0.0", + "through2": "^2.0.1" }, "dependencies": { "merge-stream": { @@ -11955,7 +11955,7 @@ "integrity": "sha1-QEEgLVCKNCugAXQAjfDCUbjBNeE=", "dev": true, "requires": { - "readable-stream": "2.3.7" + "readable-stream": "^2.0.1" } }, "readable-stream": { @@ -11964,13 +11964,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -11981,9 +11981,9 @@ "integrity": "sha512-fmr7M1f7DBly5cX2+rFDvmGBAaaZyPrHYK4mMdHEDAdNTqXSZgSOfqsfGq2HqPGT/1V0foZZuCZFx8CHKgAk3g==", "dev": true, "requires": { - "commander": "2.20.3", - "source-map": "0.6.1", - "source-map-support": "0.5.16" + "commander": "^2.20.0", + "source-map": "~0.6.1", + "source-map-support": "~0.5.12" }, "dependencies": { "source-map": { @@ -12006,8 +12006,8 @@ "integrity": "sha1-OORBT8ZJd9h6/apy+sttKfgve1s=", "dev": true, "requires": { - "chalk": "1.1.3", - "object-path": "0.9.2" + "chalk": "^1.1.1", + "object-path": "^0.9.0" }, "dependencies": { "ansi-regex": { @@ -12028,11 +12028,11 @@ "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "strip-ansi": { @@ -12041,7 +12041,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -12064,8 +12064,8 @@ "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", "dev": true, "requires": { - "readable-stream": "2.3.7", - "xtend": "4.0.2" + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" }, "dependencies": { "readable-stream": { @@ -12074,13 +12074,13 @@ "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", - "isarray": "1.0.0", - "process-nextick-args": "2.0.1", - "safe-buffer": "5.1.2", - "string_decoder": "1.1.1", - "util-deprecate": "1.0.2" + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" } } } @@ -12091,7 +12091,7 @@ "integrity": "sha512-R5/jLkfMvdmDD+seLwN7vB+mhbqzWop5fAjx5IX8/yQq7VhBhzDmhXgaHAOnhnWkCpRMM7gToYHycB0CS/pd+A==", "dev": true, "requires": { - "through2": "2.0.5" + "through2": "^2.0.0" } }, "through2-filter": { @@ -12100,8 +12100,8 @@ "integrity": "sha1-YLxVoNrLdghdsfna6Zq0P4PWIuw=", "dev": true, "requires": { - "through2": "2.0.5", - "xtend": "4.0.2" + "through2": "~2.0.0", + "xtend": "~4.0.0" } }, "thunks": { @@ -12116,7 +12116,7 @@ "integrity": "sha1-3OwD9V3Km3qj5bBPIYF+tW5jWIo=", "dev": true, "requires": { - "os-homedir": "1.0.2" + "os-homedir": "^1.0.0" } }, "time-stamp": { @@ -12137,7 +12137,7 @@ "integrity": "sha1-HN+kcqnvUMI57maZm2YsoOs5k38=", "dev": true, "requires": { - "extend-shallow": "2.0.1" + "extend-shallow": "^2.0.1" }, "dependencies": { "extend-shallow": { @@ -12146,7 +12146,7 @@ "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, "requires": { - "is-extendable": "0.1.1" + "is-extendable": "^0.1.0" } } } @@ -12169,7 +12169,7 @@ "integrity": "sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68=", "dev": true, "requires": { - "kind-of": "3.2.2" + "kind-of": "^3.0.2" }, "dependencies": { "kind-of": { @@ -12178,7 +12178,7 @@ "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, "requires": { - "is-buffer": "1.1.6" + "is-buffer": "^1.1.5" } } } @@ -12189,10 +12189,10 @@ "integrity": "sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw==", "dev": true, "requires": { - "define-property": "2.0.2", - "extend-shallow": "3.0.2", - "regex-not": "1.0.2", - "safe-regex": "1.1.0" + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "regex-not": "^1.0.2", + "safe-regex": "^1.1.0" } }, "to-regex-range": { @@ -12201,8 +12201,8 @@ "integrity": "sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg=", "dev": true, "requires": { - "is-number": "3.0.0", - "repeat-string": "1.6.1" + "is-number": "^3.0.0", + "repeat-string": "^1.6.1" } }, "to-through": { @@ -12211,7 +12211,7 @@ "integrity": "sha1-/JKtq6ByZHvAtn1rA2ZKoZUJOvY=", "dev": true, "requires": { - "through2": "2.0.5" + "through2": "^2.0.3" } }, "toidentifier": { @@ -12226,7 +12226,7 @@ "integrity": "sha512-WBx8Uy5TLtOSRtIq+M03/sKDrXCLHxwDcquSP2c43Le03/9serjQBIztjRz6FkJez9D/hleyAXTBGLwwZUw9lA==", "dev": true, "requires": { - "nopt": "1.0.10" + "nopt": "~1.0.10" } }, "tough-cookie": { @@ -12234,8 +12234,8 @@ "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz", "integrity": "sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==", "requires": { - "psl": "1.8.0", - "punycode": "2.1.1" + "psl": "^1.1.28", + "punycode": "^2.1.1" } }, "trim-newlines": { @@ -12250,7 +12250,7 @@ "integrity": "sha1-42RqLqTokTEr9+rObPsFOAvAHCE=", "dev": true, "requires": { - "escape-string-regexp": "1.0.5" + "escape-string-regexp": "^1.0.2" } }, "true-case-path": { @@ -12259,7 +12259,7 @@ "integrity": "sha512-m6s2OdQe5wgpFMC+pAJ+q9djG82O2jcHPOI6RNg1yy9rCYR+WD6Nbpl32fDpfC56nirdRy+opFa/Vk7HYhqaew==", "dev": true, "requires": { - "glob": "7.1.6" + "glob": "^7.1.2" } }, "tslib": { @@ -12273,7 +12273,7 @@ "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", "requires": { - "safe-buffer": "5.1.2" + "safe-buffer": "^5.0.1" } }, "tweetnacl": { @@ -12298,8 +12298,8 @@ "integrity": "sha512-Y2VsbPVs0FIshJztycsO2SfPk7/KAF/T72qzv9u5EpQ4kB2hQoHlhNQTsNyy6ul7lQtqJN/AoWeS23OzEiEFxw==", "dev": true, "requires": { - "commander": "2.19.0", - "source-map": "0.6.1" + "commander": "~2.19.0", + "source-map": "~0.6.1" }, "dependencies": { "commander": { @@ -12328,8 +12328,8 @@ "integrity": "sha512-fUlAF7U9Ah1Q6EieQ4x4zLNejrRvDWUYmxXUpN3uziFYCHapjWFaCAnreY9bGgxzaMCFAPPpYNng57CypwJVhg==", "dev": true, "requires": { - "buffer": "5.5.0", - "through": "2.3.8" + "buffer": "^5.2.1", + "through": "^2.3.8" } }, "unc-path-regex": { @@ -12350,10 +12350,10 @@ "integrity": "sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg==", "dev": true, "requires": { - "arr-union": "3.1.0", - "get-value": "2.0.6", - "is-extendable": "0.1.1", - "set-value": "2.0.1" + "arr-union": "^3.1.0", + "get-value": "^2.0.6", + "is-extendable": "^0.1.1", + "set-value": "^2.0.1" } }, "unique-stream": { @@ -12385,8 +12385,8 @@ "integrity": "sha1-g3aHP30jNRef+x5vw6jtDfyKtVk=", "dev": true, "requires": { - "has-value": "0.3.1", - "isobject": "3.0.1" + "has-value": "^0.3.1", + "isobject": "^3.0.0" }, "dependencies": { "has-value": { @@ -12395,9 +12395,9 @@ "integrity": "sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8=", "dev": true, "requires": { - "get-value": "2.0.6", - "has-values": "0.1.4", - "isobject": "2.1.0" + "get-value": "^2.0.3", + "has-values": "^0.1.4", + "isobject": "^2.0.0" }, "dependencies": { "isobject": { @@ -12425,7 +12425,7 @@ "integrity": "sha1-F+soB5h/dpUunASF/DEdBqgmouA=", "dev": true, "requires": { - "os-homedir": "1.0.2" + "os-homedir": "^1.0.0" } }, "upath": { @@ -12445,7 +12445,7 @@ "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", "requires": { - "punycode": "2.1.1" + "punycode": "^2.1.0" } }, "urijs": { @@ -12467,7 +12467,7 @@ "dev": true, "optional": true, "requires": { - "prepend-http": "1.0.4" + "prepend-http": "^1.0.1" } }, "url-to-options": { @@ -12505,10 +12505,10 @@ "integrity": "sha512-g9JpC/3He3bm38zsLupWryXHoEcS22YHthuPQSJdMy6KNrzIRzWqcsHzD/WUnqe45whVou4VIsPew37DoXWNrA==", "dev": true, "requires": { - "define-properties": "1.1.3", - "es-abstract": "1.17.5", - "has-symbols": "1.0.1", - "object.getownpropertydescriptors": "2.1.0" + "define-properties": "^1.1.3", + "es-abstract": "^1.17.2", + "has-symbols": "^1.0.1", + "object.getownpropertydescriptors": "^2.1.0" } }, "utils-merge": { @@ -12528,7 +12528,7 @@ "integrity": "sha1-qrGh+jDUX4jdMhFIh1rALAtV5bQ=", "dev": true, "requires": { - "user-home": "1.1.1" + "user-home": "^1.1.1" } }, "vali-date": { @@ -12543,8 +12543,8 @@ "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", "dev": true, "requires": { - "spdx-correct": "3.1.0", - "spdx-expression-parse": "3.0.0" + "spdx-correct": "^3.0.0", + "spdx-expression-parse": "^3.0.0" } }, "value-or-function": { @@ -12558,9 +12558,9 @@ "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", "requires": { - "assert-plus": "1.0.0", + "assert-plus": "^1.0.0", "core-util-is": "1.0.2", - "extsprintf": "1.3.0" + "extsprintf": "^1.2.0" } }, "vinyl": { @@ -12569,8 +12569,8 @@ "integrity": "sha1-sEVbOPxeDPMNQyUTLkYZcMIJHN4=", "dev": true, "requires": { - "clone": "1.0.4", - "clone-stats": "0.0.1", + "clone": "^1.0.0", + "clone-stats": "^0.0.1", "replace-ext": "0.0.1" } }, @@ -12589,14 +12589,14 @@ "integrity": "sha1-mmhRzhysHBzqX+hsCTHWIMLPqeY=", "dev": true, "requires": { - "defaults": "1.0.3", - "glob-stream": "3.1.18", - "glob-watcher": "0.0.6", - "graceful-fs": "3.0.12", - "mkdirp": "0.5.4", - "strip-bom": "1.0.0", - "through2": "0.6.5", - "vinyl": "0.4.6" + "defaults": "^1.0.0", + "glob-stream": "^3.1.5", + "glob-watcher": "^0.0.6", + "graceful-fs": "^3.0.0", + "mkdirp": "^0.5.0", + "strip-bom": "^1.0.0", + "through2": "^0.6.1", + "vinyl": "^0.4.0" }, "dependencies": { "clone": { @@ -12611,7 +12611,7 @@ "integrity": "sha512-J55gaCS4iTTJfTXIxSVw3EMQckcqkpdRv3IR7gu6sq0+tbC363Zx6KH/SEwXASK9JRbhyZmVjJEVJIOxYsB3Qg==", "dev": true, "requires": { - "natives": "1.1.6" + "natives": "^1.1.3" } }, "isarray": { @@ -12626,10 +12626,10 @@ "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", "dev": true, "requires": { - "core-util-is": "1.0.2", - "inherits": "2.0.4", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", "isarray": "0.0.1", - "string_decoder": "0.10.31" + "string_decoder": "~0.10.x" } }, "string_decoder": { @@ -12644,8 +12644,8 @@ "integrity": "sha1-hbiGLzhEtabV7IRnqTWYFzo295Q=", "dev": true, "requires": { - "first-chunk-stream": "1.0.0", - "is-utf8": "0.2.1" + "first-chunk-stream": "^1.0.0", + "is-utf8": "^0.2.0" } }, "through2": { @@ -12654,8 +12654,8 @@ "integrity": "sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg=", "dev": true, "requires": { - "readable-stream": "1.0.34", - "xtend": "4.0.2" + "readable-stream": ">=1.0.33-1 <1.1.0-0", + "xtend": ">=4.0.0 <4.1.0-0" } }, "vinyl": { @@ -12664,8 +12664,8 @@ "integrity": "sha1-LzVsh6VQolVGHza76ypbqL94SEc=", "dev": true, "requires": { - "clone": "0.2.0", - "clone-stats": "0.0.1" + "clone": "^0.2.0", + "clone-stats": "^0.0.1" } } } @@ -12676,8 +12676,8 @@ "integrity": "sha1-84pa+53R6Ttl1VBGmsYYKsT1S44=", "dev": true, "requires": { - "through2": "2.0.5", - "vinyl": "2.2.0" + "through2": "^2.0.3", + "vinyl": "^2.1.0" }, "dependencies": { "clone": { @@ -12704,12 +12704,12 @@ "integrity": "sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg==", "dev": true, "requires": { - "clone": "2.1.2", - "clone-buffer": "1.0.0", - "clone-stats": "1.0.0", - "cloneable-readable": "1.1.3", - "remove-trailing-separator": "1.1.0", - "replace-ext": "1.0.0" + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" } } } @@ -12720,13 +12720,13 @@ "integrity": "sha1-kqgAWTo4cDqM2xHYswCtS+Y7PhY=", "dev": true, "requires": { - "append-buffer": "1.0.2", - "convert-source-map": "1.7.0", - "graceful-fs": "4.2.3", - "normalize-path": "2.1.1", - "now-and-later": "2.0.1", - "remove-bom-buffer": "3.0.0", - "vinyl": "2.2.0" + "append-buffer": "^1.0.2", + "convert-source-map": "^1.5.0", + "graceful-fs": "^4.1.6", + "normalize-path": "^2.1.1", + "now-and-later": "^2.0.0", + "remove-bom-buffer": "^3.0.0", + "vinyl": "^2.0.0" }, "dependencies": { "clone": { @@ -12747,7 +12747,7 @@ "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", "dev": true, "requires": { - "remove-trailing-separator": "1.1.0" + "remove-trailing-separator": "^1.0.1" } }, "replace-ext": { @@ -12762,12 +12762,12 @@ "integrity": "sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg==", "dev": true, "requires": { - "clone": "2.1.2", - "clone-buffer": "1.0.0", - "clone-stats": "1.0.0", - "cloneable-readable": "1.1.3", - "remove-trailing-separator": "1.1.0", - "replace-ext": "1.0.0" + "clone": "^2.1.1", + "clone-buffer": "^1.0.0", + "clone-stats": "^1.0.0", + "cloneable-readable": "^1.0.0", + "remove-trailing-separator": "^1.0.1", + "replace-ext": "^1.0.0" } } } @@ -12778,7 +12778,7 @@ "integrity": "sha1-q2VJ1h0XLCsbh75cUI0jnI74dwU=", "dev": true, "requires": { - "source-map": "0.5.7" + "source-map": "^0.5.1" } }, "wdio-browserstack-service": { @@ -12787,9 +12787,9 @@ "integrity": "sha512-ZAq20McWrQy80FQst+4cn1l5WRP9u+9DOKif2TarxYFzw/EmhdNg9TFcXBT5dxH+LcP5v47v7mXMmsO7B3+92Q==", "dev": true, "requires": { - "browserstack-local": "1.4.5", - "request": "2.88.2", - "request-promise": "4.2.5" + "browserstack-local": "^1.3.7", + "request": "^2.81.0", + "request-promise": "^4.2.1" } }, "wdio-mocha-framework": { @@ -12798,8 +12798,8 @@ "integrity": "sha512-GZsXwoW60/fkkfqZJR/ZAdiALaM+hW+BbnTT9x214qPR4Pe5XeyYxhJNEdyf0dNI9625cMdkyZYaWoFHN5zDcA==", "dev": true, "requires": { - "babel-runtime": "6.26.0", - "mocha": "5.2.0", + "babel-runtime": "^6.23.0", + "mocha": "^5.2.0", "wdio-sync": "0.7.3" } }, @@ -12809,8 +12809,8 @@ "integrity": "sha512-R8iUL30SkFfZictAG5wRofeCsHQ4bIucDtaArCQWZkUqS+DlGTStIk3TaIOCaX7dS7UW1YN/lJt9Vsn4Ekmoxg==", "dev": true, "requires": { - "fs-extra": "0.30.0", - "selenium-standalone": "6.17.0" + "fs-extra": "^0.30.0", + "selenium-standalone": "^6.15.4" }, "dependencies": { "fs-extra": { @@ -12819,11 +12819,11 @@ "integrity": "sha1-8jP/zAjU2n1DLapEl3aYnbHfk/A=", "dev": true, "requires": { - "graceful-fs": "4.2.3", - "jsonfile": "2.4.0", - "klaw": "1.3.1", - "path-is-absolute": "1.0.1", - "rimraf": "2.7.1" + "graceful-fs": "^4.1.2", + "jsonfile": "^2.1.0", + "klaw": "^1.0.0", + "path-is-absolute": "^1.0.0", + "rimraf": "^2.2.8" } }, "jsonfile": { @@ -12832,7 +12832,7 @@ "integrity": "sha1-NzaitCi4e72gzIO1P6PWM6NcKug=", "dev": true, "requires": { - "graceful-fs": "4.2.3" + "graceful-fs": "^4.1.6" } } } @@ -12843,9 +12843,9 @@ "integrity": "sha512-MqvgTow8hFwhFT47q67JwyJyeynKodGRQCxF7ijKPGfsaG1NLssbXYc0JhiL7SiAyxnQxII0UxzTCd3I6sEdkg==", "dev": true, "requires": { - "babel-runtime": "6.26.0", - "chalk": "2.4.2", - "humanize-duration": "3.15.3" + "babel-runtime": "~6.26.0", + "chalk": "^2.3.0", + "humanize-duration": "~3.15.0" }, "dependencies": { "ansi-styles": { @@ -12854,7 +12854,7 @@ "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "dev": true, "requires": { - "color-convert": "1.9.3" + "color-convert": "^1.9.0" } }, "chalk": { @@ -12863,9 +12863,9 @@ "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "3.2.1", - "escape-string-regexp": "1.0.5", - "supports-color": "5.5.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" } }, "color-convert": { @@ -12895,7 +12895,7 @@ "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", "dev": true, "requires": { - "has-flag": "3.0.0" + "has-flag": "^3.0.0" } } } @@ -12906,9 +12906,9 @@ "integrity": "sha512-ukASSHOQmOxaz5HTILR0jykqlHBtAPsBpMtwhpiG0aW9uc7SO7PF+E5LhVvTG4ypAh+UGmY3rTjohOsqDr39jw==", "dev": true, "requires": { - "babel-runtime": "6.26.0", - "fibers": "3.1.1", - "object.assign": "4.1.0" + "babel-runtime": "^6.26.0", + "fibers": "^3.0.0", + "object.assign": "^4.0.3" } }, "webdriver": { @@ -12916,13 +12916,13 @@ "resolved": "https://registry.npmjs.org/webdriver/-/webdriver-5.22.4.tgz", "integrity": "sha512-IrSb8UUt6MDgBIDaSWyh/kP4VJsHyqnubCTxKi2cEZjOQdxPwnxUfvbSQlMDCHXrcgsPaXwAPjRJVTEt6PzArQ==", "requires": { - "@types/request": "2.48.4", + "@types/request": "^2.48.4", "@wdio/config": "5.22.4", "@wdio/logger": "5.16.10", "@wdio/protocols": "5.22.1", "@wdio/utils": "5.18.6", - "lodash.merge": "4.6.2", - "request": "2.88.2" + "lodash.merge": "^4.6.1", + "request": "^2.83.0" } }, "webdriverio": { @@ -12934,16 +12934,16 @@ "@wdio/logger": "5.16.10", "@wdio/repl": "5.18.6", "@wdio/utils": "5.18.6", - "archiver": "3.1.1", - "css-value": "0.0.1", - "grapheme-splitter": "1.0.4", - "lodash.clonedeep": "4.5.0", - "lodash.isobject": "3.0.2", - "lodash.isplainobject": "4.0.6", - "lodash.zip": "4.2.0", - "resq": "1.7.1", - "rgb2hex": "0.1.10", - "serialize-error": "5.0.0", + "archiver": "^3.0.0", + "css-value": "^0.0.1", + "grapheme-splitter": "^1.0.2", + "lodash.clonedeep": "^4.5.0", + "lodash.isobject": "^3.0.2", + "lodash.isplainobject": "^4.0.6", + "lodash.zip": "^4.2.0", + "resq": "^1.6.0", + "rgb2hex": "^0.1.0", + "serialize-error": "^5.0.0", "webdriver": "5.22.4" } }, @@ -12953,7 +12953,7 @@ "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", "dev": true, "requires": { - "isexe": "2.0.0" + "isexe": "^2.0.0" } }, "which-module": { @@ -12968,7 +12968,7 @@ "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", "dev": true, "requires": { - "string-width": "1.0.2" + "string-width": "^1.0.2 || 2" } }, "window-size": { @@ -12983,12 +12983,12 @@ "integrity": "sha1-7pVIqVBN/n6FQBpDXb7SybTqLkQ=", "dev": true, "requires": { - "bower-config": "1.4.1", - "glob": "7.1.6", - "lodash": "4.17.15", - "propprop": "0.3.1", - "through2": "2.0.5", - "wiredep-cli": "0.1.0" + "bower-config": "^1.3.0", + "glob": "^7.0.3", + "lodash": "^4.6.1", + "propprop": "^0.3.0", + "through2": "^2.0.1", + "wiredep-cli": "^0.1.0" } }, "wiredep-cli": { @@ -12997,9 +12997,9 @@ "integrity": "sha1-ZCcr/KKUYfvQdEMVix4FZSb2xzk=", "dev": true, "requires": { - "chalk": "1.1.3", - "minimist": "1.2.5", - "wiredep": "4.0.0" + "chalk": "^1.1.1", + "minimist": "^1.1.0", + "wiredep": "*" }, "dependencies": { "ansi-regex": { @@ -13020,11 +13020,11 @@ "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", "dev": true, "requires": { - "ansi-styles": "2.2.1", - "escape-string-regexp": "1.0.5", - "has-ansi": "2.0.0", - "strip-ansi": "3.0.1", - "supports-color": "2.0.0" + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" } }, "strip-ansi": { @@ -13033,7 +13033,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } }, "supports-color": { @@ -13055,7 +13055,7 @@ "resolved": "https://registry.npmjs.org/workbox-background-sync/-/workbox-background-sync-4.3.1.tgz", "integrity": "sha512-1uFkvU8JXi7L7fCHVBEEnc3asPpiAL33kO495UMcD5+arew9IbKW2rV5lpzhoWcm/qhGB89YfO4PmB/0hQwPRg==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-broadcast-update": { @@ -13063,7 +13063,7 @@ "resolved": "https://registry.npmjs.org/workbox-broadcast-update/-/workbox-broadcast-update-4.3.1.tgz", "integrity": "sha512-MTSfgzIljpKLTBPROo4IpKjESD86pPFlZwlvVG32Kb70hW+aob4Jxpblud8EhNb1/L5m43DUM4q7C+W6eQMMbA==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-build": { @@ -13071,29 +13071,29 @@ "resolved": "https://registry.npmjs.org/workbox-build/-/workbox-build-4.3.1.tgz", "integrity": "sha512-UHdwrN3FrDvicM3AqJS/J07X0KXj67R8Cg0waq1MKEOqzo89ap6zh6LmaLnRAjpB+bDIz+7OlPye9iii9KBnxw==", "requires": { - "@babel/runtime": "7.9.2", - "@hapi/joi": "15.1.1", - "common-tags": "1.8.0", - "fs-extra": "4.0.3", - "glob": "7.1.6", - "lodash.template": "4.5.0", - "pretty-bytes": "5.3.0", - "stringify-object": "3.3.0", - "strip-comments": "1.0.2", - "workbox-background-sync": "4.3.1", - "workbox-broadcast-update": "4.3.1", - "workbox-cacheable-response": "4.3.1", - "workbox-core": "4.3.1", - "workbox-expiration": "4.3.1", - "workbox-google-analytics": "4.3.1", - "workbox-navigation-preload": "4.3.1", - "workbox-precaching": "4.3.1", - "workbox-range-requests": "4.3.1", - "workbox-routing": "4.3.1", - "workbox-strategies": "4.3.1", - "workbox-streams": "4.3.1", - "workbox-sw": "4.3.1", - "workbox-window": "4.3.1" + "@babel/runtime": "^7.3.4", + "@hapi/joi": "^15.0.0", + "common-tags": "^1.8.0", + "fs-extra": "^4.0.2", + "glob": "^7.1.3", + "lodash.template": "^4.4.0", + "pretty-bytes": "^5.1.0", + "stringify-object": "^3.3.0", + "strip-comments": "^1.0.2", + "workbox-background-sync": "^4.3.1", + "workbox-broadcast-update": "^4.3.1", + "workbox-cacheable-response": "^4.3.1", + "workbox-core": "^4.3.1", + "workbox-expiration": "^4.3.1", + "workbox-google-analytics": "^4.3.1", + "workbox-navigation-preload": "^4.3.1", + "workbox-precaching": "^4.3.1", + "workbox-range-requests": "^4.3.1", + "workbox-routing": "^4.3.1", + "workbox-strategies": "^4.3.1", + "workbox-streams": "^4.3.1", + "workbox-sw": "^4.3.1", + "workbox-window": "^4.3.1" } }, "workbox-cacheable-response": { @@ -13101,7 +13101,7 @@ "resolved": "https://registry.npmjs.org/workbox-cacheable-response/-/workbox-cacheable-response-4.3.1.tgz", "integrity": "sha512-Rp5qlzm6z8IOvnQNkCdO9qrDgDpoPNguovs0H8C+wswLuPgSzSp9p2afb5maUt9R1uTIwOXrVQMmPfPypv+npw==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-core": { @@ -13114,7 +13114,7 @@ "resolved": "https://registry.npmjs.org/workbox-expiration/-/workbox-expiration-4.3.1.tgz", "integrity": "sha512-vsJLhgQsQouv9m0rpbXubT5jw0jMQdjpkum0uT+d9tTwhXcEZks7qLfQ9dGSaufTD2eimxbUOJfWLbNQpIDMPw==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-google-analytics": { @@ -13122,10 +13122,10 @@ "resolved": "https://registry.npmjs.org/workbox-google-analytics/-/workbox-google-analytics-4.3.1.tgz", "integrity": "sha512-xzCjAoKuOb55CBSwQrbyWBKqp35yg1vw9ohIlU2wTy06ZrYfJ8rKochb1MSGlnoBfXGWss3UPzxR5QL5guIFdg==", "requires": { - "workbox-background-sync": "4.3.1", - "workbox-core": "4.3.1", - "workbox-routing": "4.3.1", - "workbox-strategies": "4.3.1" + "workbox-background-sync": "^4.3.1", + "workbox-core": "^4.3.1", + "workbox-routing": "^4.3.1", + "workbox-strategies": "^4.3.1" } }, "workbox-navigation-preload": { @@ -13133,7 +13133,7 @@ "resolved": "https://registry.npmjs.org/workbox-navigation-preload/-/workbox-navigation-preload-4.3.1.tgz", "integrity": "sha512-K076n3oFHYp16/C+F8CwrRqD25GitA6Rkd6+qAmLmMv1QHPI2jfDwYqrytOfKfYq42bYtW8Pr21ejZX7GvALOw==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-precaching": { @@ -13141,7 +13141,7 @@ "resolved": "https://registry.npmjs.org/workbox-precaching/-/workbox-precaching-4.3.1.tgz", "integrity": "sha512-piSg/2csPoIi/vPpp48t1q5JLYjMkmg5gsXBQkh/QYapCdVwwmKlU9mHdmy52KsDGIjVaqEUMFvEzn2LRaigqQ==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-range-requests": { @@ -13149,7 +13149,7 @@ "resolved": "https://registry.npmjs.org/workbox-range-requests/-/workbox-range-requests-4.3.1.tgz", "integrity": "sha512-S+HhL9+iTFypJZ/yQSl/x2Bf5pWnbXdd3j57xnb0V60FW1LVn9LRZkPtneODklzYuFZv7qK6riZ5BNyc0R0jZA==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-routing": { @@ -13157,7 +13157,7 @@ "resolved": "https://registry.npmjs.org/workbox-routing/-/workbox-routing-4.3.1.tgz", "integrity": "sha512-FkbtrODA4Imsi0p7TW9u9MXuQ5P4pVs1sWHK4dJMMChVROsbEltuE79fBoIk/BCztvOJ7yUpErMKa4z3uQLX+g==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-strategies": { @@ -13165,7 +13165,7 @@ "resolved": "https://registry.npmjs.org/workbox-strategies/-/workbox-strategies-4.3.1.tgz", "integrity": "sha512-F/+E57BmVG8dX6dCCopBlkDvvhg/zj6VDs0PigYwSN23L8hseSRwljrceU2WzTvk/+BSYICsWmRq5qHS2UYzhw==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-streams": { @@ -13173,7 +13173,7 @@ "resolved": "https://registry.npmjs.org/workbox-streams/-/workbox-streams-4.3.1.tgz", "integrity": "sha512-4Kisis1f/y0ihf4l3u/+ndMkJkIT4/6UOacU3A4BwZSAC9pQ9vSvJpIi/WFGQRH/uPXvuVjF5c2RfIPQFSS2uA==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "workbox-sw": { @@ -13186,7 +13186,7 @@ "resolved": "https://registry.npmjs.org/workbox-window/-/workbox-window-4.3.1.tgz", "integrity": "sha512-C5gWKh6I58w3GeSc0wp2Ne+rqVw8qwcmZnQGpjiek8A2wpbxSJb1FdCoQVO+jDJs35bFgo/WETgl1fqgsxN0Hg==", "requires": { - "workbox-core": "4.3.1" + "workbox-core": "^4.3.1" } }, "wrap-ansi": { @@ -13195,8 +13195,8 @@ "integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=", "dev": true, "requires": { - "string-width": "1.0.2", - "strip-ansi": "3.0.1" + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1" }, "dependencies": { "ansi-regex": { @@ -13211,7 +13211,7 @@ "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { - "ansi-regex": "2.1.1" + "ansi-regex": "^2.0.0" } } } @@ -13222,7 +13222,7 @@ "integrity": "sha1-sBn0I2zL8ftWCSG0tIcLe9ovUlU=", "dev": true, "requires": { - "es6-promise": "2.3.0" + "es6-promise": "^2.3.0" } }, "wrappy": { @@ -13236,7 +13236,7 @@ "integrity": "sha512-eqZfL+NE/YQc1/ZynhojeV8q+H050oR8AZ2uIev7RU10svA9ZnJUddHcOUZTJLinZ9yEfdA2kSATS2qZK5fhJA==", "dev": true, "requires": { - "async-limiter": "1.0.1" + "async-limiter": "~1.0.0" } }, "xmlbuilder": { @@ -13275,20 +13275,20 @@ "integrity": "sha1-gW4ahm1VmMzzTlWW3c4i2S2kkNQ=", "dev": true, "requires": { - "camelcase": "3.0.0", - "cliui": "3.2.0", - "decamelize": "1.2.0", - "get-caller-file": "1.0.3", - "os-locale": "1.4.0", - "read-pkg-up": "1.0.1", - "require-directory": "2.1.1", - "require-main-filename": "1.0.1", - "set-blocking": "2.0.0", - "string-width": "1.0.2", - "which-module": "1.0.0", - "window-size": "0.2.0", - "y18n": "3.2.1", - "yargs-parser": "4.2.1" + "camelcase": "^3.0.0", + "cliui": "^3.2.0", + "decamelize": "^1.1.1", + "get-caller-file": "^1.0.1", + "os-locale": "^1.4.0", + "read-pkg-up": "^1.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^1.0.1", + "set-blocking": "^2.0.0", + "string-width": "^1.0.2", + "which-module": "^1.0.0", + "window-size": "^0.2.0", + "y18n": "^3.2.1", + "yargs-parser": "^4.1.0" } }, "yargs-parser": { @@ -13297,7 +13297,7 @@ "integrity": "sha1-KczqwNxPA8bIe0qfIX3RjJ90hxw=", "dev": true, "requires": { - "camelcase": "3.0.0" + "camelcase": "^3.0.0" } }, "yauzl": { @@ -13306,8 +13306,8 @@ "integrity": "sha1-x+sXyT4RLLEIb6bY5R+wZnt5pfk=", "dev": true, "requires": { - "buffer-crc32": "0.2.13", - "fd-slicer": "1.1.0" + "buffer-crc32": "~0.2.3", + "fd-slicer": "~1.1.0" } }, "yeast": { @@ -13321,9 +13321,9 @@ "resolved": "https://registry.npmjs.org/zip-stream/-/zip-stream-2.1.3.tgz", "integrity": "sha512-EkXc2JGcKhO5N5aZ7TmuNo45budRaFGHOmz24wtJR7znbNqDPmdZtUauKX6et8KAVseAMBOyWJqEpXcHTBsh7Q==", "requires": { - "archiver-utils": "2.1.0", - "compress-commons": "2.1.1", - "readable-stream": "3.6.0" + "archiver-utils": "^2.1.0", + "compress-commons": "^2.1.1", + "readable-stream": "^3.4.0" } } } diff --git a/client/src/assets/scss/_dashboard.scss b/client/src/assets/scss/_dashboard.scss index da3d561f3c..3926ab4581 100644 --- a/client/src/assets/scss/_dashboard.scss +++ b/client/src/assets/scss/_dashboard.scss @@ -3,11 +3,81 @@ .timestamp { color: $color-white; - text-align: center; + text-align: left; + margin: 30px 0px 10px; + font-size: 18px; + } + + .month-selector { + align-items: center; + display: flex; + justify-content: center; + margin-bottom: 25px; + + .label { + color: white; + font-size: 25px; + margin: 0 40px; + } + + .icon-back.rotate-180 { + transform: rotate(180deg); + } + + .icon-back.hidden { + visibility: hidden; + } + } + + .case-management-label { + color: $color-white; + font-weight: 500; + margin-bottom: 10px; + margin-top: 50px; } .ui.segment { - padding: 1.5rem 2rem; + + .content .very.basic.table { + width: 100%; + + thead { + + th { + font-size: 16px; + line-height: 24px; + font-weight: normal; + padding: 2px 4px 2px; + border-left: 0 none; + border-right: 0 none; + border-bottom: 1px solid $color-text; + color: $color-text; + text-transform: uppercase; + + &.phone-number { + width: 26%; + } + } + } + + tbody { + + td { + font-weight: normal; + font-size: 20px; + line-height: 24px; + border: 0 none; + color: black; + padding: 4px 4px 24px; + vertical-align: top; + + &.phone-number { + justify-content: center; + text-align-last: center; + } + } + } + } &.filters { background-color: $color-light-background; @@ -55,52 +125,40 @@ } } - .content { - - .very.basic.table { - width: 100%; - - thead { + &.chw-filters { + background-color: transparent; + min-height: 40px; + padding: 25px 0; + margin-bottom: 25px; + display: flex; + border-bottom: solid 1px $color-white; - th { - font-size: 16px; - line-height: 24px; - font-weight: normal; - padding: 2px 4px 2px; - border-left: 0 none; - border-right: 0 none; - border-bottom: 1px solid $color-text; - color: $color-text; - text-transform: uppercase; + button { + background-color: $color-white; + border: solid 2px $color-primary; + border-radius: 3px; + color: $color-primary; + width: 300px; + font-size: 24px; + font-weight: 700; + margin-right:25px; + padding: 15px; + text-transform: none; - &.phone-number { - width: 26%; - } - } + &:last-child { + margin-right: 0px; } - tbody { - - td { - font-weight: normal; - font-size: 20px; - line-height: 24px; - border: 0 none; - color: black; - padding: 4px 4px 24px; - vertical-align: top; - - &.phone-number { - justify-content: center; - text-align-last: center; - } - } + &.active { + background-color: $color-primary; + border: solid 2px $color-white; + color: $color-white; } } } - &.family-planning { - margin-bottom: 40px; + &.donut-chart { + margin-top: 40px; .header { @@ -160,11 +218,19 @@ } svg.pie-chart { - position: absolute; - width: 400px; height: 400px; - top: 35px; left: 55px; + position: absolute; + top: 35px; + width: 400px; + } + + svg.pie-chart.fever { + height: 500px; + left: -235px; + position: absolute; + top: 4px; + width: 500px; } .legend { @@ -193,48 +259,76 @@ } } } - } - &.main { + &.donut-chart.fever { + min-height: 300px; - .overlay .ui.modal { - margin-left: -350px; - width: 700px; + .row .content { - .header { - font-size: 30px; - font-weight: 500; - margin-bottom: 25px; - text-align: left; - text-transform: capitalize; - } - - .content { - text-align: left; + svg.pie-chart { + height: 500px; + left: -185px; + position: absolute; + top: 4px; + width: 500px; + } - .helper { + .in-chart { font-size: 18px; - font-weight: bold; - margin-bottom: 3px; + left: 82px; + line-height: 20px; + top: 95px; + width: 175px; } - .select-input { - background: none; - border: 2px solid $color-gray; - font-size: 28px; - height: 50px; - margin-bottom: 20px; - padding: 0 7px; - width: 100%; + .legend { + margin: 0 0 0 400px; + + .legend-item span { + font-size: 18px; + } } } + } + } - .actions { - margin-top: 40px; + .overlay .ui.modal { + margin-left: -350px; + width: 700px; - button { - margin-left: 0; - } + .header { + font-size: 30px; + font-weight: 500; + margin-bottom: 25px; + text-align: left; + text-transform: capitalize; + } + + .content { + text-align: left; + + .helper { + font-size: 18px; + font-weight: bold; + margin-bottom: 3px; + } + + .select-input { + background: none; + border: 2px solid $color-gray; + font-size: 28px; + height: 50px; + margin-bottom: 20px; + padding: 0 7px; + width: 100%; + } + } + + .actions { + margin-top: 40px; + + button { + margin-left: 0; } } } @@ -406,15 +500,17 @@ } } - .dashboard-cards { - padding: 1.5rem 3rem; + .dashboard-card { + padding: 15px 5px 20px; border-radius: 1px; min-height: 130px; .header { font-size: 20px; text-align: center; + font-weight: bolder; line-height: 20px; + height: 65px; } .this-year { @@ -501,6 +597,16 @@ } } + .dashboard-card.chw { + min-height: 150px; + padding: 20px 10px 20px; + border-top:4px solid $color-primary; + + .value { + color: $color-light-background; + } + } + .dashboards-monthly-chart, .fbf-beneficiaries, .case-management { @@ -678,10 +784,6 @@ .case-management .header .filters { margin-bottom: 10px; margin-top: 0; - - &.secondary { - - } } .dashboards-links { diff --git a/client/src/elm/App/Fetch.elm b/client/src/elm/App/Fetch.elm index 93d26056c5..584f73cfd2 100644 --- a/client/src/elm/App/Fetch.elm +++ b/client/src/elm/App/Fetch.elm @@ -92,7 +92,7 @@ fetch model = getLoggedInData model |> Maybe.map (\( healthCenterId, loggedIn ) -> - Pages.Dashboard.Fetch.fetch healthCenterId loggedIn.dashboardPage + Pages.Dashboard.Fetch.fetch currentDate healthCenterId model.indexedDb loggedIn.dashboardPage |> List.map MsgIndexedDb ) |> Maybe.withDefault [] diff --git a/client/src/elm/App/Update.elm b/client/src/elm/App/Update.elm index 78dafca7a0..1c5b5230e5 100644 --- a/client/src/elm/App/Update.elm +++ b/client/src/elm/App/Update.elm @@ -587,7 +587,22 @@ update msg model = ) Pages.PinCode.Model.SetActivePage page -> - ( [ SetActivePage page ], [] ) + let + resetDashboardMsg = + case page of + -- When accessing Dashboard page, reset + -- the page to initial state - selected month, + -- for example will be set to current month. + UserPage (DashboardPage MainPage) -> + Pages.Dashboard.Model.Reset model.villageId + |> MsgPageDashboard MainPage + |> MsgLoggedIn + |> List.singleton + + _ -> + [] + in + ( SetActivePage page :: resetDashboardMsg, [] ) Pages.PinCode.Model.SetHealthCenter id -> ( [ SetHealthCenter (Just id) ], [] ) diff --git a/client/src/elm/App/View.elm b/client/src/elm/App/View.elm index 4c5bb155b2..decd000fca 100644 --- a/client/src/elm/App/View.elm +++ b/client/src/elm/App/View.elm @@ -45,7 +45,7 @@ import Pages.NutritionEncounter.Model import Pages.NutritionEncounter.View import Pages.NutritionParticipant.View import Pages.NutritionProgressReport.View -import Pages.Page exposing (Page(..), SessionPage(..), UserPage(..)) +import Pages.Page exposing (DashboardPage(..), Page(..), SessionPage(..), UserPage(..)) import Pages.PageNotFound.View import Pages.People.View import Pages.Person.View @@ -307,12 +307,50 @@ viewUserPage page deviceName model configured = |> flexPageWrapper model DashboardPage subPage -> - Pages.Dashboard.View.view model.language subPage currentDate healthCenterId isChw (Tuple.second loggedInModel.nurse) loggedInModel.dashboardPage model.indexedDb - |> Html.map (MsgLoggedIn << MsgPageDashboard subPage) - |> flexPageWrapper model + let + viewDashboardPage = + Pages.Dashboard.View.view model.language + subPage + currentDate + healthCenterId + isChw + (Tuple.second loggedInModel.nurse) + loggedInModel.dashboardPage + model.indexedDb + |> Html.map (MsgLoggedIn << MsgPageDashboard subPage) + |> flexPageWrapper model + + viewPageNotFound = + Pages.PageNotFound.View.viewPage model.language (SetActivePage PinCodePage) (UserPage <| DashboardPage subPage) + in + case subPage of + MainPage -> + -- Main page is common for Nurse and CHw. + viewDashboardPage + + NursePage _ -> + if isChw then + -- Only Nursed may access Nursed pages. + viewPageNotFound + + else + viewDashboardPage + + ChwPage _ -> + if isChw then + viewDashboardPage + + else + -- Only CHW may access CHW pages. + viewPageNotFound GlobalCaseManagementPage -> - Pages.GlobalCaseManagement.View.view model.language currentDate ( healthCenterId, model.villageId ) isChw loggedInModel.globalCaseManagementPage model.indexedDb + Pages.GlobalCaseManagement.View.view model.language + currentDate + ( healthCenterId, model.villageId ) + isChw + loggedInModel.globalCaseManagementPage + model.indexedDb |> Html.map (MsgLoggedIn << MsgPageGlobalCaseManagement) |> flexPageWrapper model diff --git a/client/src/elm/Backend/AcuteIllnessEncounter/Decoder.elm b/client/src/elm/Backend/AcuteIllnessEncounter/Decoder.elm index ba548e5798..dbf6ef348d 100644 --- a/client/src/elm/Backend/AcuteIllnessEncounter/Decoder.elm +++ b/client/src/elm/Backend/AcuteIllnessEncounter/Decoder.elm @@ -1,4 +1,4 @@ -module Backend.AcuteIllnessEncounter.Decoder exposing (decodeAcuteIllnessEncounter) +module Backend.AcuteIllnessEncounter.Decoder exposing (decodeAcuteIllnessDiagnosis, decodeAcuteIllnessEncounter) import Backend.AcuteIllnessEncounter.Model exposing (..) import Backend.AcuteIllnessEncounter.Utils exposing (acuteIllnessDiagnosisFromString) diff --git a/client/src/elm/Backend/AcuteIllnessEncounter/Encoder.elm b/client/src/elm/Backend/AcuteIllnessEncounter/Encoder.elm index 7e65ffa1ec..e215891456 100644 --- a/client/src/elm/Backend/AcuteIllnessEncounter/Encoder.elm +++ b/client/src/elm/Backend/AcuteIllnessEncounter/Encoder.elm @@ -1,4 +1,4 @@ -module Backend.AcuteIllnessEncounter.Encoder exposing (encodeAcuteIllnessEncounter) +module Backend.AcuteIllnessEncounter.Encoder exposing (encodeAcuteIllnessDiagnosis, encodeAcuteIllnessEncounter) import Backend.AcuteIllnessEncounter.Model exposing (..) import Backend.AcuteIllnessEncounter.Utils exposing (acuteIllnessDiagnosisToString) diff --git a/client/src/elm/Backend/Dashboard/Decoder.elm b/client/src/elm/Backend/Dashboard/Decoder.elm index b9ea844ed4..d90d70ee6a 100644 --- a/client/src/elm/Backend/Dashboard/Decoder.elm +++ b/client/src/elm/Backend/Dashboard/Decoder.elm @@ -1,27 +1,54 @@ -module Backend.Dashboard.Decoder exposing (decodeDashboardStats) +module Backend.Dashboard.Decoder exposing (decodeDashboardStatsRaw) import AssocList as Dict exposing (Dict) +import Backend.AcuteIllnessEncounter.Decoder exposing (decodeAcuteIllnessDiagnosis) +import Backend.AcuteIllnessEncounter.Model exposing (AcuteIllnessDiagnosis(..)) import Backend.Dashboard.Model exposing (..) import Backend.Entities exposing (VillageId) -import Backend.Measurement.Decoder exposing (decodeFamilyPlanningSign) +import Backend.IndividualEncounterParticipant.Decoder exposing (decodeDeliveryLocation, decodeIndividualEncounterParticipantOutcome) +import Backend.Measurement.Decoder + exposing + ( decodeCall114Sign + , decodeDangerSign + , decodeFamilyPlanningSign + , decodeHCContactSign + , decodeHCRecommendation + , decodeIsolationSign + , decodeRecommendation114 + , decodeSendToHCSign + ) +import Backend.Measurement.Model + exposing + ( Call114Sign(..) + , DangerSign(..) + , HCContactSign(..) + , HCRecommendation(..) + , IsolationSign(..) + , Recommendation114(..) + , SendToHCSign(..) + ) import Backend.Person.Decoder exposing (decodeGender) import Dict as LegacyDict import Gizra.Json exposing (decodeInt) import Gizra.NominalDate exposing (NominalDate, decodeYYYYMMDD) import Json.Decode exposing (..) import Json.Decode.Pipeline exposing (..) +import Pages.AcuteIllnessEncounter.Utils exposing (compareAcuteIllnessEncounterDataDesc) import Restful.Endpoint exposing (decodeEntityUuid, toEntityUuid) +import Utils.Json exposing (decodeEverySet, decodeWithFallback) -decodeDashboardStats : Decoder DashboardStats -decodeDashboardStats = - succeed DashboardStats +decodeDashboardStatsRaw : Decoder DashboardStatsRaw +decodeDashboardStatsRaw = + succeed DashboardStatsRaw |> required "case_management" decodeCaseManagementData - |> required "children_beneficiaries" (list decodePeopleStats) + |> required "children_beneficiaries" decodeChildrenBeneficiariesData |> required "completed_program" (list decodeParticipantStats) |> required "family_planning" (list decodeFamilyPlanningStats) |> required "missed_sessions" (list decodeParticipantStats) |> required "total_encounters" decodeTotalEncountersData + |> required "acute_illness_data" (list decodeAcuteIllnessDataItem) + |> required "prenatal_data" (list decodePrenatalDataItem) |> required "villages_with_residents" decodeVillagesWithResidents |> required "timestamp" string |> required "stats_cache_hash" string @@ -52,7 +79,7 @@ decodeCaseManagementDataForYear = decodeCaseManagement : Decoder CaseManagement decodeCaseManagement = succeed CaseManagement - |> required "id" int + |> required "id" decodeInt |> required "name" string |> required "birth_date" decodeYYYYMMDD |> required "gender" decodeGender @@ -123,11 +150,27 @@ decodeBeneficiaries = |> required "moderate_nutrition" decodeInt -decodePeopleStats : Decoder ChildrenBeneficiariesStats -decodePeopleStats = +decodeChildrenBeneficiariesData : Decoder (Dict ProgramType (List ChildrenBeneficiariesStats)) +decodeChildrenBeneficiariesData = + dict (list decodeChildrenBeneficiariesStats) + |> andThen + (\dict -> + LegacyDict.toList dict + |> List.map + (\( k, v ) -> + ( programTypeFromString k, v ) + ) + |> Dict.fromList + |> succeed + ) + + +decodeChildrenBeneficiariesStats : Decoder ChildrenBeneficiariesStats +decodeChildrenBeneficiariesStats = succeed ChildrenBeneficiariesStats - |> required "field_gender" decodeGender - |> required "field_birth_date" decodeYYYYMMDD + |> required "id" decodeInt + |> required "gender" decodeGender + |> required "birth_date" decodeYYYYMMDD |> required "created" decodeYYYYMMDD |> required "name" string |> required "mother_name" string @@ -223,6 +266,9 @@ programTypeFromString string = "sorwathe" -> ProgramSorwathe + "chw" -> + ProgramChw + _ -> ProgramUnknown @@ -248,3 +294,67 @@ decodeVillagesWithResidents_ = |> Dict.fromList |> succeed ) + + +decodeAcuteIllnessDataItem : Decoder AcuteIllnessDataItem +decodeAcuteIllnessDataItem = + succeed AcuteIllnessDataItem + |> required "id" decodeInt + |> required "created" decodeYYYYMMDD + |> hardcoded NoAcuteIllnessDiagnosis + |> required "date_concluded" (nullable decodeYYYYMMDD) + |> required "outcome" (nullable decodeIndividualEncounterParticipantOutcome) + |> required "encounters" (list decodeAcuteIllnessEncounterDataItem) + |> Json.Decode.map + (\item -> + let + orderedEncounters = + List.sortWith compareAcuteIllnessEncounterDataDesc item.encounters + + resolvedDiagnosis = + List.filter (.diagnosis >> (/=) NoAcuteIllnessDiagnosis) orderedEncounters + |> List.head + |> Maybe.map .diagnosis + |> Maybe.withDefault NoAcuteIllnessDiagnosis + in + { item | diagnosis = resolvedDiagnosis, encounters = orderedEncounters } + ) + + +decodeAcuteIllnessEncounterDataItem : Decoder AcuteIllnessEncounterDataItem +decodeAcuteIllnessEncounterDataItem = + succeed AcuteIllnessEncounterDataItem + |> required "start_date" decodeYYYYMMDD + |> required "sequence_number" decodeInt + |> required "diagnosis" decodeAcuteIllnessDiagnosis + |> required "fever" bool + |> required "isolation" (decodeEverySet (decodeWithFallback NoIsolationSigns decodeIsolationSign)) + |> required "send_to_hc" (decodeEverySet (decodeWithFallback NoSendToHCSigns decodeSendToHCSign)) + |> required "call_114" (decodeEverySet (decodeWithFallback NoCall114Signs decodeCall114Sign)) + |> required "recommendation_114" (decodeEverySet (decodeWithFallback NoneOtherRecommendation114 decodeRecommendation114)) + |> required "contact_hc" (decodeEverySet (decodeWithFallback NoHCContactSigns decodeHCContactSign)) + |> required "recommendation_hc" (decodeEverySet (decodeWithFallback HCRecommendationNotApplicable decodeHCRecommendation)) + + +decodePrenatalDataItem : Decoder PrenatalDataItem +decodePrenatalDataItem = + succeed PrenatalDataItem + |> required "id" decodeInt + |> required "created" decodeYYYYMMDD + |> required "expected_date_concluded" (nullable decodeYYYYMMDD) + |> required "date_concluded" (nullable decodeYYYYMMDD) + |> required "outcome" (nullable decodeIndividualEncounterParticipantOutcome) + |> required "delivery_location" (nullable decodeDeliveryLocation) + |> required "encounters" (list decodePrenatalEncounterDataItem) + + +decodePrenatalEncounterDataItem : Decoder PrenatalEncounterDataItem +decodePrenatalEncounterDataItem = + succeed PrenatalEncounterDataItem + |> required "start_date" decodeYYYYMMDD + |> required "danger_signs" (decodeEverySet (decodeWithFallback NoDangerSign decodeDangerSign)) + + +decodeDangerSignWithFallback : Decoder DangerSign +decodeDangerSignWithFallback = + decodeWithFallback NoDangerSign decodeDangerSign diff --git a/client/src/elm/Backend/Dashboard/Encoder.elm b/client/src/elm/Backend/Dashboard/Encoder.elm index d4cf885861..8ca7a8715e 100644 --- a/client/src/elm/Backend/Dashboard/Encoder.elm +++ b/client/src/elm/Backend/Dashboard/Encoder.elm @@ -1,26 +1,22 @@ -module Backend.Dashboard.Encoder exposing (encodeDashboardStats) +module Backend.Dashboard.Encoder exposing (encodeDashboardStatsRaw) import AssocList as Dict exposing (Dict) -import Backend.Dashboard.Model +import Backend.AcuteIllnessEncounter.Encoder exposing (encodeAcuteIllnessDiagnosis) +import Backend.Dashboard.Model exposing (..) +import Backend.Entities exposing (VillageId) +import Backend.IndividualEncounterParticipant.Encoder exposing (encodeDeliveryLocation, encodeIndividualEncounterParticipantOutcome) +import Backend.Measurement.Encoder exposing - ( CaseManagement - , CaseManagementData - , CaseNutrition - , ChildrenBeneficiariesStats - , DashboardStats - , FamilyPlanningStats - , Nutrition - , NutritionStatus(..) - , NutritionValue - , ParticipantStats - , Periods - , PersonIdentifier - , ProgramType(..) - , TotalBeneficiaries - , TotalEncountersData + ( encodeCall114Sign + , encodeDangerSign + , encodeEverySet + , encodeFamilyPlanningSign + , encodeHCContactSign + , encodeHCRecommendation + , encodeIsolationSign + , encodeRecommendation114 + , encodeSendToHCSign ) -import Backend.Entities exposing (VillageId) -import Backend.Measurement.Encoder exposing (encodeFamilyPlanningSign) import Backend.Person.Encoder exposing (encodeGender) import Dict as LegacyDict import Gizra.NominalDate exposing (NominalDate, encodeYYYYMMDD) @@ -29,14 +25,16 @@ import Json.Encode.Extra exposing (maybe) import Restful.Endpoint exposing (fromEntityUuid) -encodeDashboardStats : DashboardStats -> List ( String, Value ) -encodeDashboardStats stats = +encodeDashboardStatsRaw : DashboardStatsRaw -> List ( String, Value ) +encodeDashboardStatsRaw stats = [ encodeCasesManagementData stats.caseManagement - , encodeChildrenBeneficiaries stats.childrenBeneficiaries + , encodeChildrenBeneficiariesData stats.childrenBeneficiaries , encodeCompletedPrograms stats.completedPrograms , encodeFamilyPlanning stats.familyPlanning , encodeMissedSessions stats.missedSessions , encodeTotalEncountersData stats.totalEncounters + , encodeAcuteIllnessData stats.acuteIllnessData + , encodePrenatalData stats.prenatalData , encodeVillagesWithResidents stats.villagesWithResidents , ( "timestamp", string stats.timestamp ) , ( "stats_cache_hash", string stats.cacheHash ) @@ -113,16 +111,24 @@ encodeNutritionStatus status = "severe_nutrition" -encodeChildrenBeneficiaries : List ChildrenBeneficiariesStats -> ( String, Value ) -encodeChildrenBeneficiaries statsList = - ( "children_beneficiaries", list (encodeChildrenBeneficiariesStats >> object) statsList ) +encodeChildrenBeneficiariesData : Dict ProgramType (List ChildrenBeneficiariesStats) -> ( String, Value ) +encodeChildrenBeneficiariesData dict = + ( "children_beneficiaries" + , Dict.toList dict + |> List.map + (\( programType, casesList ) -> + ( programTypeToString programType, list (encodeChildrenBeneficiariesStats >> object) casesList ) + ) + |> object + ) encodeChildrenBeneficiariesStats : ChildrenBeneficiariesStats -> List ( String, Value ) encodeChildrenBeneficiariesStats stats = - [ ( "name", string stats.name ) - , ( "field_gender", encodeGender stats.gender ) - , ( "field_birth_date", encodeYYYYMMDD stats.birthDate ) + [ ( "id", int stats.identifier ) + , ( "name", string stats.name ) + , ( "gender", encodeGender stats.gender ) + , ( "birth_date", encodeYYYYMMDD stats.birthDate ) , ( "created", encodeYYYYMMDD stats.memberSince ) , ( "mother_name", string stats.motherName ) , ( "phone_number", maybe string stats.phoneNumber ) @@ -211,6 +217,9 @@ programTypeToString programType = ProgramSorwathe -> "sorwathe" + ProgramChw -> + "chw" + ProgramUnknown -> "unknown" @@ -239,3 +248,60 @@ encodeVillagesWithResidents dict = |> object in ( "villages_with_residents", value ) + + +encodeAcuteIllnessData : List AcuteIllnessDataItem -> ( String, Value ) +encodeAcuteIllnessData itemsList = + ( "acute_illness_data", list (encodeAcuteIllnessDataItem >> object) itemsList ) + + +encodeAcuteIllnessDataItem : AcuteIllnessDataItem -> List ( String, Value ) +encodeAcuteIllnessDataItem item = + [ ( "id", int item.identifier ) + , ( "created", encodeYYYYMMDD item.created ) + , ( "diagnosis", encodeAcuteIllnessDiagnosis item.diagnosis ) + , ( "date_concluded", maybe encodeYYYYMMDD item.dateConcluded ) + , ( "outcome", maybe encodeIndividualEncounterParticipantOutcome item.outcome ) + , ( "encounters", list encodeAcuteIllnessEncounterDataItem item.encounters ) + ] + + +encodeAcuteIllnessEncounterDataItem : AcuteIllnessEncounterDataItem -> Value +encodeAcuteIllnessEncounterDataItem item = + object + [ ( "start_date", encodeYYYYMMDD item.startDate ) + , ( "sequence_number", int item.sequenceNumber ) + , ( "diagnosis", encodeAcuteIllnessDiagnosis item.diagnosis ) + , ( "fever", bool item.feverRecorded ) + , ( "isolation", encodeEverySet encodeIsolationSign item.isolationSigns ) + , ( "send_to_hc", encodeEverySet encodeSendToHCSign item.sendToHCSigns ) + , ( "call_114", encodeEverySet encodeCall114Sign item.call114Signs ) + , ( "recommendation_114", encodeEverySet encodeRecommendation114 item.recommendation114 ) + , ( "contact_hc", encodeEverySet encodeHCContactSign item.hcContactSigns ) + , ( "recommendation_hc", encodeEverySet encodeHCRecommendation item.hcRecommendation ) + ] + + +encodePrenatalData : List PrenatalDataItem -> ( String, Value ) +encodePrenatalData itemsList = + ( "prenatal_data", list (encodePrenatalDataItem >> object) itemsList ) + + +encodePrenatalDataItem : PrenatalDataItem -> List ( String, Value ) +encodePrenatalDataItem item = + [ ( "id", int item.identifier ) + , ( "created", encodeYYYYMMDD item.created ) + , ( "expected_date_concluded", maybe encodeYYYYMMDD item.expectedDateConcluded ) + , ( "date_concluded", maybe encodeYYYYMMDD item.dateConcluded ) + , ( "outcome", maybe encodeIndividualEncounterParticipantOutcome item.outcome ) + , ( "delivery_location", maybe encodeDeliveryLocation item.deliveryLocation ) + , ( "encounters", list encodePrenatalEncounterDataItem item.encounters ) + ] + + +encodePrenatalEncounterDataItem : PrenatalEncounterDataItem -> Value +encodePrenatalEncounterDataItem item = + object + [ ( "start_date", encodeYYYYMMDD item.startDate ) + , ( "danger_signs", encodeEverySet encodeDangerSign item.dangerSigns ) + ] diff --git a/client/src/elm/Backend/Dashboard/Model.elm b/client/src/elm/Backend/Dashboard/Model.elm index 6d9348d0a3..941ba9f320 100644 --- a/client/src/elm/Backend/Dashboard/Model.elm +++ b/client/src/elm/Backend/Dashboard/Model.elm @@ -4,12 +4,34 @@ module Backend.Dashboard.Model exposing (..) -} import AssocList as Dict exposing (Dict) +import Backend.AcuteIllnessEncounter.Model exposing (AcuteIllnessDiagnosis) import Backend.Entities exposing (VillageId) -import Backend.Measurement.Model exposing (FamilyPlanningSign) +import Backend.IndividualEncounterParticipant.Model exposing (DeliveryLocation, IndividualEncounterParticipantOutcome) +import Backend.Measurement.Model + exposing + ( Call114Sign + , DangerSign + , FamilyPlanningSign + , FollowUpMeasurements + , HCContactSign + , HCRecommendation + , IsolationSign + , Recommendation114 + , SendToHCSign + ) import Backend.Person.Model exposing (Gender) +import EverySet exposing (EverySet) import Gizra.NominalDate exposing (NominalDate) +type alias AssembledData = + { stats : DashboardStats + , acuteIllnessData : List AcuteIllnessDataItem + , prenatalData : List PrenatalDataItem + , caseManagementData : Maybe FollowUpMeasurements + } + + {-| To void a cycle in dependency, we just define the zScore here. Added a comment in the main definition to point to this one. -} @@ -17,13 +39,15 @@ type alias ZScore = Float -type alias DashboardStats = +type alias DashboardStatsRaw = { caseManagement : CaseManagementData - , childrenBeneficiaries : List ChildrenBeneficiariesStats + , childrenBeneficiaries : ChildrenBeneficiariesData , completedPrograms : List ParticipantStats , familyPlanning : List FamilyPlanningStats , missedSessions : List ParticipantStats , totalEncounters : TotalEncountersData + , acuteIllnessData : List AcuteIllnessDataItem + , prenatalData : List PrenatalDataItem , villagesWithResidents : Dict VillageId (List PersonIdentifier) -- UTC Date and time on which statistics were generated. @@ -34,20 +58,42 @@ type alias DashboardStats = } -emptyModel : DashboardStats +emptyModel : DashboardStatsRaw emptyModel = { caseManagement = CaseManagementData Dict.empty Dict.empty - , childrenBeneficiaries = [] + , childrenBeneficiaries = Dict.empty , completedPrograms = [] , familyPlanning = [] , missedSessions = [] , totalEncounters = TotalEncountersData Dict.empty Dict.empty + , acuteIllnessData = [] + , prenatalData = [] , villagesWithResidents = Dict.empty , timestamp = "" , cacheHash = "" } +type alias DashboardStats = + { caseManagement : CaseManagementPast2Years + , childrenBeneficiaries : List ChildrenBeneficiariesStats + , completedPrograms : List ParticipantStats + , familyPlanning : List FamilyPlanningStats + , missedSessions : List ParticipantStats + , totalEncounters : TotalEncountersData + , villagesWithResidents : Dict VillageId (List PersonIdentifier) + + -- UTC Date and time on which statistics were generated. + , timestamp : String + } + + +type alias CaseManagementPast2Years = + { thisYear : List CaseManagement + , lastYear : List CaseManagement + } + + type alias PersonIdentifier = Int @@ -85,8 +131,13 @@ type alias CaseNutritionTotal = } +type alias ChildrenBeneficiariesData = + Dict ProgramType (List ChildrenBeneficiariesStats) + + type alias ChildrenBeneficiariesStats = - { gender : Gender + { identifier : PersonIdentifier + , gender : Gender , birthDate : NominalDate , memberSince : NominalDate , name : String @@ -172,6 +223,7 @@ type ProgramType | ProgramIndividual | ProgramPmtct | ProgramSorwathe + | ProgramChw | ProgramUnknown @@ -179,3 +231,44 @@ type alias TotalEncountersData = { global : Dict ProgramType Periods , villages : Dict VillageId (Dict ProgramType Periods) } + + +type alias PrenatalDataItem = + { identifier : PersonIdentifier + , created : NominalDate + , expectedDateConcluded : Maybe NominalDate + , dateConcluded : Maybe NominalDate + , outcome : Maybe IndividualEncounterParticipantOutcome + , deliveryLocation : Maybe DeliveryLocation + , encounters : List PrenatalEncounterDataItem + } + + +type alias PrenatalEncounterDataItem = + { startDate : NominalDate + , dangerSigns : EverySet DangerSign + } + + +type alias AcuteIllnessDataItem = + { identifier : PersonIdentifier + , created : NominalDate + , diagnosis : AcuteIllnessDiagnosis + , dateConcluded : Maybe NominalDate + , outcome : Maybe IndividualEncounterParticipantOutcome + , encounters : List AcuteIllnessEncounterDataItem + } + + +type alias AcuteIllnessEncounterDataItem = + { startDate : NominalDate + , sequenceNumber : Int + , diagnosis : AcuteIllnessDiagnosis + , feverRecorded : Bool + , isolationSigns : EverySet IsolationSign + , sendToHCSigns : EverySet SendToHCSign + , call114Signs : EverySet Call114Sign + , recommendation114 : EverySet Recommendation114 + , hcContactSigns : EverySet HCContactSign + , hcRecommendation : EverySet HCRecommendation + } diff --git a/client/src/elm/Backend/Decoder.elm b/client/src/elm/Backend/Decoder.elm index fd0a4eb9a9..97f0ef864e 100644 --- a/client/src/elm/Backend/Decoder.elm +++ b/client/src/elm/Backend/Decoder.elm @@ -3,7 +3,7 @@ module Backend.Decoder exposing (decodeRevision) import Backend.AcuteIllnessEncounter.Decoder exposing (decodeAcuteIllnessEncounter) import Backend.Clinic.Decoder exposing (decodeClinic) import Backend.Counseling.Decoder exposing (decodeCounselingSchedule, decodeCounselingTopic) -import Backend.Dashboard.Decoder exposing (decodeDashboardStats) +import Backend.Dashboard.Decoder exposing (decodeDashboardStatsRaw) import Backend.HealthCenter.Decoder exposing (decodeCatchmentArea, decodeHealthCenter) import Backend.HomeVisitEncounter.Decoder exposing (decodeHomeVisitEncounter) import Backend.IndividualEncounterParticipant.Decoder exposing (decodeIndividualEncounterParticipant) @@ -265,7 +265,7 @@ decodeRevision = decodeWithUuid SocialHistoryRevision decodeSocialHistory "statistics" -> - decodeWithUuid DashboardStatsRevision decodeDashboardStats + decodeWithUuid DashboardStatsRevision decodeDashboardStatsRaw "symptoms_general" -> decodeWithUuid SymptomsGeneralRevision decodeSymptomsGeneral diff --git a/client/src/elm/Backend/Endpoints.elm b/client/src/elm/Backend/Endpoints.elm index bdcdf0a065..46aea07b54 100644 --- a/client/src/elm/Backend/Endpoints.elm +++ b/client/src/elm/Backend/Endpoints.elm @@ -9,8 +9,8 @@ import Backend.Clinic.Model exposing (Clinic) import Backend.Counseling.Decoder exposing (decodeCounselingSchedule, decodeCounselingTopic) import Backend.Counseling.Encoder exposing (encodeCounselingSchedule, encodeCounselingTopic) import Backend.Counseling.Model exposing (CounselingSchedule, CounselingTopic) -import Backend.Dashboard.Decoder exposing (decodeDashboardStats) -import Backend.Dashboard.Model exposing (DashboardStats) +import Backend.Dashboard.Decoder exposing (decodeDashboardStatsRaw) +import Backend.Dashboard.Model exposing (DashboardStatsRaw) import Backend.Entities exposing (..) import Backend.HealthCenter.Decoder exposing (decodeHealthCenter) import Backend.HealthCenter.Model exposing (HealthCenter) @@ -81,7 +81,7 @@ type alias PersonParams = encodePersonParams : PersonParams -> List ( String, String ) encodePersonParams params = - List.filterMap identity + Maybe.Extra.values [ Maybe.map (\name -> ( "name_contains", name )) params.nameContains ] @@ -101,15 +101,15 @@ type alias RelationshipParams = encodeRelationshipParams : RelationshipParams -> List ( String, String ) encodeRelationshipParams params = - List.filterMap identity + Maybe.Extra.values [ Maybe.map (\person -> ( "person", fromEntityUuid person )) params.person , Maybe.map (\relatedTo -> ( "related_to", fromEntityUuid relatedTo )) params.relatedTo ] -computedDashboardEndpoint : ReadOnlyEndPoint Error HealthCenterId DashboardStats () +computedDashboardEndpoint : ReadOnlyEndPoint Error HealthCenterId DashboardStatsRaw () computedDashboardEndpoint = - swEndpoint "statistics" decodeDashboardStats + swEndpoint "statistics" decodeDashboardStatsRaw healthCenterEndpoint : ReadOnlyEndPoint Error HealthCenterId HealthCenter () diff --git a/client/src/elm/Backend/HomeVisitEncounter/Fetch.elm b/client/src/elm/Backend/HomeVisitEncounter/Fetch.elm index 7ec4483d22..adb3ebe337 100644 --- a/client/src/elm/Backend/HomeVisitEncounter/Fetch.elm +++ b/client/src/elm/Backend/HomeVisitEncounter/Fetch.elm @@ -5,6 +5,7 @@ import Backend.Entities exposing (..) import Backend.HomeVisitEncounter.Utils exposing (resolveHomeVisitParticipantForChild) import Backend.IndividualEncounterType.Model exposing (IndividualEncounterType(..)) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -30,7 +31,7 @@ fetchForChild id db = encountersIds |> List.map FetchHomeVisitMeasurements in - List.filterMap identity + Maybe.Extra.values [ Maybe.map FetchIndividualEncounterParticipant participantId , Maybe.map FetchHomeVisitEncountersForParticipant participantId , Just <| FetchPerson id diff --git a/client/src/elm/Backend/IndividualEncounterParticipant/Decoder.elm b/client/src/elm/Backend/IndividualEncounterParticipant/Decoder.elm index 8abab14b2a..afa6b92014 100644 --- a/client/src/elm/Backend/IndividualEncounterParticipant/Decoder.elm +++ b/client/src/elm/Backend/IndividualEncounterParticipant/Decoder.elm @@ -1,4 +1,4 @@ -module Backend.IndividualEncounterParticipant.Decoder exposing (acuteIllnessOutcomeFromString, decodeIndividualEncounterParticipant, pregnancyOutcomeFromString) +module Backend.IndividualEncounterParticipant.Decoder exposing (..) import Backend.IndividualEncounterParticipant.Model exposing (..) import Backend.IndividualEncounterParticipant.Utils exposing (decodeIndividualEncounterTypeFromString) diff --git a/client/src/elm/Backend/IndividualEncounterParticipant/Encoder.elm b/client/src/elm/Backend/IndividualEncounterParticipant/Encoder.elm index ad1275e1a1..710ae638eb 100644 --- a/client/src/elm/Backend/IndividualEncounterParticipant/Encoder.elm +++ b/client/src/elm/Backend/IndividualEncounterParticipant/Encoder.elm @@ -1,11 +1,4 @@ -module Backend.IndividualEncounterParticipant.Encoder exposing - ( acuteIllnessOutcomeToString - , encodeAcuteIllnessOutcome - , encodeDeliveryLocation - , encodeIndividualEncounterParticipant - , encodePregnancyOutcome - , pregnancyOutcomeToString - ) +module Backend.IndividualEncounterParticipant.Encoder exposing (..) import Backend.IndividualEncounterParticipant.Model exposing (..) import Backend.IndividualEncounterParticipant.Utils exposing (encodeIndividualEncounterTypeAsString) diff --git a/client/src/elm/Backend/Measurement/Decoder.elm b/client/src/elm/Backend/Measurement/Decoder.elm index e0c4ddde11..a49f814188 100644 --- a/client/src/elm/Backend/Measurement/Decoder.elm +++ b/client/src/elm/Backend/Measurement/Decoder.elm @@ -12,7 +12,7 @@ import Json.Decode exposing (..) import Json.Decode.Pipeline exposing (custom, hardcoded, optional, optionalAt, required, requiredAt) import Restful.Endpoint exposing (EntityUuid, decodeEntityUuid, toEntityUuid) import Translate.Utils exposing (decodeLanguage) -import Utils.Json exposing (decodeEverySet) +import Utils.Json exposing (decodeEverySet, decodeWithFallback) decodeGroupMeasurement : Decoder value -> Decoder (Measurement SessionId value) @@ -2357,8 +2357,8 @@ decodeCall114 : Decoder Call114 decodeCall114 = succeed Call114Value |> required "114_contact" (decodeEverySet decodeCall114Sign) - |> required "114_recommendation" (decodeEverySet decodeRecommendation114) - |> required "site_recommendation" (decodeEverySet decodeRecommendationSite) + |> required "114_recommendation" (decodeEverySet (decodeWithFallback NoneOtherRecommendation114 decodeRecommendation114)) + |> required "site_recommendation" (decodeEverySet (decodeWithFallback RecommendationSiteNotApplicable decodeRecommendationSite)) |> decodeAcuteIllnessMeasurement diff --git a/client/src/elm/Backend/Measurement/Encoder.elm b/client/src/elm/Backend/Measurement/Encoder.elm index 5298f4d909..df9735adc1 100644 --- a/client/src/elm/Backend/Measurement/Encoder.elm +++ b/client/src/elm/Backend/Measurement/Encoder.elm @@ -1479,15 +1479,15 @@ encodeGroupSendToHC = encodeSendToHCValueWithType : String -> SendToHCValue -> List ( String, Value ) encodeSendToHCValueWithType type_ value = - [ ( "send_to_hc", encodeEverySet encondeSendToHCSign value.signs ) + [ ( "send_to_hc", encodeEverySet encodeSendToHCSign value.signs ) , ( "reason_not_sent_to_hc", encodeReasonForNotSendingToHC value.reasonForNotSendingToHC ) , ( "deleted", bool False ) , ( "type", string type_ ) ] -encondeSendToHCSign : SendToHCSign -> Value -encondeSendToHCSign sign = +encodeSendToHCSign : SendToHCSign -> Value +encodeSendToHCSign sign = string <| case sign of HandReferrerForm -> diff --git a/client/src/elm/Backend/Model.elm b/client/src/elm/Backend/Model.elm index 908100ab38..aa1df1c305 100644 --- a/client/src/elm/Backend/Model.elm +++ b/client/src/elm/Backend/Model.elm @@ -21,7 +21,7 @@ import AssocList as Dict exposing (Dict) import Backend.AcuteIllnessEncounter.Model exposing (AcuteIllnessEncounter) import Backend.Clinic.Model exposing (Clinic, ClinicType) import Backend.Counseling.Model exposing (CounselingSchedule, CounselingTopic, EveryCounselingSchedule) -import Backend.Dashboard.Model exposing (DashboardStats) +import Backend.Dashboard.Model exposing (DashboardStatsRaw) import Backend.Entities exposing (..) import Backend.HealthCenter.Model exposing (CatchmentArea, HealthCenter) import Backend.HomeVisitEncounter.Model exposing (HomeVisitEncounter) @@ -134,7 +134,7 @@ type alias ModelIndexedDb = , postHomeVisitEncounter : Dict IndividualEncounterParticipantId (WebData ( HomeVisitEncounterId, HomeVisitEncounter )) -- Dashboard Statistics. - , computedDashboard : Dict HealthCenterId DashboardStats + , computedDashboard : Dict HealthCenterId DashboardStatsRaw , computedDashboardLastFetched : Time.Posix } @@ -241,7 +241,7 @@ type MsgIndexedDb | HandleFetchedAcuteIllnessEncountersForParticipant IndividualEncounterParticipantId (WebData (Dict AcuteIllnessEncounterId AcuteIllnessEncounter)) | HandleFetchedAcuteIllnessMeasurements AcuteIllnessEncounterId (WebData AcuteIllnessMeasurements) | HandleFetchedChildMeasurements PersonId (WebData ChildMeasurementList) - | HandleFetchedComputedDashboard HealthCenterId (WebData (Dict HealthCenterId DashboardStats)) + | HandleFetchedComputedDashboard HealthCenterId (WebData (Dict HealthCenterId DashboardStatsRaw)) | HandleFetchedChildrenMeasurements (WebData (Dict PersonId ChildMeasurementList)) | HandleFetchedClinics (WebData (Dict ClinicId Clinic)) | HandleFetchedEveryCounselingSchedule (WebData EveryCounselingSchedule) @@ -333,7 +333,7 @@ type Revision | CounselingSessionRevision CounselingSessionId CounselingSession | CounselingTopicRevision CounselingTopicId CounselingTopic | DangerSignsRevision DangerSignsId DangerSigns - | DashboardStatsRevision HealthCenterId DashboardStats + | DashboardStatsRevision HealthCenterId DashboardStatsRaw | ExposureRevision ExposureId Exposure | FamilyPlanningRevision FamilyPlanningId FamilyPlanning | FollowUpRevision FollowUpId FollowUp diff --git a/client/src/elm/Backend/NutritionEncounter/Fetch.elm b/client/src/elm/Backend/NutritionEncounter/Fetch.elm index 7dc05f0b81..bf6b190e19 100644 --- a/client/src/elm/Backend/NutritionEncounter/Fetch.elm +++ b/client/src/elm/Backend/NutritionEncounter/Fetch.elm @@ -5,6 +5,7 @@ import Backend.Entities exposing (..) import Backend.IndividualEncounterParticipant.Model exposing (IndividualEncounterType(..)) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) import Backend.Utils exposing (resolveIndividualParticipantForPerson) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -30,7 +31,7 @@ fetchForChild id db = encountersIds |> List.map FetchNutritionMeasurements in - List.filterMap identity + Maybe.Extra.values [ Maybe.map FetchIndividualEncounterParticipant participantId , Maybe.map FetchNutritionEncountersForParticipant participantId , Just <| FetchPerson id diff --git a/client/src/elm/Backend/NutritionEncounter/Utils.elm b/client/src/elm/Backend/NutritionEncounter/Utils.elm index c4737effcf..90904aa4de 100644 --- a/client/src/elm/Backend/NutritionEncounter/Utils.elm +++ b/client/src/elm/Backend/NutritionEncounter/Utils.elm @@ -193,7 +193,7 @@ generateNutritionAssesment currentDate zscores childId muacValue weightValue nut List.Extra.getAt (index + 1) fourLatest |> Maybe.map (\previousWeight -> previousWeight - weight) ) - |> List.filterMap identity + |> Maybe.Extra.values |> (\diffs -> -- Each diff needs to be 0.5 or more if List.all (\diff -> diff >= 0.5) diffs then @@ -252,7 +252,7 @@ generateNutritionAssesment currentDate zscores childId muacValue weightValue nut |> Maybe.withDefault [] in [ assesmentByMuac, assesmentByWeightForAgeZScore, assesmentByConsecutiveWeight, assementByNutritionSigns ] - |> List.filterMap identity + |> Maybe.Extra.values resolveAllWeightMeasurementsForChild : PersonId -> ModelIndexedDb -> List ( NominalDate, Float ) diff --git a/client/src/elm/Pages/AcuteIllnessActivity/Update.elm b/client/src/elm/Pages/AcuteIllnessActivity/Update.elm index 2c203d8580..ac0c05dd79 100644 --- a/client/src/elm/Pages/AcuteIllnessActivity/Update.elm +++ b/client/src/elm/Pages/AcuteIllnessActivity/Update.elm @@ -877,7 +877,7 @@ update currentDate id db msg model = model.nextStepsData.isolationForm updatedForm = - { form | patientIsolated = Just value } + { form | patientIsolated = Just value, signOnDoor = Nothing } updatedData = model.nextStepsData diff --git a/client/src/elm/Pages/AcuteIllnessActivity/View.elm b/client/src/elm/Pages/AcuteIllnessActivity/View.elm index 0844ebf265..799b1e8918 100644 --- a/client/src/elm/Pages/AcuteIllnessActivity/View.elm +++ b/client/src/elm/Pages/AcuteIllnessActivity/View.elm @@ -342,7 +342,7 @@ pertinentSymptomsPopup language isOpen closeMsg measurements = |> Maybe.withDefault [] content = - List.filterMap identity + Maybe.Extra.values [ viewBodyTemperature , viewRespiratoryRate , viewTravelHistory diff --git a/client/src/elm/Pages/AcuteIllnessEncounter/Fetch.elm b/client/src/elm/Pages/AcuteIllnessEncounter/Fetch.elm index 3c0fa6bfff..e470a8068d 100644 --- a/client/src/elm/Pages/AcuteIllnessEncounter/Fetch.elm +++ b/client/src/elm/Pages/AcuteIllnessEncounter/Fetch.elm @@ -3,6 +3,7 @@ module Pages.AcuteIllnessEncounter.Fetch exposing (fetch) import AssocList as Dict import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -39,7 +40,7 @@ fetch id db = encountersIds |> List.map FetchAcuteIllnessMeasurements in - List.filterMap identity + Maybe.Extra.values [ Maybe.map FetchIndividualEncounterParticipant participantId , Maybe.map FetchPerson personId , Maybe.map FetchAcuteIllnessEncountersForParticipant participantId diff --git a/client/src/elm/Pages/AcuteIllnessOutcome/Fetch.elm b/client/src/elm/Pages/AcuteIllnessOutcome/Fetch.elm index d68837f9ef..bbf97b7b21 100644 --- a/client/src/elm/Pages/AcuteIllnessOutcome/Fetch.elm +++ b/client/src/elm/Pages/AcuteIllnessOutcome/Fetch.elm @@ -3,6 +3,7 @@ module Pages.AcuteIllnessOutcome.Fetch exposing (fetch) import AssocList as Dict import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -30,7 +31,7 @@ fetch participantId db = encountersIds |> List.map FetchAcuteIllnessMeasurements in - List.filterMap identity + Maybe.Extra.values [ Maybe.map FetchIndividualEncounterParticipant (Just participantId) , Maybe.map FetchPerson personId , Maybe.map FetchAcuteIllnessEncountersForParticipant (Just participantId) diff --git a/client/src/elm/Pages/AcuteIllnessParticipant/Model.elm b/client/src/elm/Pages/AcuteIllnessParticipant/Model.elm index 2176c9b408..851e037460 100644 --- a/client/src/elm/Pages/AcuteIllnessParticipant/Model.elm +++ b/client/src/elm/Pages/AcuteIllnessParticipant/Model.elm @@ -17,7 +17,6 @@ emptyModel = type Msg = MsgBackend Backend.Model.MsgIndexedDb - | RecordIllnessOutcome IndividualEncounterParticipantId | SetViewMode AcuteIllnessParticipantViewMode | SetActivePage Page diff --git a/client/src/elm/Pages/AcuteIllnessParticipant/Update.elm b/client/src/elm/Pages/AcuteIllnessParticipant/Update.elm index 18d295a624..e0c1a81ae5 100644 --- a/client/src/elm/Pages/AcuteIllnessParticipant/Update.elm +++ b/client/src/elm/Pages/AcuteIllnessParticipant/Update.elm @@ -15,12 +15,6 @@ update currentDate personId msg model = , [ App.Model.MsgIndexedDb msgBackend ] ) - RecordIllnessOutcome sessionId -> - ( model - , Cmd.none - , [] - ) - SetViewMode mode -> ( { model | viewMode = mode } , Cmd.none diff --git a/client/src/elm/Pages/AcuteIllnessParticipant/Utils.elm b/client/src/elm/Pages/AcuteIllnessParticipant/Utils.elm index 3e649e4ee9..1aa2406690 100644 --- a/client/src/elm/Pages/AcuteIllnessParticipant/Utils.elm +++ b/client/src/elm/Pages/AcuteIllnessParticipant/Utils.elm @@ -6,10 +6,9 @@ import Gizra.NominalDate exposing (NominalDate) import Maybe.Extra exposing (isNothing) -{-| Preganancy is considered 'active' if it does not have it's end -date set, and it's EDD date is not set, or, EDD date is less than -3 month overdue. +{-| Illness is considered 'active' if it does not have it's end +date or outcome set. -} isAcuteIllnessActive : NominalDate -> IndividualEncounterParticipant -> Bool isAcuteIllnessActive currentDate session = - isNothing session.endDate + isNothing session.endDate || isNothing session.outcome diff --git a/client/src/elm/Pages/AcuteIllnessParticipant/View.elm b/client/src/elm/Pages/AcuteIllnessParticipant/View.elm index e33303131c..b90dd897d4 100644 --- a/client/src/elm/Pages/AcuteIllnessParticipant/View.elm +++ b/client/src/elm/Pages/AcuteIllnessParticipant/View.elm @@ -334,28 +334,30 @@ viewActiveIllness language currentDate selectedHealthCenter db viewMode sessionI >> Maybe.map .diagnosis ) in - case mDiagnosis of - Nothing -> - Nothing + Maybe.andThen + (\diagnosis -> + if diagnosis == DiagnosisFeverOfUnknownOrigin then + -- Do not show illness if diagnosis is + -- fever of unknown origin. + Nothing - Just NoAcuteIllnessDiagnosis -> - Nothing - - Just diagnosis -> - sessionEncounters - |> Maybe.andThen - (\encounters -> - case viewMode of - -- No need to view illnesses for this view mode. - ManageIllnesses -> - Nothing - - ManageParticipants -> - viewActiveIllnessForManagement language currentDate selectedHealthCenter sessionId encounters diagnosis - - RecordOutcome -> - viewActiveIllnessForOutcome language currentDate sessionId encounters diagnosis - ) + else + sessionEncounters + |> Maybe.andThen + (\encounters -> + case viewMode of + -- No need to view illnesses for this view mode. + ManageIllnesses -> + Nothing + + ManageParticipants -> + viewActiveIllnessForManagement language currentDate selectedHealthCenter sessionId encounters diagnosis + + RecordOutcome -> + viewActiveIllnessForOutcome language currentDate sessionId encounters diagnosis + ) + ) + mDiagnosis viewActiveIllnessForManagement : diff --git a/client/src/elm/Pages/Clinical/Fetch.elm b/client/src/elm/Pages/Clinical/Fetch.elm index b44700101e..6a5eb651d0 100644 --- a/client/src/elm/Pages/Clinical/Fetch.elm +++ b/client/src/elm/Pages/Clinical/Fetch.elm @@ -4,6 +4,7 @@ import AssocList as Dict exposing (Dict) import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) import Backend.Village.Utils exposing (getVillageClinicId) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -12,7 +13,7 @@ fetch maybeVillageId db = maybeVillageId |> Maybe.map (\villageId -> - List.filterMap identity + Maybe.Extra.values [ Just FetchClinics , Maybe.map FetchSessionsByClinic (getVillageClinicId villageId db) ] diff --git a/client/src/elm/Pages/Clinics/Fetch.elm b/client/src/elm/Pages/Clinics/Fetch.elm index 10bc99a6ac..d3557f7d60 100644 --- a/client/src/elm/Pages/Clinics/Fetch.elm +++ b/client/src/elm/Pages/Clinics/Fetch.elm @@ -2,6 +2,7 @@ module Pages.Clinics.Fetch exposing (fetch) import Backend.Entities exposing (..) import Backend.Model +import Maybe.Extra {-| The `fetch` function is an innovation in how to manage the "lazy" loading @@ -58,7 +59,7 @@ fetch clinicId = -- centrally, by looking at the messages we return. That allows us to -- **remember** what data is desired ... and, thus, no longer desired ... -- so we can know when to **forget** things as well. - List.filterMap identity + Maybe.Extra.values [ Just Backend.Model.FetchClinics , Maybe.map Backend.Model.FetchSessionsByClinic clinicId ] diff --git a/client/src/elm/Pages/Dashboard/Fetch.elm b/client/src/elm/Pages/Dashboard/Fetch.elm index 890c865431..3440bfe4e6 100644 --- a/client/src/elm/Pages/Dashboard/Fetch.elm +++ b/client/src/elm/Pages/Dashboard/Fetch.elm @@ -2,9 +2,20 @@ module Pages.Dashboard.Fetch exposing (fetch) import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) +import Gizra.NominalDate exposing (NominalDate) +import Maybe.Extra exposing (isJust) import Pages.Dashboard.Model exposing (..) +import Pages.GlobalCaseManagement.Fetch -fetch : HealthCenterId -> Model -> List MsgIndexedDb -fetch healthCenterId model = +fetch : NominalDate -> HealthCenterId -> ModelIndexedDb -> Model -> List MsgIndexedDb +fetch currentDate healthCenterId db model = [ FetchVillages, FetchComputedDashboard healthCenterId ] + ++ (case model.selectedVillageFilter of + -- For CHW, we fetch case management data. + Just villageId -> + Pages.GlobalCaseManagement.Fetch.fetch currentDate healthCenterId villageId db + + Nothing -> + [] + ) diff --git a/client/src/elm/Pages/Dashboard/GraphUtils.elm b/client/src/elm/Pages/Dashboard/GraphUtils.elm index 049bebac3b..f3acf0b5bb 100644 --- a/client/src/elm/Pages/Dashboard/GraphUtils.elm +++ b/client/src/elm/Pages/Dashboard/GraphUtils.elm @@ -1,10 +1,31 @@ -module Pages.Dashboard.GraphUtils exposing (barChartHeight, barChartWidth, colors, column, familyPlanningSignToColor, gridXScale, gridYScale, padding, pieChartHeight, pieChartWidth, radius, xAxis, xGridLine, xScale, yAxis, yGridLine, yScale) +module Pages.Dashboard.GraphUtils exposing + ( barChartHeight + , barChartWidth + , column + , familyPlanningSignToColor + , familyPlanningSignsColors + , feverCauseToColor + , feverCausesColors + , gridXScale + , gridYScale + , padding + , pieChartHeight + , pieChartWidth + , radius + , xAxis + , xGridLine + , xScale + , yAxis + , yGridLine + , yScale + ) import AssocList as Dict exposing (Dict) import Axis import Backend.Dashboard.Model exposing (DashboardStats, Nutrition, Periods) import Backend.Measurement.Model exposing (FamilyPlanningSign(..)) import Color exposing (Color) +import Pages.Dashboard.Model exposing (FeverCause(..), allFeverCauses) import Scale exposing (BandConfig, BandScale, ContinuousScale, defaultBandConfig) import Time exposing (Month(..)) import TypedSvg exposing (g, line, rect) @@ -168,24 +189,51 @@ familyPlanningSignToColor sign = Color.rgb (3 / 255) (121 / 255) (113 / 255) -colors : Dict FamilyPlanningSign Color -colors = - Dict.fromList - [ ( AutoObservation, familyPlanningSignToColor AutoObservation ) - , ( Condoms, familyPlanningSignToColor Condoms ) - , ( CycleBeads, familyPlanningSignToColor CycleBeads ) - , ( CycleCounting, familyPlanningSignToColor CycleCounting ) - , ( Hysterectomy, familyPlanningSignToColor Hysterectomy ) - , ( Implants, familyPlanningSignToColor Implants ) - , ( Injectables, familyPlanningSignToColor Injectables ) - , ( NoFamilyPlanning, familyPlanningSignToColor NoFamilyPlanning ) - , ( IUD, familyPlanningSignToColor IUD ) - , ( LactationAmenorrhea, familyPlanningSignToColor LactationAmenorrhea ) - , ( OralContraceptives, familyPlanningSignToColor OralContraceptives ) - , ( Spermicide, familyPlanningSignToColor Spermicide ) - , ( TubalLigatures, familyPlanningSignToColor TubalLigatures ) - , ( Vasectomy, familyPlanningSignToColor Vasectomy ) - ] +familyPlanningSignsColors : Dict FamilyPlanningSign Color +familyPlanningSignsColors = + [ AutoObservation + , Condoms + , CycleBeads + , CycleCounting + , Hysterectomy + , Implants + , Injectables + , NoFamilyPlanning + , IUD + , LactationAmenorrhea + , OralContraceptives + , Spermicide + , TubalLigatures + , Vasectomy + ] + |> List.map (\sign -> ( sign, familyPlanningSignToColor sign )) + |> Dict.fromList + + +feverCauseToColor : FeverCause -> Color +feverCauseToColor cause = + case cause of + FeverCauseCovid19 -> + Color.rgb (27 / 255) (207 / 255) (193 / 255) + + FeverCauseMalaria -> + Color.rgb (253 / 255) (240 / 255) (124 / 255) + + FeverCauseRespiratory -> + Color.rgb (240 / 255) (111 / 255) (107 / 255) + + FeverCauseGI -> + Color.rgb (238 / 255) (87 / 255) (142 / 255) + + FeverCauseUnknown -> + Color.rgb (157 / 255) (121 / 255) (188 / 255) + + +feverCausesColors : Dict FeverCause Color +feverCausesColors = + allFeverCauses + |> List.map (\cause -> ( cause, feverCauseToColor cause )) + |> Dict.fromList radius : Float diff --git a/client/src/elm/Pages/Dashboard/Model.elm b/client/src/elm/Pages/Dashboard/Model.elm index dd8019602d..8a5ecb32b3 100644 --- a/client/src/elm/Pages/Dashboard/Model.elm +++ b/client/src/elm/Pages/Dashboard/Model.elm @@ -3,13 +3,14 @@ module Pages.Dashboard.Model exposing (..) import AssocList exposing (Dict) import Backend.Dashboard.Model exposing (ParticipantStats) import Backend.Entities exposing (HealthCenterId, VillageId) +import Backend.IndividualEncounterParticipant.Model exposing (IndividualEncounterType) import Backend.Measurement.Model exposing (FamilyPlanningSign) import Backend.Nurse.Model exposing (Nurse) import Backend.Nurse.Utils exposing (isCommunityHealthWorker) import Backend.Person.Model exposing (Gender) import Gizra.NominalDate exposing (NominalDate) import Maybe.Extra exposing (isJust) -import Pages.Page exposing (DashboardPage(..), Page(..)) +import Pages.Page exposing (AcuteIllnessDashboardPage(..), ChwDashboardPage(..), DashboardPage(..), NurseDashboardPage(..), Page(..)) type FilterPeriod @@ -35,16 +36,6 @@ type BeneficiariesTableLabels | Total -filterPeriodsForMainPage : List FilterPeriod -filterPeriodsForMainPage = - [] - - -filterPeriodsForCaseManagementPage : List FilterPeriod -filterPeriodsForCaseManagementPage = - [] - - filterPeriodsForStatsPage : List FilterPeriod filterPeriodsForStatsPage = [ ThisMonth @@ -125,6 +116,11 @@ type alias Model = , currentCaseManagementSubFilter : DashboardSubFilter , latestPage : DashboardPage , modalState : Maybe ModalState + + -- This is used by month selector to determine + -- the gap from current month. We allow to go back + -- 6 months, so, valid values are between 0 and 5. + , monthGap : MonthGap } @@ -153,9 +149,19 @@ emptyModel maybeSelectedVillage = , currentCaseManagementSubFilter = FilterTotal , latestPage = MainPage , modalState = Nothing + , monthGap = 0 } +type alias MonthGap = + Int + + +maxMonthGap : MonthGap +maxMonthGap = + 5 + + type ModalState = StatisticsModal String (List ParticipantStats) | FiltersModal @@ -219,8 +225,28 @@ type MonthlyChartType | MonthlyChartIncidence +type FeverCause + = FeverCauseCovid19 + | FeverCauseMalaria + | FeverCauseRespiratory + | FeverCauseGI + | FeverCauseUnknown + + +allFeverCauses : List FeverCause +allFeverCauses = + [ FeverCauseCovid19 + , FeverCauseMalaria + , FeverCauseRespiratory + , FeverCauseGI + , FeverCauseUnknown + ] + + type Msg = SetModalState (Maybe ModalState) + | Reset (Maybe VillageId) + | ChangeMonthGap Int | NavigateToStuntingTable DashboardSubFilter | SetFilterGender FilterGender | SetFilterPeriod FilterPeriod diff --git a/client/src/elm/Pages/Dashboard/Update.elm b/client/src/elm/Pages/Dashboard/Update.elm index ead3321d45..9aaad1a62c 100644 --- a/client/src/elm/Pages/Dashboard/Update.elm +++ b/client/src/elm/Pages/Dashboard/Update.elm @@ -3,7 +3,7 @@ module Pages.Dashboard.Update exposing (update) import App.Model import Pages.Dashboard.Model exposing (..) import Pages.Dashboard.Utils exposing (filterProgramTypeFromString) -import Pages.Page exposing (DashboardPage(..), Page(..), UserPage(..)) +import Pages.Page exposing (ChwDashboardPage(..), DashboardPage(..), NurseDashboardPage(..), Page(..), UserPage(..)) import Restful.Endpoint exposing (toEntityUuid) @@ -16,9 +16,32 @@ update msg subPage model = , [] ) + Reset villageId -> + ( emptyModel villageId + , Cmd.none + , [] + ) + + ChangeMonthGap interval -> + let + potential = + model.monthGap + interval + + updated = + if potential < 0 || potential > maxMonthGap then + model.monthGap + + else + potential + in + ( { model | monthGap = updated } + , Cmd.none + , [] + ) + NavigateToStuntingTable filter -> { model | currentCaseManagementSubFilter = filter } - |> update (SetActivePage (UserPage (DashboardPage CaseManagementPage))) subPage + |> update (SetActivePage (UserPage (DashboardPage (NursePage CaseManagementPage)))) subPage SetFilterGender gender -> ( { model | beneficiariesGender = gender } @@ -94,10 +117,10 @@ update msg subPage model = UserPage (DashboardPage MainPage) -> OneYear - UserPage (DashboardPage StatsPage) -> + UserPage (DashboardPage (NursePage StatsPage)) -> ThisMonth - UserPage (DashboardPage CaseManagementPage) -> + UserPage (DashboardPage (NursePage CaseManagementPage)) -> ThreeMonthsAgo _ -> diff --git a/client/src/elm/Pages/Dashboard/Utils.elm b/client/src/elm/Pages/Dashboard/Utils.elm index 4fec99cdff..9f77e3fc63 100644 --- a/client/src/elm/Pages/Dashboard/Utils.elm +++ b/client/src/elm/Pages/Dashboard/Utils.elm @@ -1,6 +1,47 @@ module Pages.Dashboard.Utils exposing (..) +import AssocList as Dict exposing (Dict) +import Backend.AcuteIllnessEncounter.Model exposing (AcuteIllnessDiagnosis(..)) +import Backend.Dashboard.Model + exposing + ( AcuteIllnessDataItem + , AcuteIllnessEncounterDataItem + , AssembledData + , CaseManagement + , ChildrenBeneficiariesStats + , DashboardStats + , DashboardStatsRaw + , NutritionStatus(..) + , NutritionValue + , Periods + , PersonIdentifier + , PrenatalDataItem + , ProgramType(..) + , TotalEncountersData + ) +import Backend.Entities exposing (..) +import Backend.IndividualEncounterParticipant.Model exposing (DeliveryLocation, IndividualEncounterParticipantOutcome(..), PregnancyOutcome(..)) +import Backend.Measurement.Model + exposing + ( Call114Sign(..) + , DangerSign(..) + , FollowUpMeasurements + , HCContactSign(..) + , HCRecommendation(..) + , IsolationSign(..) + , Recommendation114(..) + , SendToHCSign(..) + ) +import Backend.Model exposing (ModelIndexedDb) +import Date +import EverySet exposing (EverySet) +import Gizra.NominalDate exposing (NominalDate) +import Maybe.Extra exposing (isJust, isNothing) import Pages.Dashboard.Model exposing (..) +import Pages.GlobalCaseManagement.Utils exposing (filterVillageResidents, generateAcuteIllnessFollowUps, generateNutritionFollowUps, generatePrenatalFollowUps) +import Pages.GlobalCaseManagement.View exposing (generateAcuteIllnessFollowUpEntries, generateNutritionFollowUpEntries, generatePrenatalFollowUpEntries) +import RemoteData +import Translate exposing (Language) filterProgramTypeToString : FilterProgramType -> String @@ -48,3 +89,890 @@ filterProgramTypeFromString string = _ -> Nothing + + +generateAssembledData : HealthCenterId -> DashboardStatsRaw -> ModelIndexedDb -> Model -> AssembledData +generateAssembledData healthCenterId stats db model = + { stats = generateFilteredDashboardStats stats model + , acuteIllnessData = generateFilteredAcuteIllnessData stats model + , prenatalData = generateFilteredPrenatalData stats model + , caseManagementData = + Dict.get healthCenterId db.followUpMeasurements + |> Maybe.andThen RemoteData.toMaybe + } + + +generateFilteredDashboardStats : DashboardStatsRaw -> Model -> DashboardStats +generateFilteredDashboardStats stats model = + { caseManagement = + { thisYear = + applyProgramTypeAndResidentsFilters stats.villagesWithResidents + model.programTypeFilter + model.selectedVillageFilter + stats.caseManagement.thisYear + |> caseManagementMergeDuplicates + , lastYear = + applyProgramTypeAndResidentsFilters + stats.villagesWithResidents + model.programTypeFilter + model.selectedVillageFilter + stats.caseManagement.lastYear + |> caseManagementMergeDuplicates + } + , childrenBeneficiaries = applyProgramTypeAndResidentsFilters stats.villagesWithResidents model.programTypeFilter model.selectedVillageFilter stats.childrenBeneficiaries + , completedPrograms = stats.completedPrograms + , familyPlanning = stats.familyPlanning + , missedSessions = stats.missedSessions + , totalEncounters = stats.totalEncounters + , villagesWithResidents = stats.villagesWithResidents + , timestamp = stats.timestamp + } + + +generateFilteredAcuteIllnessData : DashboardStatsRaw -> Model -> List AcuteIllnessDataItem +generateFilteredAcuteIllnessData stats model = + model.selectedVillageFilter + |> Maybe.andThen + (\villageId -> Dict.get villageId stats.villagesWithResidents) + |> Maybe.map + (\residents -> List.filter (\item -> List.member item.identifier residents) stats.acuteIllnessData) + |> Maybe.withDefault [] + + +generateFilteredPrenatalData : DashboardStatsRaw -> Model -> List PrenatalDataItem +generateFilteredPrenatalData stats model = + model.selectedVillageFilter + |> Maybe.andThen + (\villageId -> Dict.get villageId stats.villagesWithResidents) + |> Maybe.map + (\residents -> List.filter (\item -> List.member item.identifier residents) stats.prenatalData) + |> Maybe.withDefault [] + + +applyProgramTypeAndResidentsFilters : + Dict VillageId (List PersonIdentifier) + -> FilterProgramType + -> Maybe VillageId + -> Dict ProgramType (List { a | identifier : PersonIdentifier }) + -> List { a | identifier : PersonIdentifier } +applyProgramTypeAndResidentsFilters villagesWithResidents programTypeFilter selectedVillageFilter dict = + case programTypeFilter of + FilterAllPrograms -> + let + achi = + Dict.get ProgramAchi dict + |> Maybe.withDefault [] + + fbf = + Dict.get ProgramFbf dict + |> Maybe.withDefault [] + + pmtct = + Dict.get ProgramPmtct dict + |> Maybe.withDefault [] + + sorwathe = + Dict.get ProgramSorwathe dict + |> Maybe.withDefault [] + + chw = + Dict.get ProgramChw dict + |> Maybe.withDefault [] + + individual = + Dict.get ProgramIndividual dict + |> Maybe.withDefault [] + in + achi ++ fbf ++ pmtct ++ sorwathe ++ chw ++ individual + + FilterProgramAchi -> + Dict.get ProgramAchi dict + |> Maybe.withDefault [] + + FilterProgramFbf -> + Dict.get ProgramFbf dict + |> Maybe.withDefault [] + + FilterProgramPmtct -> + Dict.get ProgramPmtct dict + |> Maybe.withDefault [] + + FilterProgramSorwathe -> + Dict.get ProgramSorwathe dict + |> Maybe.withDefault [] + + FilterProgramCommunity -> + selectedVillageFilter + |> Maybe.map + (\selectedVillage -> + let + villageResidents = + Dict.get selectedVillage villagesWithResidents + |> Maybe.withDefault [] + in + applyProgramTypeAndResidentsFilters villagesWithResidents FilterAllPrograms selectedVillageFilter dict + |> List.filter (\item -> List.member item.identifier villageResidents) + ) + |> Maybe.withDefault [] + + +mergeNutritionValueDicts : Dict Int NutritionValue -> Dict Int NutritionValue -> Dict Int NutritionValue +mergeNutritionValueDicts dict1 dict2 = + Dict.merge + (\key nutritionCase -> Dict.insert key nutritionCase) + (\key nutritionCase1 nutritionCase2 -> Dict.insert key (mergeNutritionValues nutritionCase1 nutritionCase2)) + (\key nutritionCase -> Dict.insert key nutritionCase) + dict1 + dict2 + Dict.empty + + +caseManagementMergeDuplicates : List CaseManagement -> List CaseManagement +caseManagementMergeDuplicates cases = + List.foldl + (\candidate accum -> + Dict.get candidate.identifier accum + |> Maybe.map + (\current -> + let + mergedNutrition = + { stunting = mergeNutritionValueDicts candidate.nutrition.stunting candidate.nutrition.stunting + , underweight = mergeNutritionValueDicts candidate.nutrition.underweight candidate.nutrition.underweight + , wasting = mergeNutritionValueDicts candidate.nutrition.wasting candidate.nutrition.wasting + , muac = mergeNutritionValueDicts candidate.nutrition.muac candidate.nutrition.muac + , nutritionSigns = mergeNutritionValueDicts candidate.nutrition.nutritionSigns candidate.nutrition.nutritionSigns + } + + merged = + { current | nutrition = mergedNutrition } + in + Dict.insert current.identifier merged accum + ) + |> Maybe.withDefault (Dict.insert candidate.identifier candidate accum) + ) + Dict.empty + cases + |> Dict.values + + +mergeNutritionValues : NutritionValue -> NutritionValue -> NutritionValue +mergeNutritionValues first second = + case compareNutritionStatus first.class second.class of + GT -> + first + + EQ -> + let + firstValue = + String.toFloat first.value + + secondValue = + String.toFloat second.value + in + case ( firstValue, secondValue ) of + ( Just value1, Just value2 ) -> + if compare value1 value2 == GT then + first + + else + second + + ( Just value1, Nothing ) -> + first + + ( Nothing, Just value2 ) -> + second + + ( Nothing, Nothing ) -> + second + + LT -> + second + + +compareNutritionStatus : NutritionStatus -> NutritionStatus -> Order +compareNutritionStatus first second = + let + numericValue status = + case status of + Backend.Dashboard.Model.Neutral -> + 0 + + Backend.Dashboard.Model.Good -> + 1 + + Backend.Dashboard.Model.Moderate -> + 2 + + Backend.Dashboard.Model.Severe -> + 3 + in + compare (numericValue first) (numericValue second) + + +generateTotalEncounters : TotalEncountersData -> Model -> Periods +generateTotalEncounters data model = + let + ( dict, programTypeFilter ) = + case model.selectedVillageFilter of + Just village -> + ( Dict.get village data.villages + |> Maybe.withDefault Dict.empty + , FilterAllPrograms + ) + + -- When village is not selected, we show global data. + Nothing -> + ( data.global, model.programTypeFilter ) + in + generateTotalEncountersFromPeriodsDict programTypeFilter dict + + +generateTotalEncountersFromPeriodsDict : FilterProgramType -> Dict ProgramType Periods -> Periods +generateTotalEncountersFromPeriodsDict programTypeFilter dict = + let + emptyPeriods = + Periods 0 0 + in + case programTypeFilter of + FilterAllPrograms -> + let + achi = + Dict.get ProgramAchi dict + |> Maybe.withDefault emptyPeriods + + fbf = + Dict.get ProgramFbf dict + |> Maybe.withDefault emptyPeriods + + pmtct = + Dict.get ProgramPmtct dict + |> Maybe.withDefault emptyPeriods + + sorwathe = + Dict.get ProgramSorwathe dict + |> Maybe.withDefault emptyPeriods + + chw = + Dict.get ProgramChw dict + |> Maybe.withDefault emptyPeriods + + individual = + Dict.get ProgramIndividual dict + |> Maybe.withDefault emptyPeriods + + sumPeriods p1 p2 = + Periods (p1.lastYear + p2.lastYear) (p1.thisYear + p2.thisYear) + in + sumPeriods achi fbf + |> sumPeriods pmtct + |> sumPeriods sorwathe + |> sumPeriods chw + |> sumPeriods individual + + FilterProgramAchi -> + Dict.get ProgramAchi dict + |> Maybe.withDefault emptyPeriods + + FilterProgramFbf -> + Dict.get ProgramFbf dict + |> Maybe.withDefault emptyPeriods + + FilterProgramPmtct -> + Dict.get ProgramPmtct dict + |> Maybe.withDefault emptyPeriods + + FilterProgramSorwathe -> + Dict.get ProgramSorwathe dict + |> Maybe.withDefault emptyPeriods + + FilterProgramCommunity -> + -- This type requires village to be selected, and when it is, + -- generateTotalEncounters() will invoke this function with + -- FilterAllPrograms for village data. + emptyPeriods + + + +-- +-- Acute illness - Overview functions. +-- + + +getAcuteIllnessEncountersForSelectedMonth : NominalDate -> List AcuteIllnessDataItem -> List AcuteIllnessEncounterDataItem +getAcuteIllnessEncountersForSelectedMonth selectedDate itemsList = + List.map .encounters itemsList + |> List.concat + |> List.filter (.startDate >> withinSelectedMonth selectedDate) + + +countAcuteIllnessAssesments : List AcuteIllnessEncounterDataItem -> Int +countAcuteIllnessAssesments encounters = + -- Count number of encounters that occured during selected month. + List.length encounters + + +countAcuteIllnessDiagnosedCases : List AcuteIllnessEncounterDataItem -> Int +countAcuteIllnessDiagnosedCases encounters = + List.filter (.diagnosis >> (/=) NoAcuteIllnessDiagnosis) encounters + |> List.length + + +countAcuteIllnessCasesByTreatmentApproach : List AcuteIllnessEncounterDataItem -> ( Int, Int ) +countAcuteIllnessCasesByTreatmentApproach encounters = + let + diagnosedEncounters = + List.filter (.diagnosis >> (/=) NoAcuteIllnessDiagnosis) encounters + + sentToHC = + List.filter wasSentToHCByDiagnosis diagnosedEncounters + + managedAtHome = + List.filter wasManagedAtHomeByDiagnosis diagnosedEncounters + in + ( List.length sentToHC, List.length managedAtHome ) + + +{-| There's a difference betweeen non Covid and Covid cases, when making +a decision if to send patient to health center. +Covid case has a specific set of parameters, while non Covid has a simple logic - +only those that Yes answered to quesiton about patien being refered to HC. +-} +wasSentToHCByDiagnosis : AcuteIllnessEncounterDataItem -> Bool +wasSentToHCByDiagnosis encounter = + case encounter.diagnosis of + DiagnosisCovid19 -> + let + sentToHCBy114 = + EverySet.member Call114 encounter.call114Signs + && EverySet.member SendToHealthCenter encounter.recommendation114 + + sentToHCByHC = + EverySet.member ContactedHealthCenter encounter.hcContactSigns + && EverySet.member ComeToHealthCenter encounter.hcRecommendation + in + sentToHCBy114 || sentToHCByHC + + -- All others, but it must exclude NoAcuteIllnessDiagnosis - invoking function + -- should be taking care of this. + _ -> + -- All that were refered sent to HC. + EverySet.member ReferToHealthCenter encounter.sendToHCSigns + + +{-| There's a difference betweeen non Covid and Covid cases, when making +a decision if to manage illness at home. +Covid case has a specific set of parameters, while non Covid has a simple logic - +if patient was not sent to HC, then it was managed at home. +-} +wasManagedAtHomeByDiagnosis : AcuteIllnessEncounterDataItem -> Bool +wasManagedAtHomeByDiagnosis encounter = + case encounter.diagnosis of + DiagnosisCovid19 -> + -- HC was contacted, and it suggested home isolation + -- or CHW monitoring. + EverySet.member ContactedHealthCenter encounter.hcContactSigns + && (EverySet.member HomeIsolation encounter.hcRecommendation + || EverySet.member ChwMonitoring encounter.hcRecommendation + ) + + -- All others, but it must exclude NoAcuteIllnessDiagnosis - invoking function + -- should be taking care of this. + _ -> + -- All that were not refered to HC are managed at home. + not <| wasSentToHCByDiagnosis encounter + + +countAcuteIllnessCasesByPossibleDiagnosises : List AcuteIllnessDiagnosis -> Bool -> List AcuteIllnessEncounterDataItem -> Int +countAcuteIllnessCasesByPossibleDiagnosises possible whenFeverRecorded encounters = + List.filter + (\encounter -> + let + feverFilter = + if whenFeverRecorded then + encounter.feverRecorded + + else + True + in + List.member encounter.diagnosis possible + && feverFilter + ) + encounters + |> List.length + + + +-- +-- Acute illness - COVID functions. +-- + + +countDiagnosedWithCovidCallsTo114 : List AcuteIllnessEncounterDataItem -> Int +countDiagnosedWithCovidCallsTo114 encounters = + List.filter + (\encounter -> + -- Encounter which has produced Covid19 diagnosis, + -- and there was a call to 114. + (encounter.diagnosis == DiagnosisCovid19) + && EverySet.member Call114 encounter.call114Signs + ) + encounters + |> List.length + + +countDiagnosedWithCovidSentToHC : List AcuteIllnessEncounterDataItem -> Int +countDiagnosedWithCovidSentToHC encounters = + -- Encounters which has produced Covid19 diagnosis, + -- and patient was sent to health center. + List.filter (.diagnosis >> (==) DiagnosisCovid19) encounters + |> List.filter wasSentToHCByDiagnosis + |> List.length + + +countDiagnosedWithCovidManagedAtHome : List AcuteIllnessEncounterDataItem -> Int +countDiagnosedWithCovidManagedAtHome encounters = + -- Encounter which has produced Covid19 diagnosis, + -- and it was decided to manage illness at home. + List.filter (.diagnosis >> (==) DiagnosisCovid19) encounters + |> List.filter wasManagedAtHomeByDiagnosis + |> List.length + + + +-- +-- Acute illness - Malaria functions. +-- + + +countDiagnosedWithMalaria : List AcuteIllnessEncounterDataItem -> Int +countDiagnosedWithMalaria encounters = + List.filter + (\encounter -> + List.member encounter.diagnosis + [ DiagnosisMalariaComplicated + , DiagnosisMalariaUncomplicated + , DiagnosisMalariaUncomplicatedAndPregnant + ] + ) + encounters + |> List.length + + +countUncomplicatedMalariaManagedByChw : List AcuteIllnessEncounterDataItem -> Int +countUncomplicatedMalariaManagedByChw encounters = + List.filter + (\encounter -> + -- Enconter which has produced Uncomplicated Malaria diagnosis, + -- and patient was not sent to health center. + (encounter.diagnosis == DiagnosisMalariaUncomplicated) + && not (EverySet.member ReferToHealthCenter encounter.sendToHCSigns) + ) + encounters + |> List.length + + +countUncomplicatedMalariaAndPregnantSentToHC : List AcuteIllnessEncounterDataItem -> Int +countUncomplicatedMalariaAndPregnantSentToHC encounters = + List.filter + (\encounter -> + -- Encounter which has produced Uncomplicated Malaria and Pregnant + -- diagnosis, and patient was sent to health center. + (encounter.diagnosis == DiagnosisMalariaUncomplicatedAndPregnant) + && EverySet.member ReferToHealthCenter encounter.sendToHCSigns + ) + encounters + |> List.length + + +countComplicatedMalariaSentToHC : List AcuteIllnessEncounterDataItem -> Int +countComplicatedMalariaSentToHC encounters = + List.filter + (\encounter -> + -- Encounter which has produced Comlpicated Malaria diagnosis, + -- and patient was sent to health center. + (encounter.diagnosis == DiagnosisMalariaComplicated) + && EverySet.member ReferToHealthCenter encounter.sendToHCSigns + ) + encounters + |> List.length + + +countResolvedMalariaCasesForSelectedMonth : NominalDate -> List AcuteIllnessDataItem -> Int +countResolvedMalariaCasesForSelectedMonth selectedDate itemsList = + List.filter + (\item -> + case item.dateConcluded of + Nothing -> + False + + Just dateConcluded -> + -- Illness that was resolved at selected month, + -- and had a Malaria diagnosis. + withinSelectedMonth selectedDate dateConcluded + && List.member item.diagnosis + [ DiagnosisMalariaComplicated + , DiagnosisMalariaUncomplicated + , DiagnosisMalariaUncomplicatedAndPregnant + ] + ) + itemsList + |> List.length + + + +-- +-- Acute illness - Gastro functions. +-- + + +countDiagnosedWithGI : List AcuteIllnessEncounterDataItem -> Int +countDiagnosedWithGI encounters = + List.filter + (\encounter -> + List.member encounter.diagnosis + [ DiagnosisGastrointestinalInfectionComplicated + , DiagnosisGastrointestinalInfectionUncomplicated + ] + ) + encounters + |> List.length + + +countUncomplicatedGIManagedByChw : List AcuteIllnessEncounterDataItem -> Int +countUncomplicatedGIManagedByChw encounters = + List.filter + (\encounter -> + -- Encounter which has produced Uncomlicated GI diagnosis, + -- and patient was not sent to health center. + (encounter.diagnosis == DiagnosisGastrointestinalInfectionUncomplicated) + && not (EverySet.member ReferToHealthCenter encounter.sendToHCSigns) + ) + encounters + |> List.length + + +countComplicatedGISentToHC : List AcuteIllnessEncounterDataItem -> Int +countComplicatedGISentToHC encounters = + List.filter + (\encounter -> + -- Encounter which has produced Comlicated GI diagnosis, + -- and patient was sent to health center. + (encounter.diagnosis == DiagnosisGastrointestinalInfectionComplicated) + && EverySet.member ReferToHealthCenter encounter.sendToHCSigns + ) + encounters + |> List.length + + +countResolvedGICasesForSelectedMonth : NominalDate -> List AcuteIllnessDataItem -> Int +countResolvedGICasesForSelectedMonth selectedDate itemsList = + List.filter + (\item -> + case item.dateConcluded of + Nothing -> + False + + Just dateConcluded -> + -- Illness that was resolved at selected month, + -- has outcome set, and had a GI diagnosis. + withinSelectedMonth selectedDate dateConcluded + && isJust item.outcome + && List.member item.diagnosis + [ DiagnosisGastrointestinalInfectionComplicated + , DiagnosisGastrointestinalInfectionUncomplicated + ] + ) + itemsList + |> List.length + + + +-- +-- ANC functions. +-- + + +countNewlyIdentifiedPregananciesForSelectedMonth : NominalDate -> List PrenatalDataItem -> Int +countNewlyIdentifiedPregananciesForSelectedMonth selectedDate itemsList = + itemsList + |> List.filter (.created >> withinSelectedMonth selectedDate) + |> List.length + + +countCurrentlyPregnantForSelectedMonth : NominalDate -> NominalDate -> List PrenatalDataItem -> Int +countCurrentlyPregnantForSelectedMonth currentDate selectedDate itemsList = + getCurrentlyPregnantForSelectedMonth currentDate selectedDate itemsList + |> List.length + + +getCurrentlyPregnantForSelectedMonth : NominalDate -> NominalDate -> List PrenatalDataItem -> List PrenatalDataItem +getCurrentlyPregnantForSelectedMonth currentDate selectedDate itemsList = + let + dateFirstDayOfSelectedMonth = + Date.floor Date.Month selectedDate + + dateFirstDayOfNextMonth = + Date.ceiling Date.Month selectedDate + in + itemsList + |> List.filter + (\item -> + let + -- Pregnancy was tracked during current month, or before. + createdDateFilter = + Date.compare item.created dateFirstDayOfNextMonth == LT + + -- Expected date exists, and is set to 3 weeks or less, + -- before the beggining of the range. + expectedDateConcludedFilter = + item.expectedDateConcluded + |> Maybe.map + (\expectedDateConcluded -> + Date.diff Date.Weeks expectedDateConcluded dateFirstDayOfSelectedMonth <= 3 + ) + |> Maybe.withDefault False + + -- No date concluded, or it's set within month range, or after that. + actualDateConcludedFilter = + case item.dateConcluded of + Just dateConcluded -> + let + compareResult = + Date.compare dateFirstDayOfSelectedMonth dateConcluded + in + compareResult == LT || compareResult == EQ + + Nothing -> + True + in + createdDateFilter && expectedDateConcludedFilter && actualDateConcludedFilter + ) + + +countCurrentlyPregnantWithDangerSignsForSelectedMonth : NominalDate -> NominalDate -> List PrenatalDataItem -> Int +countCurrentlyPregnantWithDangerSignsForSelectedMonth currentDate selectedDate itemsList = + getCurrentlyPregnantWithDangerSignsForSelectedMonth currentDate selectedDate itemsList + |> List.length + + +getCurrentlyPregnantWithDangerSignsForSelectedMonth : NominalDate -> NominalDate -> List PrenatalDataItem -> List PrenatalDataItem +getCurrentlyPregnantWithDangerSignsForSelectedMonth currentDate selectedDate itemsList = + getCurrentlyPregnantForSelectedMonth currentDate selectedDate itemsList + |> List.filter + (.encounters + >> List.any + (\encounter -> + -- Active pregnancy that got an encounter at + -- selected month, where danger signs where recorded. + withinSelectedMonth selectedDate encounter.startDate + && (not <| EverySet.isEmpty encounter.dangerSigns) + && (encounter.dangerSigns /= EverySet.singleton NoDangerSign) + ) + ) + + +countNewbornForSelectedMonth : NominalDate -> List PrenatalDataItem -> Int +countNewbornForSelectedMonth selectedDate itemsList = + itemsList + |> List.filter + (\item -> + Maybe.map2 + (\dateConcluded outcome -> + -- Live baby born within selected month. + (outcome == Pregnancy OutcomeLiveAtTerm || outcome == Pregnancy OutcomeLivePreTerm) + && withinSelectedMonth selectedDate dateConcluded + ) + item.dateConcluded + item.outcome + |> Maybe.withDefault False + ) + |> List.length + + +countPregnanciesDueWithin4MonthsForSelectedMonth : NominalDate -> List PrenatalDataItem -> Int +countPregnanciesDueWithin4MonthsForSelectedMonth selectedDate itemsList = + let + dateFirstDayOfSelectedMonth = + Date.floor Date.Month selectedDate + + dateLastDayOfSelectedMonth = + Date.ceiling Date.Month selectedDate + |> Date.add Date.Days -1 + in + itemsList + |> List.filter + (\item -> + let + -- Either pregnanacy is not concluded, or, it was concluded + -- after selected months has ended. + dateConcludedFilter = + case item.dateConcluded of + Just dateConcluded -> + Date.compare dateConcluded dateLastDayOfSelectedMonth == GT + + Nothing -> + True + + -- Expected date exists, is within selected month or + -- latter than that, and within 120 days from the + -- beginning of selected month. + expectedDateConcludedFilter = + item.expectedDateConcluded + |> Maybe.map + (\expectedDateConcluded -> + let + compareResult = + Date.compare expectedDateConcluded dateFirstDayOfSelectedMonth + in + (compareResult == GT || compareResult == EQ) + && (Date.diff Date.Days dateFirstDayOfSelectedMonth expectedDateConcluded <= 120) + ) + |> Maybe.withDefault False + in + dateConcludedFilter && expectedDateConcludedFilter + ) + |> List.length + + +countDeliveriesAtLocationForSelectedMonth : NominalDate -> DeliveryLocation -> List PrenatalDataItem -> Int +countDeliveriesAtLocationForSelectedMonth selectedDate location itemsList = + itemsList + |> List.filter + (\item -> + Maybe.map2 + (\dateConcluded deliveryLocation -> + -- Live baby born within selected month. + withinSelectedMonth selectedDate dateConcluded + && (deliveryLocation == location) + ) + item.dateConcluded + item.deliveryLocation + |> Maybe.withDefault False + ) + |> List.length + + + +-- +-- Case management functions. +-- + + +getFollowUpsTotals : Language -> NominalDate -> NominalDate -> ModelIndexedDb -> VillageId -> FollowUpMeasurements -> ( Int, Int, Int ) +getFollowUpsTotals language currentDate limitDate db villageId followUps = + let + followUpsToLimitDate = + filterFollowUpMeasurementsByLimitDate limitDate followUps + + nutritionFollowUps = + generateNutritionFollowUps db followUpsToLimitDate + |> filterVillageResidents villageId identity db + + nutritionEntries = + generateNutritionFollowUpEntries language currentDate limitDate nutritionFollowUps db + + acuteIllnessFollowUps = + generateAcuteIllnessFollowUps db followUpsToLimitDate + |> filterVillageResidents villageId Tuple.second db + + acuteIllnessEntries = + generateAcuteIllnessFollowUpEntries language currentDate limitDate acuteIllnessFollowUps db + + prenatalFollowUps = + generatePrenatalFollowUps db followUpsToLimitDate + |> filterVillageResidents villageId Tuple.second db + + prenatalEntries = + generatePrenatalFollowUpEntries language currentDate limitDate prenatalFollowUps db + in + ( List.length nutritionEntries + , List.length acuteIllnessEntries + , List.length prenatalEntries + ) + + +getAcuteIllnessFollowUpsBreakdownByDiagnosis : Language -> NominalDate -> NominalDate -> ModelIndexedDb -> VillageId -> FollowUpMeasurements -> ( Int, Int, Int ) +getAcuteIllnessFollowUpsBreakdownByDiagnosis language currentDate limitDate db villageId followUps = + let + acuteIllnessFollowUps = + filterFollowUpMeasurementsByLimitDate limitDate followUps + |> generateAcuteIllnessFollowUps db + |> filterVillageResidents villageId Tuple.second db + + acuteIllnessEntries = + generateAcuteIllnessFollowUpEntries language currentDate limitDate acuteIllnessFollowUps db + + covidEntries = + List.filter (.diagnosis >> (==) DiagnosisCovid19) acuteIllnessEntries + + malariaEntries = + List.filter + (\entry -> + List.member entry.diagnosis + [ DiagnosisMalariaComplicated + , DiagnosisMalariaUncomplicated + , DiagnosisMalariaUncomplicatedAndPregnant + ] + ) + acuteIllnessEntries + + giEntries = + List.filter + (\entry -> + List.member entry.diagnosis + [ DiagnosisGastrointestinalInfectionComplicated + , DiagnosisGastrointestinalInfectionUncomplicated + ] + ) + acuteIllnessEntries + in + ( List.length covidEntries + , List.length malariaEntries + , List.length giEntries + ) + + +filterFollowUpMeasurementsByLimitDate : NominalDate -> FollowUpMeasurements -> FollowUpMeasurements +filterFollowUpMeasurementsByLimitDate limitDate followUpMeasurements = + { followUpMeasurements + | nutritionGroup = filterByLimitDate limitDate followUpMeasurements.nutritionGroup + , nutritionIndividual = filterByLimitDate limitDate followUpMeasurements.nutritionIndividual + , acuteIllness = filterByLimitDate limitDate followUpMeasurements.acuteIllness + , prenatal = filterByLimitDate limitDate followUpMeasurements.prenatal + } + + + +-- +-- Helper functions. +-- + + +withinSelectedMonth : NominalDate -> NominalDate -> Bool +withinSelectedMonth selectedDate date = + let + month = + Date.monthNumber selectedDate + + year = + Date.year selectedDate + in + (Date.monthNumber date == month) + && (Date.year date == year) + + +getSelectedDate : NominalDate -> Model -> NominalDate +getSelectedDate currentDate model = + Date.add Date.Months (-1 * model.monthGap) currentDate + + +childrenBeneficiariesByProgramType : ProgramType -> Dict ProgramType (List ChildrenBeneficiariesStats) -> List ChildrenBeneficiariesStats +childrenBeneficiariesByProgramType programType childrenBeneficiaries = + Dict.get programType childrenBeneficiaries + |> Maybe.withDefault [] + + +filterByLimitDate : NominalDate -> Dict id { a | dateMeasured : NominalDate } -> Dict id { a | dateMeasured : NominalDate } +filterByLimitDate limitDate followUps = + Dict.filter (\_ followUp -> Date.compare followUp.dateMeasured limitDate == LT) followUps diff --git a/client/src/elm/Pages/Dashboard/View.elm b/client/src/elm/Pages/Dashboard/View.elm index 9544753b36..ac3b943c1c 100644 --- a/client/src/elm/Pages/Dashboard/View.elm +++ b/client/src/elm/Pages/Dashboard/View.elm @@ -1,18 +1,24 @@ module Pages.Dashboard.View exposing (view) import AssocList as Dict exposing (Dict) +import Backend.AcuteIllnessEncounter.Model exposing (AcuteIllnessDiagnosis(..)) import Backend.Dashboard.Model exposing - ( CaseManagement + ( AcuteIllnessDataItem + , AcuteIllnessEncounterDataItem + , AssembledData + , CaseManagement , CaseManagementData , CaseNutrition , CaseNutritionTotal + , ChildrenBeneficiariesData , DashboardStats , Nutrition , NutritionValue , ParticipantStats , Periods , PersonIdentifier + , PrenatalDataItem , ProgramType(..) , TotalBeneficiaries , TotalEncountersData @@ -21,12 +27,13 @@ import Backend.Dashboard.Model , emptyTotalBeneficiaries ) import Backend.Entities exposing (..) +import Backend.IndividualEncounterParticipant.Model exposing (DeliveryLocation(..), IndividualEncounterType(..)) import Backend.Measurement.Model exposing (FamilyPlanningSign(..)) import Backend.Model exposing (ModelIndexedDb) import Backend.Nurse.Model exposing (Nurse) import Backend.Person.Model import Color exposing (Color) -import Date exposing (Month, Unit(..), isBetween, numberToMonth) +import Date exposing (Month, Unit(..), isBetween, monthNumber, numberToMonth, year) import Debug exposing (toString) import EverySet import Gizra.Html exposing (emptyNode, showMaybe) @@ -40,15 +47,17 @@ import Maybe.Extra exposing (isJust, isNothing) import Pages.Dashboard.GraphUtils exposing (..) import Pages.Dashboard.Model exposing (..) import Pages.Dashboard.Utils exposing (..) -import Pages.Page exposing (DashboardPage(..), Page(..), UserPage(..)) +import Pages.GlobalCaseManagement.Utils exposing (allEncounterTypes) +import Pages.Page exposing (AcuteIllnessDashboardPage(..), ChwDashboardPage(..), DashboardPage(..), NurseDashboardPage(..), Page(..), UserPage(..)) import Pages.Utils exposing (calculatePercentage) import Path -import RemoteData +import RemoteData exposing (RemoteData(..)) import Restful.Endpoint exposing (fromEntityUuid) import Scale exposing (BandConfig, BandScale, ContinuousScale) import Shape exposing (Arc, defaultPieConfig) import Svg import Svg.Attributes exposing (cx, cy, r) +import Time exposing (millisToPosix) import Translate exposing (Language, TranslationId, translate, translateText) import TypedSvg exposing (g, svg) import TypedSvg.Attributes as Explicit exposing (fill, transform, viewBox) @@ -62,291 +71,163 @@ import Utils.Html exposing (spinner, viewModal) view : Language -> DashboardPage -> NominalDate -> HealthCenterId -> Bool -> Nurse -> Model -> ModelIndexedDb -> Html Msg view language page currentDate healthCenterId isChw nurse model db = let - ( content, goBackPage ) = - Dict.get healthCenterId db.computedDashboard - |> Maybe.map - (\stats -> - case page of - MainPage -> - ( viewMainPage language currentDate isChw nurse stats db model, PinCodePage ) - - StatsPage -> - ( viewStatsPage language currentDate isChw nurse stats healthCenterId db model, UserPage <| DashboardPage MainPage ) - - CaseManagementPage -> - ( viewCaseManagementPage language currentDate stats db model, UserPage <| DashboardPage model.latestPage ) - ) - |> Maybe.withDefault ( spinner, PinCodePage ) - header = - div - [ class "ui basic head segment" ] - [ h1 [ class "ui header" ] - [ translateText language Translate.DashboardLabel ] - , a - [ class "link-back" - , onClick <| SetActivePage goBackPage - ] - [ span [ class "icon-back" ] [] ] - ] - in - div - [ class "wrap" ] - [ header - , content - ] + case page of + MainPage -> + let + label = + if isChw then + Translate.ChwDashboardLabel + else + Translate.DashboardLabel + in + viewHeader language label PinCodePage -viewMainPage : Language -> NominalDate -> Bool -> Nurse -> DashboardStats -> ModelIndexedDb -> Model -> Html Msg -viewMainPage language currentDate isChw nurse stats db model = - let - currentPeriodStats = - filterStatsWithinPeriod currentDate model stats + ChwPage chwDashboardPage -> + case chwDashboardPage of + AcuteIllnessPage _ -> + viewHeader language (Translate.EncounterTypeFileterLabel AcuteIllnessEncounter) (UserPage <| DashboardPage MainPage) - totalBeneficiariesMonthlyDuringPastYear = - generateTotalBeneficiariesMonthlyDuringPastYear currentDate stats + NutritionPage -> + viewHeader language (Translate.EncounterTypeFileterLabel NutritionEncounter) (UserPage <| DashboardPage MainPage) - emptyTotalBeneficiariesDict = - List.repeat 12 emptyTotalBeneficiaries - |> List.indexedMap (\index empty -> ( index + 1, empty )) - |> Dict.fromList + AntenatalPage -> + viewHeader language (Translate.EncounterTypeFileterLabel AntenatalEncounter) (UserPage <| DashboardPage MainPage) - caseManagementsThisYear = - caseManagementApplyBreakdownFilters stats.villagesWithResidents stats.caseManagement.thisYear model + NursePage nurseDashboardPage -> + let + goBackPage = + case nurseDashboardPage of + StatsPage -> + UserPage <| DashboardPage MainPage - caseManagementsLastYear = - caseManagementApplyBreakdownFilters stats.villagesWithResidents stats.caseManagement.lastYear model + CaseManagementPage -> + UserPage <| DashboardPage model.latestPage + in + viewHeader language Translate.DashboardLabel goBackPage - caseNutritionTotalsThisYear = - caseManagementsThisYear - |> List.map (.nutrition >> generateCaseNutritionTotals) + content = + Dict.get healthCenterId db.computedDashboard + |> Maybe.map + (\stats -> + let + assembled = + generateAssembledData healthCenterId stats db model + + ( pageContent, pageClass ) = + case page of + MainPage -> + ( viewMainPage language currentDate healthCenterId isChw nurse assembled db model + , "main" + ) - caseNutritionTotalsLastYear = - caseManagementsLastYear - |> List.map (.nutrition >> generateCaseNutritionTotals) + NursePage nurseDashboardPage -> + case nurseDashboardPage of + StatsPage -> + ( viewStatsPage language currentDate False nurse assembled.stats healthCenterId db model, "stats" ) - totalsGraphData = - caseNutritionTotalsThisYear - |> List.foldl accumCaseNutritionTotals emptyTotalBeneficiariesDict - |> applyTotalBeneficiariesDenomination totalBeneficiariesMonthlyDuringPastYear + CaseManagementPage -> + ( viewCaseManagementPage language currentDate assembled.stats db model, "case" ) - newCasesGraphData = - caseManagementsThisYear - |> List.map (.nutrition >> generateCaseNutritionNewCases currentDate) - |> List.foldl accumCaseNutritionTotals emptyTotalBeneficiariesDict - |> applyTotalBeneficiariesDenomination totalBeneficiariesMonthlyDuringPastYear + ChwPage chwDashboardPage -> + case chwDashboardPage of + AcuteIllnessPage acuteIllnessPage -> + ( viewAcuteIllnessPage language currentDate acuteIllnessPage assembled db model, "acute-illness" ) - links = - case model.programTypeFilter of - FilterProgramFbf -> - div [ class "sixteen wide column" ] - [ viewDashboardPagesLinks language - ] + NutritionPage -> + ( viewNutritionPage language currentDate True nurse assembled.stats db model, "nutrition" ) - _ -> - emptyNode + AntenatalPage -> + ( viewAntenatalPage language currentDate assembled db model, "prenatal" ) + in + div [ class <| "dashboard " ++ pageClass ] <| + [ viewFiltersPane language page db model ] + ++ pageContent + ++ [ viewCustomModal language isChw nurse assembled.stats db model + , div [ class "timestamp" ] + [ text <| (translate language <| Translate.Dashboard Translate.LastUpdated) ++ ": " ++ assembled.stats.timestamp ++ " UTC" ] + ] + ) + |> Maybe.withDefault spinner in - div [ class "dashboard main" ] - [ div [ class "timestamp" ] [ text <| (translate language <| Translate.Dashboard Translate.LastUpdated) ++ ": " ++ stats.timestamp ++ " UTC" ] - , viewFiltersPane language MainPage filterPeriodsForMainPage db model - , div [ class "ui grid" ] - [ div [ class "eight wide column" ] - [ viewGoodNutrition language caseNutritionTotalsThisYear caseNutritionTotalsLastYear - ] - , div [ class "eight wide column" ] - [ totalEncountersApplyBreakdownFilters currentPeriodStats.totalEncounters model - |> viewTotalEncounters language - ] - , div [ class "sixteen wide column" ] - [ viewMonthlyChart language currentDate MonthlyChartTotals FilterBeneficiariesChart totalsGraphData model.currentBeneficiariesChartsFilter - ] - , div [ class "sixteen wide column" ] - [ viewMonthlyChart language currentDate MonthlyChartIncidence FilterBeneficiariesIncidenceChart newCasesGraphData model.currentBeneficiariesIncidenceChartsFilter - ] - , links - ] - , viewCustomModal language isChw nurse stats db model + div + [ class "wrap" ] + [ header + , content ] -caseManagementApplyBreakdownFilters : Dict VillageId (List PersonIdentifier) -> Dict ProgramType (List CaseManagement) -> Model -> List CaseManagement -caseManagementApplyBreakdownFilters villagesWithResidents dict model = - case model.programTypeFilter of - FilterAllPrograms -> - let - achi = - Dict.get ProgramAchi dict - |> Maybe.withDefault [] - - fbf = - Dict.get ProgramFbf dict - |> Maybe.withDefault [] - - pmtct = - Dict.get ProgramPmtct dict - |> Maybe.withDefault [] - - sorwathe = - Dict.get ProgramSorwathe dict - |> Maybe.withDefault [] - - individual = - Dict.get ProgramIndividual dict - |> Maybe.withDefault [] - in - achi ++ fbf ++ pmtct ++ sorwathe ++ individual - - FilterProgramAchi -> - Dict.get ProgramAchi dict - |> Maybe.withDefault [] - - FilterProgramFbf -> - Dict.get ProgramFbf dict - |> Maybe.withDefault [] - - FilterProgramPmtct -> - Dict.get ProgramPmtct dict - |> Maybe.withDefault [] +viewHeader : Language -> TranslationId -> Page -> Html Msg +viewHeader language label goBackPage = + div [ class "ui basic head segment" ] + [ h1 [ class "ui header" ] + [ translateText language label ] + , span + [ class "link-back" + , onClick <| SetActivePage goBackPage + ] + [ span [ class "icon-back" ] [] ] + ] - FilterProgramSorwathe -> - Dict.get ProgramSorwathe dict - |> Maybe.withDefault [] - FilterProgramCommunity -> - let - villageResidents = - model.selectedVillageFilter - |> Maybe.andThen (\village -> Dict.get village villagesWithResidents) - |> Maybe.withDefault [] +viewMainPage : Language -> NominalDate -> HealthCenterId -> Bool -> Nurse -> AssembledData -> ModelIndexedDb -> Model -> List (Html Msg) +viewMainPage language currentDate healthCenterId isChw nurse assembled db model = + if isChw then + viewChwMainPage language currentDate healthCenterId assembled db model - villageFilterFunc caseManagement = - if isJust model.selectedVillageFilter then - List.member caseManagement.identifier villageResidents - - else - -- Do not filter by village, if village is not selected. - True - - achi = - Dict.get ProgramAchi dict - |> Maybe.withDefault [] - |> List.filter villageFilterFunc - - fbf = - Dict.get ProgramFbf dict - |> Maybe.withDefault [] - |> List.filter villageFilterFunc - - pmtct = - Dict.get ProgramPmtct dict - |> Maybe.withDefault [] - |> List.filter villageFilterFunc - - sorwathe = - Dict.get ProgramSorwathe dict - |> Maybe.withDefault [] - |> List.filter villageFilterFunc - - individual = - Dict.get ProgramIndividual dict - |> Maybe.withDefault [] - |> List.filter villageFilterFunc - in - achi ++ fbf ++ pmtct ++ sorwathe ++ individual + else + viewNutritionPage language currentDate False nurse assembled.stats db model -totalEncountersApplyBreakdownFilters : TotalEncountersData -> Model -> Periods -totalEncountersApplyBreakdownFilters data model = +viewChwMainPage : Language -> NominalDate -> HealthCenterId -> AssembledData -> ModelIndexedDb -> Model -> List (Html Msg) +viewChwMainPage language currentDate healthCenterId assembled db model = let - emptyPeriods = - Periods 0 0 - in - case model.programTypeFilter of - FilterAllPrograms -> - let - achi = - Dict.get ProgramAchi data.global - |> Maybe.withDefault emptyPeriods - - fbf = - Dict.get ProgramFbf data.global - |> Maybe.withDefault emptyPeriods - - pmtct = - Dict.get ProgramPmtct data.global - |> Maybe.withDefault emptyPeriods - - sorwathe = - Dict.get ProgramSorwathe data.global - |> Maybe.withDefault emptyPeriods - - individual = - Dict.get ProgramIndividual data.global - |> Maybe.withDefault emptyPeriods + selectedDate = + getSelectedDate currentDate model - sumPeriods p1 p2 = - Periods (p1.lastYear + p2.lastYear) (p1.thisYear + p2.thisYear) - in - sumPeriods achi fbf - |> sumPeriods pmtct - |> sumPeriods sorwathe - |> sumPeriods individual + -- ANC + encountersForSelectedMonth = + getAcuteIllnessEncountersForSelectedMonth selectedDate assembled.acuteIllnessData - FilterProgramAchi -> - Dict.get ProgramAchi data.global - |> Maybe.withDefault emptyPeriods + diagnosedCases = + countAcuteIllnessDiagnosedCases encountersForSelectedMonth - FilterProgramFbf -> - Dict.get ProgramFbf data.global - |> Maybe.withDefault emptyPeriods + -- Prenatal + currentlyPregnant = + countCurrentlyPregnantForSelectedMonth currentDate selectedDate assembled.prenatalData - FilterProgramPmtct -> - Dict.get ProgramPmtct data.global - |> Maybe.withDefault emptyPeriods + totalNewborn = + countNewbornForSelectedMonth selectedDate assembled.prenatalData - FilterProgramSorwathe -> - Dict.get ProgramSorwathe data.global - |> Maybe.withDefault emptyPeriods + limitDate = + Date.ceiling Date.Month selectedDate - FilterProgramCommunity -> - let - dict = - case model.selectedVillageFilter of - Just village -> - Dict.get village data.villages - |> Maybe.withDefault Dict.empty - - -- When village is not selected, we show global data. - Nothing -> - data.global - - achi = - Dict.get ProgramAchi dict - |> Maybe.withDefault emptyPeriods - - fbf = - Dict.get ProgramFbf dict - |> Maybe.withDefault emptyPeriods - - pmtct = - Dict.get ProgramPmtct dict - |> Maybe.withDefault emptyPeriods - - sorwathe = - Dict.get ProgramSorwathe dict - |> Maybe.withDefault emptyPeriods - - individual = - Dict.get ProgramIndividual dict - |> Maybe.withDefault emptyPeriods - - sumPeriods p1 p2 = - Periods (p1.lastYear + p2.lastYear) (p1.thisYear + p2.thisYear) - in - sumPeriods achi fbf - |> sumPeriods pmtct - |> sumPeriods sorwathe - |> sumPeriods individual + -- Case Management + ( totalNutritionFollowUps, totalAcuteIllnessFollowUps, totalPrenatalFollowUps ) = + Maybe.map2 (getFollowUpsTotals language currentDate limitDate db) + model.selectedVillageFilter + assembled.caseManagementData + |> Maybe.withDefault ( 0, 0, 0 ) + in + [ viewChwMenu language + , monthSelector language selectedDate model + , div [ class "ui grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.AcuteIllnessDiagnosed) (String.fromInt diagnosedCases) + , chwCard language (Translate.Dashboard Translate.MothersInANC) (String.fromInt currentlyPregnant) + , chwCard language (Translate.Dashboard Translate.NewbornsInCare) (String.fromInt totalNewborn) + ] + ] + , div [ class "case-management-label" ] [ text <| translate language <| Translate.CaseManagement ] + , div [ class "ui grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.EncounterTypeFileterLabel AcuteIllnessEncounter) (String.fromInt totalAcuteIllnessFollowUps) + , chwCard language (Translate.EncounterTypeFileterLabel NutritionEncounter) (String.fromInt totalNutritionFollowUps) + , chwCard language (Translate.EncounterTypeFileterLabel AntenatalEncounter) (String.fromInt totalPrenatalFollowUps) + ] + ] + ] applyTotalBeneficiariesDenomination : Dict Int Int -> Dict Int TotalBeneficiaries -> Dict Int TotalBeneficiaries @@ -379,8 +260,12 @@ applyTotalBeneficiariesDenomination beneficiariesPerMonthsDict totalBeneficiarie ) -generateTotalBeneficiariesMonthlyDuringPastYear : NominalDate -> DashboardStats -> Dict Int Int -generateTotalBeneficiariesMonthlyDuringPastYear currentDate stats = +generateTotalBeneficiariesMonthlyDuringPastYear : + NominalDate + -> DashboardStats + -> Model + -> Dict Int Int +generateTotalBeneficiariesMonthlyDuringPastYear currentDate stats model = let currentMonth = Date.month currentDate @@ -408,12 +293,20 @@ generateTotalBeneficiariesMonthlyDuringPastYear currentDate stats = totalBeneficiaries = stats.childrenBeneficiaries - |> List.filter + |> List.filterMap (\child -> - (Date.compare child.memberSince maxJoinDate == LT) - && (Date.compare minGraduationDate child.graduationDate == LT) + if + (Date.compare child.memberSince maxJoinDate == LT) + && (Date.compare minGraduationDate child.graduationDate == LT) + then + Just child.identifier + + else + Nothing ) - |> List.length + -- We want to get unique participants. + |> EverySet.fromList + |> EverySet.size in ( month, totalBeneficiaries ) ) @@ -557,10 +450,10 @@ generateCaseNutritionNewCases currentDate caseNutrition = } -viewStatsPage : Language -> NominalDate -> Bool -> Nurse -> DashboardStats -> HealthCenterId -> ModelIndexedDb -> Model -> Html Msg +viewStatsPage : Language -> NominalDate -> Bool -> Nurse -> DashboardStats -> HealthCenterId -> ModelIndexedDb -> Model -> List (Html Msg) viewStatsPage language currentDate isChw nurse stats healthCenterId db model = if model.programTypeFilter /= FilterProgramFbf then - emptyNode + [] else let @@ -581,25 +474,19 @@ viewStatsPage language currentDate isChw nurse stats healthCenterId db model = monthBeforeStats = filterStatsWithinPeriod currentDate modelWithLastMonth stats - currentPeriodCaseManagement = - caseManagementApplyBreakdownFilters stats.villagesWithResidents currentPeriodStats.caseManagement.thisYear model - malnourishedCurrentMonth = - mapMalnorishedByMonth displayedMonth currentPeriodCaseManagement + mapMalnorishedByMonth displayedMonth currentPeriodStats.caseManagement.thisYear malnourishedPreviousMonth = - mapMalnorishedByMonth (resolvePreviousMonth displayedMonth) currentPeriodCaseManagement + mapMalnorishedByMonth (resolvePreviousMonth displayedMonth) currentPeriodStats.caseManagement.thisYear in - div [ class "dashboard stats" ] - [ viewFiltersPane language StatsPage filterPeriodsForStatsPage db model - , div [ class "ui equal width grid" ] - [ viewMalnourishedCards language malnourishedCurrentMonth malnourishedPreviousMonth - , viewMiscCards language currentDate currentPeriodStats monthBeforeStats - ] - , viewBeneficiariesTable language currentDate stats currentPeriodStats malnourishedCurrentMonth model - , viewFamilyPlanning language currentPeriodStats - , viewCustomModal language isChw nurse stats db model + [ div [ class "ui equal width grid" ] + [ viewMalnourishedCards language malnourishedCurrentMonth malnourishedPreviousMonth + , viewMiscCards language currentDate currentPeriodStats monthBeforeStats ] + , viewBeneficiariesTable language currentDate stats currentPeriodStats malnourishedCurrentMonth model + , viewFamilyPlanning language currentPeriodStats + ] mapMalnorishedByMonth : Int -> List CaseManagement -> List MalnorishedNutritionData @@ -653,10 +540,10 @@ mapMalnorishedByMonth mappedMonth caseManagement = [] -viewCaseManagementPage : Language -> NominalDate -> DashboardStats -> ModelIndexedDb -> Model -> Html Msg +viewCaseManagementPage : Language -> NominalDate -> DashboardStats -> ModelIndexedDb -> Model -> List (Html Msg) viewCaseManagementPage language currentDate stats db model = if model.programTypeFilter /= FilterProgramFbf then - emptyNode + [] else let @@ -706,7 +593,7 @@ viewCaseManagementPage language currentDate stats db model = { name = caseNutrition.name, nutrition = nutrition } :: accum ) [] - (caseManagementApplyBreakdownFilters stats.villagesWithResidents stats.caseManagement.thisYear model) + stats.caseManagement.thisYear |> List.filter (.nutrition >> List.all (Tuple.second >> .class >> (==) Backend.Dashboard.Model.Good) >> not) _ -> @@ -730,7 +617,7 @@ viewCaseManagementPage language currentDate stats db model = accum ) [] - (caseManagementApplyBreakdownFilters stats.villagesWithResidents stats.caseManagement.thisYear model) + stats.caseManagement.thisYear |> List.filter (.nutrition >> List.any @@ -762,22 +649,20 @@ viewCaseManagementPage language currentDate stats db model = |> List.sortBy Tuple.first |> List.reverse in - div [ class "dashboard case" ] - [ viewFiltersPane language CaseManagementPage filterPeriodsForCaseManagementPage db model - , div [ class "ui segment blue" ] - [ div [ class "case-management" ] - [ div [ class "header" ] - [ h3 [ class "title left floated column" ] [ translateText language <| Translate.Dashboard Translate.CaseManagementLabel ] - , List.map (viewFilter language FilterCaseManagement model.currentCaseManagementFilter) caseManagementFilters - |> div [ class "filters" ] - , List.map (viewSubFilter language model.currentCaseManagementSubFilter) (caseManagementSubFilters model.currentCaseManagementFilter) - |> div [ class "filters secondary" ] - ] - , div [ class "content" ] - [ viewCaseManagementTable language currentDate model tableData ] + [ div [ class "ui segment blue" ] + [ div [ class "case-management" ] + [ div [ class "header" ] + [ h3 [ class "title left floated column" ] [ translateText language <| Translate.Dashboard Translate.CaseManagementLabel ] + , List.map (viewFilter language FilterCaseManagement model.currentCaseManagementFilter) caseManagementFilters + |> div [ class "filters" ] + , List.map (viewSubFilter language model.currentCaseManagementSubFilter) (caseManagementSubFilters model.currentCaseManagementFilter) + |> div [ class "filters secondary" ] ] + , div [ class "content" ] + [ viewCaseManagementTable language currentDate model tableData ] ] ] + ] viewCaseManagementTable : Language -> NominalDate -> Model -> List { name : String, nutrition : List ( Int, NutritionValue ) } -> Html Msg @@ -828,62 +713,448 @@ viewMonthCell ( month, cellData ) = td [ class ] [ span [] [ text cellData.value ] ] -viewFiltersPane : Language -> DashboardPage -> List FilterPeriod -> ModelIndexedDb -> Model -> Html Msg -viewFiltersPane language page filterPeriodsPerPage db model = +viewFiltersPane : Language -> DashboardPage -> ModelIndexedDb -> Model -> Html Msg +viewFiltersPane language page db model = let - ( programTypeFilterFilterButton, labelSelected ) = - if page == MainPage then - ( div - [ class "primary ui button program-type-filter" - , onClick <| SetModalState <| Just FiltersModal - ] - [ span [] [ translateText language <| Translate.Dashboard Translate.Filters ] - , span [ class "icon-settings" ] [] - ] - , if model.programTypeFilter == FilterProgramCommunity then - db.villages - |> RemoteData.toMaybe - |> Maybe.andThen - (\villages -> - model.selectedVillageFilter - |> Maybe.andThen - (\villageId -> - Dict.get villageId villages - |> Maybe.map - (\village -> - span [ class "label" ] - [ text <| translate language Translate.SelectedVillage ++ ": " - , text village.name - ] - ) - ) - ) - |> Maybe.withDefault emptyNode + filters = + case page of + MainPage -> + [ labelSelected, programTypeFilterButton ] + + NursePage nursePage -> + case nursePage of + StatsPage -> + let + periodButton period = + button + [ classList + [ ( "inactive", model.period /= period ) + , ( "primary ui button", True ) + ] + , onClick <| SetFilterPeriod period + ] + [ translateText language <| Translate.Dashboard <| Translate.PeriodFilter period + ] + in + List.map periodButton filterPeriodsForStatsPage - else - span [ class "label" ] - [ text <| translate language Translate.SelectedProgram ++ ": " - , translateText language <| Translate.Dashboard <| Translate.FilterProgramType model.programTypeFilter - ] - ) + CaseManagementPage -> + [] + + ChwPage _ -> + [ labelSelected, programTypeFilterButton ] + + programTypeFilterButton = + div + [ class "primary ui button program-type-filter" + , onClick <| SetModalState <| Just FiltersModal + ] + [ span [] [ translateText language <| Translate.Dashboard Translate.Filters ] + , span [ class "icon-settings" ] [] + ] + + labelSelected = + if model.programTypeFilter == FilterProgramCommunity then + db.villages + |> RemoteData.toMaybe + |> Maybe.andThen + (\villages -> + model.selectedVillageFilter + |> Maybe.andThen + (\villageId -> + Dict.get villageId villages + |> Maybe.map + (\village -> + span [ class "label" ] + [ text <| translate language Translate.SelectedVillage ++ ": " + , text village.name + ] + ) + ) + ) + |> Maybe.withDefault emptyNode else - ( emptyNode, emptyNode ) + span [ class "label" ] + [ text <| translate language Translate.SelectedProgram ++ ": " + , translateText language <| Translate.Dashboard <| Translate.FilterProgramType model.programTypeFilter + ] + in + div [ class "ui segment filters" ] + filters - renderButton period = + +viewChwMenu : Language -> Html Msg +viewChwMenu language = + div [ class "ui segment chw-filters" ] + [ viewChwMenuButton language AntenatalPage Nothing + , viewChwMenuButton language NutritionPage Nothing + , viewChwMenuButton language (AcuteIllnessPage OverviewPage) Nothing + ] + + +viewAcuteIllnessMenu : Language -> AcuteIllnessDashboardPage -> Html Msg +viewAcuteIllnessMenu language activePage = + let + viewMenu targetPage = button [ classList - [ ( "inactive", model.period /= period ) + [ ( "active", activePage == targetPage ) , ( "primary ui button", True ) ] - , onClick <| SetFilterPeriod period + , DashboardPage (ChwPage <| AcuteIllnessPage targetPage) + |> UserPage + |> SetActivePage + |> onClick + ] + [ translateText language <| Translate.EncounterTypePageLabel <| AcuteIllnessPage targetPage ] + in + div [ class "ui segment chw-filters" ] + [ viewChwMenuButton language (AcuteIllnessPage OverviewPage) (Just <| AcuteIllnessPage activePage) + , viewChwMenuButton language (AcuteIllnessPage Covid19Page) (Just <| AcuteIllnessPage activePage) + , viewChwMenuButton language (AcuteIllnessPage MalariaPage) (Just <| AcuteIllnessPage activePage) + , viewChwMenuButton language (AcuteIllnessPage GastroPage) (Just <| AcuteIllnessPage activePage) + ] + + +viewChwMenuButton : Language -> ChwDashboardPage -> Maybe ChwDashboardPage -> Html Msg +viewChwMenuButton language targetPage activePage = + let + label = + if isNothing activePage && targetPage == AcuteIllnessPage OverviewPage then + -- On Main page, and target is Acute Illness page. + Translate.EncounterTypeFileterLabel AcuteIllnessEncounter + + else + Translate.EncounterTypePageLabel targetPage + in + button + [ classList + [ ( "active", activePage == Just targetPage ) + , ( "primary ui button", True ) + ] + , DashboardPage (ChwPage targetPage) + |> UserPage + |> SetActivePage + |> onClick + ] + [ translateText language label ] + + +viewAcuteIllnessPage : Language -> NominalDate -> AcuteIllnessDashboardPage -> AssembledData -> ModelIndexedDb -> Model -> List (Html Msg) +viewAcuteIllnessPage language currentDate activePage assembled db model = + let + selectedDate = + getSelectedDate currentDate model + + encountersForSelectedMonth = + getAcuteIllnessEncountersForSelectedMonth selectedDate assembled.acuteIllnessData + + limitDate = + Date.ceiling Date.Month selectedDate + + ( managedCovid, managedMalaria, managedGI ) = + Maybe.map2 (getAcuteIllnessFollowUpsBreakdownByDiagnosis language currentDate limitDate db) + model.selectedVillageFilter + assembled.caseManagementData + |> Maybe.withDefault ( 0, 0, 0 ) + + pageContent = + case activePage of + OverviewPage -> + viewAcuteIllnessOverviewPage language encountersForSelectedMonth model + + Covid19Page -> + viewCovid19Page language encountersForSelectedMonth managedCovid model + + MalariaPage -> + viewMalariaPage language selectedDate assembled.acuteIllnessData encountersForSelectedMonth managedMalaria model + + GastroPage -> + viewGastroPage language selectedDate assembled.acuteIllnessData encountersForSelectedMonth managedGI model + in + [ viewAcuteIllnessMenu language activePage + , monthSelector language selectedDate model + ] + ++ pageContent + + +viewAcuteIllnessOverviewPage : Language -> List AcuteIllnessEncounterDataItem -> Model -> List (Html Msg) +viewAcuteIllnessOverviewPage language encounters model = + let + totalAssesments = + countAcuteIllnessAssesments encounters + + ( sentToHC, managedLocally ) = + countAcuteIllnessCasesByTreatmentApproach encounters + + undeterminedCases = + countAcuteIllnessCasesByPossibleDiagnosises [ DiagnosisUndeterminedMoreEvaluationNeeded ] False encounters + + feverOfUnknownOriginCases = + countAcuteIllnessCasesByPossibleDiagnosises [ DiagnosisFeverOfUnknownOrigin ] False encounters + + covidCases = + countAcuteIllnessCasesByPossibleDiagnosises [ DiagnosisCovid19 ] True encounters + + malariaCases = + countAcuteIllnessCasesByPossibleDiagnosises + [ DiagnosisMalariaComplicated + , DiagnosisMalariaUncomplicated + , DiagnosisMalariaUncomplicatedAndPregnant + ] + True + encounters + + respiratoryCases = + countAcuteIllnessCasesByPossibleDiagnosises [ DiagnosisRespiratoryInfectionComplicated ] True encounters + + giCases = + countAcuteIllnessCasesByPossibleDiagnosises [ DiagnosisGastrointestinalInfectionComplicated ] True encounters + + feverByCauses = + List.filter (Tuple.second >> (/=) 0) + [ ( FeverCauseCovid19, covidCases ) + , ( FeverCauseMalaria, malariaCases ) + , ( FeverCauseRespiratory, respiratoryCases ) + , ( FeverCauseGI, giCases ) + , ( FeverCauseUnknown, feverOfUnknownOriginCases ) ] - [ translateText language <| Translate.Dashboard <| Translate.PeriodFilter period + in + [ div [ class "ui grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.TotalAssessment) (String.fromInt totalAssesments) + , chwCard language (Translate.Dashboard Translate.CommunityLevelCases) (String.fromInt managedLocally) + , chwCard language (Translate.Dashboard Translate.HealthCenterReferrals) (String.fromInt sentToHC) + ] + ] + , div [ class "ui centered grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.DiagnosisUndetermined) (String.fromInt undeterminedCases) + , chwCard language (Translate.Dashboard Translate.FeverOfUnknownOrigin) (String.fromInt feverOfUnknownOriginCases) + ] + ] + , div [ class "ui blue segment donut-chart fever" ] + [ viewFeverDistributionDonutChart language feverByCauses ] + ] + + +viewFeverDistributionDonutChart : Language -> List ( FeverCause, Int ) -> Html Msg +viewFeverDistributionDonutChart language feverByCauses = + if List.isEmpty feverByCauses then + div [ class "no-data-message" ] [ translateText language <| Translate.Dashboard Translate.NoDataForPeriod ] + + else + div [ class "ui center aligned grid" ] + [ div [ class "middle aligned row" ] + [ div [ class "content" ] + [ viewPieChart feverCausesColors feverByCauses + , div [ class "in-chart" ] + [ translateText language <| Translate.Dashboard Translate.FeversByCause ] + , viewPieChartLegend language (Translate.FeverCause >> Translate.Dashboard) feverCauseToColor feverByCauses + ] ] + ] + + +viewCovid19Page : Language -> List AcuteIllnessEncounterDataItem -> Int -> Model -> List (Html Msg) +viewCovid19Page language encounters managedCovid model = + let + callsTo114 = + countDiagnosedWithCovidCallsTo114 encounters + + sentToHC = + countDiagnosedWithCovidSentToHC encounters + + managedAtHome = + countDiagnosedWithCovidManagedAtHome encounters + in + [ div [ class "ui grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.CallsTo114) (String.fromInt callsTo114) + , chwCard language (Translate.Dashboard Translate.HealthCenterReferrals) (String.fromInt sentToHC) + , chwCard language (Translate.Dashboard Translate.PatientsManagedAtHome) (String.fromInt managedAtHome) + ] + ] + , div [ class "ui centered grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.PatientCurrentlyUnderCare) (String.fromInt managedCovid) ] + ] + ] + + +viewMalariaPage : Language -> NominalDate -> List AcuteIllnessDataItem -> List AcuteIllnessEncounterDataItem -> Int -> Model -> List (Html Msg) +viewMalariaPage language selectedDate acuteIllnessData encountersForSelectedMonth managedMalaria model = + let + totalDaignosed = + countDiagnosedWithMalaria encountersForSelectedMonth + + uncomplicatedMalariaManagedByChw = + countUncomplicatedMalariaManagedByChw encountersForSelectedMonth + + uncomplicatedMalariaAndPregnantSentToHC = + countUncomplicatedMalariaAndPregnantSentToHC encountersForSelectedMonth + + complicatedMalariaSentToHC = + countComplicatedMalariaSentToHC encountersForSelectedMonth + + resolvedMalariaCases = + countResolvedMalariaCasesForSelectedMonth selectedDate acuteIllnessData + in + [ div [ class "ui grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.DiagnosedCases) (String.fromInt totalDaignosed) + , chwCard language (Translate.Dashboard Translate.UncomplicatedMalariaByChws) (String.fromInt uncomplicatedMalariaManagedByChw) + , chwCard language (Translate.Dashboard Translate.UncomplicatedMalariaInPregnancyReferredToHc) (String.fromInt uncomplicatedMalariaAndPregnantSentToHC) + ] + ] + , div [ class "ui centered grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.ComplicatedMalariaReferredToHC) (String.fromInt complicatedMalariaSentToHC) + , chwCard language (Translate.Dashboard Translate.ResolvedCases) (String.fromInt resolvedMalariaCases ++ " : " ++ String.fromInt managedMalaria) + ] + ] + ] + + +viewGastroPage : Language -> NominalDate -> List AcuteIllnessDataItem -> List AcuteIllnessEncounterDataItem -> Int -> Model -> List (Html Msg) +viewGastroPage language selectedDate acuteIllnessData encountersForSelectedMonth managedGI model = + let + totalDaignosed = + countDiagnosedWithGI encountersForSelectedMonth + + uncomplicatedGIManagedByChw = + countUncomplicatedGIManagedByChw encountersForSelectedMonth + + complicatedGISentToHC = + countComplicatedGISentToHC encountersForSelectedMonth + + resolvedGICases = + countResolvedGICasesForSelectedMonth selectedDate acuteIllnessData in - div [ class "ui segment filters" ] <| - List.map renderButton filterPeriodsPerPage - ++ [ labelSelected, programTypeFilterFilterButton ] + [ div [ class "ui grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.DiagnosedCases) (String.fromInt totalDaignosed) + , chwCard language (Translate.Dashboard Translate.UncomplicatedGIInfectionByCHWS) (String.fromInt uncomplicatedGIManagedByChw) + , chwCard language (Translate.Dashboard Translate.ComplicatedGIInfectionsReferredToHc) (String.fromInt complicatedGISentToHC) + ] + ] + , div [ class "ui centered grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.ResolvedCases) (String.fromInt resolvedGICases ++ " : " ++ String.fromInt managedGI) + ] + ] + ] + + +viewNutritionPage : Language -> NominalDate -> Bool -> Nurse -> DashboardStats -> ModelIndexedDb -> Model -> List (Html Msg) +viewNutritionPage language currentDate isChw nurse stats db model = + let + currentPeriodStats = + filterStatsWithinPeriod currentDate model stats + + totalBeneficiariesMonthlyDuringPastYear = + generateTotalBeneficiariesMonthlyDuringPastYear currentDate stats model + + emptyTotalBeneficiariesDict = + List.repeat 12 emptyTotalBeneficiaries + |> List.indexedMap (\index empty -> ( index + 1, empty )) + |> Dict.fromList + + caseNutritionTotalsThisYear = + stats.caseManagement.thisYear + |> List.map (.nutrition >> generateCaseNutritionTotals) + + caseNutritionTotalsLastYear = + stats.caseManagement.lastYear + |> List.map (.nutrition >> generateCaseNutritionTotals) + + totalsGraphData = + caseNutritionTotalsThisYear + |> List.foldl accumCaseNutritionTotals emptyTotalBeneficiariesDict + |> applyTotalBeneficiariesDenomination totalBeneficiariesMonthlyDuringPastYear + + newCasesGraphData = + stats.caseManagement.thisYear + |> List.map (.nutrition >> generateCaseNutritionNewCases currentDate) + |> List.foldl accumCaseNutritionTotals emptyTotalBeneficiariesDict + |> applyTotalBeneficiariesDenomination totalBeneficiariesMonthlyDuringPastYear + + links = + case model.programTypeFilter of + FilterProgramFbf -> + div [ class "sixteen wide column" ] + [ viewDashboardPagesLinks language + ] + + _ -> + emptyNode + in + [ div [ class "ui grid" ] + [ div [ class "eight wide column" ] + [ viewGoodNutrition language caseNutritionTotalsThisYear caseNutritionTotalsLastYear + ] + , div [ class "eight wide column" ] + [ generateTotalEncounters currentPeriodStats.totalEncounters model + |> viewTotalEncounters language + ] + , div [ class "sixteen wide column" ] + [ viewMonthlyChart language currentDate MonthlyChartTotals FilterBeneficiariesChart totalsGraphData model.currentBeneficiariesChartsFilter + ] + , div [ class "sixteen wide column" ] + [ viewMonthlyChart language currentDate MonthlyChartIncidence FilterBeneficiariesIncidenceChart newCasesGraphData model.currentBeneficiariesIncidenceChartsFilter + ] + , links + ] + ] + + +viewAntenatalPage : Language -> NominalDate -> AssembledData -> ModelIndexedDb -> Model -> List (Html Msg) +viewAntenatalPage language currentDate assembled db model = + let + selectedDate = + getSelectedDate currentDate model + + newlyIdentifiedPreganancies = + countNewlyIdentifiedPregananciesForSelectedMonth selectedDate assembled.prenatalData + + currentlyPregnant = + countCurrentlyPregnantForSelectedMonth currentDate selectedDate assembled.prenatalData + + pregnanciesDueWithin4Month = + countPregnanciesDueWithin4MonthsForSelectedMonth selectedDate assembled.prenatalData + + currentlyPregnantWithDangerSigns = + countCurrentlyPregnantWithDangerSignsForSelectedMonth currentDate selectedDate assembled.prenatalData + + deliveriesAtHome = + countDeliveriesAtLocationForSelectedMonth selectedDate HomeDelivery assembled.prenatalData + + deliveriesAtFacility = + countDeliveriesAtLocationForSelectedMonth selectedDate FacilityDelivery assembled.prenatalData + in + [ monthSelector language selectedDate model + , div [ class "ui grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.NewPregnancy) (String.fromInt newlyIdentifiedPreganancies) + , chwCard language (Translate.Dashboard Translate.CurrentPregnancies) (String.fromInt currentlyPregnant) + , chwCard language (Translate.Dashboard Translate.Within4MonthsOfDueDate) (String.fromInt pregnanciesDueWithin4Month) + ] + ] + , div [ class "ui centered grid" ] + [ div [ class "three column row" ] + [ chwCard language (Translate.Dashboard Translate.WithDangerSigns) (String.fromInt currentlyPregnantWithDangerSigns) + , chwCard language (Translate.Dashboard Translate.HomeDeliveries) (String.fromInt deliveriesAtHome) + , chwCard language (Translate.Dashboard Translate.HealthFacilityDeliveries) (String.fromInt deliveriesAtFacility) + ] + ] + ] + + +chwCard : Language -> TranslationId -> String -> Html Msg +chwCard language titleTransId value = + div [ class "column" ] + [ viewChwCard language titleTransId value ] viewGoodNutrition : Language -> List CaseNutritionTotal -> List CaseNutritionTotal -> Html Msg @@ -1199,7 +1470,7 @@ viewCard language statsCard = ) cardAttributes = - (class <| "ui segment blue dashboard-cards " ++ statsCard.cardClasses ++ " " ++ cardLinkClass) :: cardAction + (class <| "ui segment blue dashboard-card " ++ statsCard.cardClasses ++ " " ++ cardLinkClass) :: cardAction severityClass = case statsCard.valueSeverity of @@ -1264,6 +1535,16 @@ viewCard language statsCard = ] +viewChwCard : Language -> TranslationId -> String -> Html Msg +viewChwCard language titleTransId value = + div [ class "ui segment dashboard-card chw" ] + [ div [ class "content" ] + [ div [ class "header" ] [ text <| translate language titleTransId ] + , div [ class "value this-year" ] [ text value ] + ] + ] + + viewBeneficiariesGenderFilter : Language -> Model -> Html Msg viewBeneficiariesGenderFilter language model = let @@ -1455,7 +1736,7 @@ viewDashboardPagesLinks language = div [ class "dashboards-links" ] [ div [ class "ui segment stats" - , DashboardPage StatsPage + , DashboardPage (NursePage StatsPage) |> UserPage |> SetActivePage |> onClick @@ -1470,7 +1751,7 @@ viewDashboardPagesLinks language = ] , div [ class "ui segment case" - , DashboardPage CaseManagementPage + , DashboardPage (NursePage CaseManagementPage) |> UserPage |> SetActivePage |> onClick @@ -1489,69 +1770,17 @@ viewDashboardPagesLinks language = viewFamilyPlanning : Language -> DashboardStats -> Html Msg viewFamilyPlanning language stats = div - [ class "ui blue segment family-planning" ] + [ class "ui blue segment donut-chart family-planning" ] [ div [ class "header" ] [ h3 [ class "title" ] [ translateText language <| Translate.Dashboard Translate.FamilyPlanningLabel ] ] , div [ class "ui center aligned grid" ] [ div [ class "middle aligned row" ] - [ viewDonutChart language stats ] + [ viewFamilyPlanningDonutChart language stats ] ] ] -viewDonutChart : Language -> DashboardStats -> Html Msg -viewDonutChart language stats = - let - dict = - getFamilyPlanningSignsCounter stats - in - if Dict.isEmpty dict then - div [ class "no-data-message" ] [ translateText language <| Translate.Dashboard Translate.NoDataForPeriod ] - - else - let - totalWomen = - stats.familyPlanning - |> List.length - - totalNoFamilyPlanning = - Dict.get NoFamilyPlanning dict - |> Maybe.withDefault 0 - - useFamilyPlanning = - totalWomen - totalNoFamilyPlanning - - totalPercent = - useFamilyPlanning * 100 // totalWomen - - signs = - dict - |> Dict.toList - |> List.filter (\( sign, _ ) -> sign /= NoFamilyPlanning) - |> List.sortBy (\( name, val ) -> Debug.toString name) - in - div [ class "content" ] - [ viewChart signs - , div [ class "in-chart" ] - [ div [ class "stats" ] - [ span [ class "percentage neutral" ] [ text <| String.fromInt totalPercent ++ "%" ] - , text " " - , span [ class "use-label" ] [ translateText language <| Translate.Dashboard Translate.UseFamilyPlanning ] - , div [ class "count" ] - [ translateText language <| - Translate.Dashboard <| - Translate.FamilyPlanningOutOfWomen - { total = totalWomen - , useFamilyPlanning = useFamilyPlanning - } - ] - ] - ] - , viewFamilyPlanningChartLegend language signs - ] - - viewMonthlyChart : Language -> NominalDate -> MonthlyChartType -> FilterType -> Dict Int TotalBeneficiaries -> DashboardFilter -> Html Msg viewMonthlyChart language currentDate chartType filterType data currentFilter = let @@ -1572,12 +1801,26 @@ viewMonthlyChart language currentDate chartType filterType data currentFilter = caption = case chartType of MonthlyChartTotals -> - div [ class "title left floated column" ] [ text <| translate language (Translate.Dashboard Translate.TotalBeneficiaries) ++ " " ++ toString currentFilter ++ " (%)" ] + div [ class "title left floated column" ] + [ text <| + translate language (Translate.Dashboard Translate.TotalBeneficiaries) + ++ " " + ++ translate language (Translate.Dashboard <| Translate.Filter currentFilter) + ++ " (%)" + ] MonthlyChartIncidence -> div [ class "title left floated column" ] - [ div [] [ text <| translate language (Translate.Dashboard Translate.IncidenceOf) ++ " " ++ toString currentFilter ++ " (%)" ] - , div [ class "helper" ] [ text "(New cases per month)" ] + [ div [] + [ text <| + translate language (Translate.Dashboard Translate.IncidenceOf) + ++ " " + ++ translate language (Translate.Dashboard <| Translate.Filter currentFilter) + ++ " (%)" + ] + , div [ class "helper" ] + [ text <| "(" ++ translate language (Translate.Dashboard Translate.NewCasesPerMonth) ++ ")" + ] ] chartData = @@ -1727,13 +1970,103 @@ viewSubFilter language currentSubFilter filter = [ translateText language <| Translate.Dashboard <| Translate.SubFilter filter ] -viewFamilyPlanningChartLegend : Language -> List ( FamilyPlanningSign, Int ) -> Html Msg -viewFamilyPlanningChartLegend language signs = +viewFamilyPlanningDonutChart : Language -> DashboardStats -> Html Msg +viewFamilyPlanningDonutChart language stats = + let + dict = + getFamilyPlanningSignsCounter stats + in + if Dict.isEmpty dict then + div [ class "no-data-message" ] [ translateText language <| Translate.Dashboard Translate.NoDataForPeriod ] + + else + let + totalWomen = + stats.familyPlanning + |> List.length + + totalNoFamilyPlanning = + Dict.get NoFamilyPlanning dict + |> Maybe.withDefault 0 + + useFamilyPlanning = + totalWomen - totalNoFamilyPlanning + + totalPercent = + useFamilyPlanning * 100 // totalWomen + + signs = + dict + |> Dict.toList + |> List.filter (\( sign, _ ) -> sign /= NoFamilyPlanning) + |> List.sortBy (\( name, val ) -> Debug.toString name) + in + div [ class "content" ] + [ viewPieChart familyPlanningSignsColors signs + , div [ class "in-chart" ] + [ div [ class "stats" ] + [ span [ class "percentage neutral" ] [ text <| String.fromInt totalPercent ++ "%" ] + , text " " + , span [ class "use-label" ] [ translateText language <| Translate.Dashboard Translate.UseFamilyPlanning ] + , div [ class "count" ] + [ translateText language <| + Translate.Dashboard <| + Translate.FamilyPlanningOutOfWomen + { total = totalWomen + , useFamilyPlanning = useFamilyPlanning + } + ] + ] + ] + , viewPieChartLegend language Translate.FamilyPlanningSignLabel familyPlanningSignToColor signs + ] + + +viewPieChart : Dict a Color -> List ( a, Int ) -> Svg msg +viewPieChart colors values = + let + arcs = + List.map (Tuple.second >> toFloat) values + + signs = + List.map Tuple.first values + + pieData = + arcs + |> Shape.pie + { defaultPieConfig + | outerRadius = radius + , padAngle = 0 + , cornerRadius = 0 + } + in + svg [ Explicit.class [ "pie-chart" ], viewBox 0 0 pieChartWidth pieChartHeight ] + [ annular colors signs pieData ] + + +annular : Dict a Color -> List a -> List Arc -> Svg msg +annular colors signs pieData = + let + getColor index = + List.Extra.getAt index signs + |> Maybe.andThen (\sign -> Dict.get sign colors) + |> Maybe.withDefault Color.black + + makeSlice index datum = + Path.element (Shape.arc { datum | innerRadius = radius - 60 }) + [ fill <| Fill <| getColor index ] + in + g [ transform [ Translate (3 * radius + 20) radius ] ] + [ g [] <| List.indexedMap makeSlice pieData + ] + + +viewPieChartLegend : Language -> (a -> TranslationId) -> (a -> Color) -> List ( a, Int ) -> Html Msg +viewPieChartLegend language translateFunc colorFunc signs = let totalSigns = - signs - |> List.map Tuple.second - |> List.foldl (+) 0 + List.map Tuple.second signs + |> List.sum |> toFloat in div [ class "legend" ] @@ -1741,7 +2074,7 @@ viewFamilyPlanningChartLegend language signs = (\( sign, usage ) -> let label = - translate language <| Translate.FamilyPlanningSignLabel sign + translate language <| translateFunc sign percentage = round (100 * toFloat usage / totalSigns) @@ -1756,7 +2089,7 @@ viewFamilyPlanningChartLegend language signs = in div [ class "legend-item" ] [ svg [ Svg.Attributes.width "12", Svg.Attributes.height "12", viewBox 0 0 100 100 ] - [ Svg.circle [ cx "50", cy "50", r "40", fill <| Fill <| familyPlanningSignToColor sign ] [] + [ Svg.circle [ cx "50", cy "50", r "40", fill <| Fill <| colorFunc sign ] [] ] , span [] [ text <| label ++ " (" ++ normalizedPercentage ++ "%)" ] ] @@ -1765,30 +2098,6 @@ viewFamilyPlanningChartLegend language signs = ) -viewChart : List ( FamilyPlanningSign, Int ) -> Svg msg -viewChart signs = - let - arcs = - signs - |> List.map (Tuple.second >> toFloat) - - signsList = - signs - |> List.map Tuple.first - - pieData = - arcs - |> Shape.pie - { defaultPieConfig - | outerRadius = radius - , padAngle = 0 - , cornerRadius = 0 - } - in - svg [ Explicit.class [ "pie-chart" ], viewBox 0 0 pieChartWidth pieChartHeight ] - [ annular signsList pieData ] - - viewCustomModal : Language -> Bool -> Nurse -> DashboardStats -> ModelIndexedDb -> Model -> Html Msg viewCustomModal language isChw nurse stats db model = model.modalState @@ -2126,24 +2435,6 @@ getFamilyPlanningSignsCounter stats = stats.familyPlanning -annular : List FamilyPlanningSign -> List Arc -> Svg msg -annular signsList arcs = - let - getColor index = - List.Extra.getAt index signsList - |> Maybe.withDefault NoFamilyPlanning - |> (\sign -> Dict.get sign colors) - |> Maybe.withDefault Color.black - - makeSlice index datum = - Path.element (Shape.arc { datum | innerRadius = radius - 60 }) - [ fill <| Fill <| getColor index ] - in - g [ transform [ Translate (3 * radius + 20) radius ] ] - [ g [] <| List.indexedMap makeSlice arcs - ] - - withinThreePreviousMonths : Int -> Int -> Bool withinThreePreviousMonths currentMonth monthNumber = if monthNumber == 13 then @@ -2173,3 +2464,37 @@ resolvePreviousMonth thisMonth = else thisMonth - 1 + + +monthSelector : Language -> NominalDate -> Model -> Html Msg +monthSelector language selectedDate model = + let + monthNumber = + Date.monthNumber selectedDate + + month = + Date.numberToMonth monthNumber + + year = + Date.year selectedDate + in + div [ class "month-selector" ] + [ span + [ classList + [ ( "icon-back", True ) + , ( "hidden", model.monthGap == maxMonthGap ) + ] + , onClick <| ChangeMonthGap 1 + ] + [] + , span [ class "label" ] + [ text <| translate language (Translate.ResolveMonth False month) ++ " " ++ String.fromInt year ] + , span + [ classList + [ ( "icon-back rotate-180", True ) + , ( "hidden", model.monthGap == 0 ) + ] + , onClick <| ChangeMonthGap -1 + ] + [] + ] diff --git a/client/src/elm/Pages/DemographicsReport/Fetch.elm b/client/src/elm/Pages/DemographicsReport/Fetch.elm index bb21b68430..9d72615e9d 100644 --- a/client/src/elm/Pages/DemographicsReport/Fetch.elm +++ b/client/src/elm/Pages/DemographicsReport/Fetch.elm @@ -4,6 +4,7 @@ import AssocList as Dict import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) import Backend.Relationship.Model exposing (MyRelatedBy(..)) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -38,7 +39,7 @@ fetch id db = ) |> Maybe.withDefault [] in - List.filterMap identity <| + Maybe.Extra.values <| ([ Just <| FetchHealthCenters , Just <| FetchPrenatalEncounter id , Maybe.map FetchIndividualEncounterParticipant participantId diff --git a/client/src/elm/Pages/Device/View.elm b/client/src/elm/Pages/Device/View.elm index 216845b0a8..0eb52cbf52 100644 --- a/client/src/elm/Pages/Device/View.elm +++ b/client/src/elm/Pages/Device/View.elm @@ -14,6 +14,7 @@ import Html.Attributes exposing (..) import Html.Events exposing (..) import List.Extra import List.Zipper as Zipper +import Maybe.Extra import Pages.Device.Model exposing (..) import Pages.Page exposing (Page(..)) import RemoteData exposing (RemoteData(..), WebData) @@ -92,7 +93,7 @@ viewStorageStatus language app = , Maybe.map viewPersistent app.persistentStorage , Maybe.map viewMemoryQuota app.memoryQuota ] - |> List.filterMap identity + |> Maybe.Extra.values |> ul [ class "storage-dashboard" ] diff --git a/client/src/elm/Pages/GlobalCaseManagement/Model.elm b/client/src/elm/Pages/GlobalCaseManagement/Model.elm index f5d0d5e0b6..3366d9ecce 100644 --- a/client/src/elm/Pages/GlobalCaseManagement/Model.elm +++ b/client/src/elm/Pages/GlobalCaseManagement/Model.elm @@ -1,6 +1,7 @@ module Pages.GlobalCaseManagement.Model exposing (..) import AssocList exposing (Dict) +import Backend.AcuteIllnessEncounter.Model exposing (AcuteIllnessDiagnosis) import Backend.Entities exposing (..) import Backend.IndividualEncounterParticipant.Model exposing (IndividualEncounterType) import Backend.Measurement.Model exposing (FollowUpOption(..), FollowUpValue, NutritionAssesment, PrenatalFollowUpValue) @@ -38,6 +39,12 @@ type alias NutritionFollowUpItem = } +type alias NutritionFollowUpEntry = + { personId : PersonId + , item : NutritionFollowUpItem + } + + type alias AcuteIllnessFollowUpItem = { dateMeasured : NominalDate , personName : String @@ -51,6 +58,15 @@ type alias AcuteIllnessFollowUpItem = } +type alias AcuteIllnessFollowUpEntry = + { participantId : IndividualEncounterParticipantId + , personId : PersonId + , item : AcuteIllnessFollowUpItem + , newEncounterSequenceNumber : Int + , diagnosis : AcuteIllnessDiagnosis + } + + type alias PrenatalFollowUpItem = { dateMeasured : NominalDate , personName : String @@ -59,6 +75,15 @@ type alias PrenatalFollowUpItem = } +type alias PrenatalFollowUpEntry = + { participantId : IndividualEncounterParticipantId + , personId : PersonId + , item : PrenatalFollowUpItem + , encounterType : PrenatalEncounterType + , hasNurseEncounter : Bool + } + + type FollowUpEncounterDataType = FollowUpNutrition FollowUpNutritionData | FollowUpAcuteIllness FollowUpAcuteIllnessData diff --git a/client/src/elm/Pages/GlobalCaseManagement/View.elm b/client/src/elm/Pages/GlobalCaseManagement/View.elm index 9694bbd5b9..7c53804078 100644 --- a/client/src/elm/Pages/GlobalCaseManagement/View.elm +++ b/client/src/elm/Pages/GlobalCaseManagement/View.elm @@ -1,4 +1,4 @@ -module Pages.GlobalCaseManagement.View exposing (view) +module Pages.GlobalCaseManagement.View exposing (generateAcuteIllnessFollowUpEntries, generateNutritionFollowUpEntries, generatePrenatalFollowUpEntries, view) import AssocList as Dict exposing (Dict) import Backend.AcuteIllnessEncounter.Model exposing (AcuteIllnessDiagnosis(..)) @@ -250,18 +250,29 @@ viewFilters language model = List.map renderButton filters +viewItemHeading : Language -> IndividualEncounterType -> Html Msg +viewItemHeading language encounterType = + div [ class "pane-heading" ] + [ text <| translate language <| Translate.EncounterTypeFollowUpLabel encounterType ] + + viewNutritionPane : Language -> NominalDate -> Dict PersonId NutritionFollowUpItem -> ModelIndexedDb -> Model -> Html Msg viewNutritionPane language currentDate itemsDict db model = let + limitDate = + -- Set limit date for tomorrow, so that we + -- load all available follow ups. + Date.add Days 1 currentDate + entries = - Dict.map (viewNutritionFollowUpItem language currentDate db) itemsDict + generateNutritionFollowUpEntries language currentDate limitDate itemsDict db content = - if Dict.isEmpty entries then + if List.isEmpty entries then [ translateText language Translate.NoMatchesFound ] else - Dict.values entries + List.map (viewNutritionFollowUpEntry language currentDate) entries in div [ class "pane" ] [ viewItemHeading language NutritionEncounter @@ -269,14 +280,15 @@ viewNutritionPane language currentDate itemsDict db model = ] -viewItemHeading : Language -> IndividualEncounterType -> Html Msg -viewItemHeading language encounterType = - div [ class "pane-heading" ] - [ text <| translate language <| Translate.EncounterTypeFollowUpLabel encounterType ] +generateNutritionFollowUpEntries : Language -> NominalDate -> NominalDate -> Dict PersonId NutritionFollowUpItem -> ModelIndexedDb -> List NutritionFollowUpEntry +generateNutritionFollowUpEntries language currentDate limitDate itemsDict db = + Dict.map (generateNutritionFollowUpEntryData language currentDate limitDate db) itemsDict + |> Dict.values + |> Maybe.Extra.values -viewNutritionFollowUpItem : Language -> NominalDate -> ModelIndexedDb -> PersonId -> NutritionFollowUpItem -> Html Msg -viewNutritionFollowUpItem language currentDate db personId item = +generateNutritionFollowUpEntryData : Language -> NominalDate -> NominalDate -> ModelIndexedDb -> PersonId -> NutritionFollowUpItem -> Maybe NutritionFollowUpEntry +generateNutritionFollowUpEntryData language currentDate limitDate db personId item = let lastHomeVisitEncounter = resolveIndividualParticipantForPerson personId HomeVisitEncounter db @@ -284,7 +296,10 @@ viewNutritionFollowUpItem language currentDate db personId item = (\participantId -> Dict.get participantId db.homeVisitEncountersByParticipant |> Maybe.andThen RemoteData.toMaybe - |> Maybe.map Dict.values + |> Maybe.map + (Dict.values + >> List.filter (\encounter -> Date.compare encounter.startDate limitDate == LT) + ) |> Maybe.withDefault [] ) |> Maybe.withDefault [] @@ -297,18 +312,22 @@ viewNutritionFollowUpItem language currentDate db personId item = (\encounter -> -- Last Home Visitit encounter occurred before follow up was scheduled. if Date.compare encounter.startDate item.dateMeasured == LT then - viewNutritionFollowUpEntry language currentDate personId item + Just <| NutritionFollowUpEntry personId item else - emptyNode + Nothing ) |> -- No Home Visitit encounter found. - Maybe.withDefault (viewNutritionFollowUpEntry language currentDate personId item) + Maybe.withDefault + (Just <| NutritionFollowUpEntry personId item) -viewNutritionFollowUpEntry : Language -> NominalDate -> PersonId -> NutritionFollowUpItem -> Html Msg -viewNutritionFollowUpEntry language currentDate personId item = +viewNutritionFollowUpEntry : Language -> NominalDate -> NutritionFollowUpEntry -> Html Msg +viewNutritionFollowUpEntry language currentDate entry = let + item = + entry.item + dueOption = followUpDueOptionByDate currentDate item.dateMeasured item.value.options @@ -331,7 +350,7 @@ viewNutritionFollowUpEntry language currentDate personId item = text <| translate language <| Translate.NutritionAssesment assessment popupData = - FollowUpNutrition <| FollowUpNutritionData personId item.personName + FollowUpNutrition <| FollowUpNutritionData entry.personId item.personName in viewFollowUpEntry language dueOption item.personName popupData assessments @@ -366,17 +385,20 @@ viewAcuteIllnessPane : -> Html Msg viewAcuteIllnessPane language currentDate itemsDict db model = let + limitDate = + -- Set limit date for tomorrow, so that we + -- load all available follow ups. + Date.add Days 1 currentDate + entries = - Dict.map (viewAcuteIllnessFollowUpItem language currentDate db) itemsDict - |> Dict.values - |> List.filterMap identity + generateAcuteIllnessFollowUpEntries language currentDate limitDate itemsDict db content = if List.isEmpty entries then [ translateText language Translate.NoMatchesFound ] else - entries + List.map (viewAcuteIllnessFollowUpEntry language currentDate) entries in div [ class "pane" ] [ viewItemHeading language AcuteIllnessEncounter @@ -385,16 +407,37 @@ viewAcuteIllnessPane language currentDate itemsDict db model = ] -viewAcuteIllnessFollowUpItem : Language -> NominalDate -> ModelIndexedDb -> ( IndividualEncounterParticipantId, PersonId ) -> AcuteIllnessFollowUpItem -> Maybe (Html Msg) -viewAcuteIllnessFollowUpItem language currentDate db ( participantId, personId ) item = +generateAcuteIllnessFollowUpEntries : + Language + -> NominalDate + -> NominalDate + -> Dict ( IndividualEncounterParticipantId, PersonId ) AcuteIllnessFollowUpItem + -> ModelIndexedDb + -> List AcuteIllnessFollowUpEntry +generateAcuteIllnessFollowUpEntries language currentDate limitDate itemsDict db = + Dict.map (generateAcuteIllnessFollowUpEntryData language currentDate limitDate db) itemsDict + |> Dict.values + |> Maybe.Extra.values + + +generateAcuteIllnessFollowUpEntryData : + Language + -> NominalDate + -> NominalDate + -> ModelIndexedDb + -> ( IndividualEncounterParticipantId, PersonId ) + -> AcuteIllnessFollowUpItem + -> Maybe AcuteIllnessFollowUpEntry +generateAcuteIllnessFollowUpEntryData language currentDate limitDate db ( participantId, personId ) item = let - outcome = + dateConcludedCriteria = Dict.get participantId db.individualParticipants |> Maybe.andThen RemoteData.toMaybe - |> Maybe.andThen .outcome + |> Maybe.andThen .dateConcluded + |> Maybe.map (\dateConcluded -> Date.compare dateConcluded limitDate) in - if isJust outcome then - -- Illness was concluded, so we do not need to follow up on it. + if dateConcludedCriteria == Just LT then + -- Illness was concluded before limit date, so we do not need to follow up on it. Nothing else @@ -402,7 +445,10 @@ viewAcuteIllnessFollowUpItem language currentDate db ( participantId, personId ) allEncountersWithIds = Dict.get participantId db.acuteIllnessEncountersByParticipant |> Maybe.andThen RemoteData.toMaybe - |> Maybe.map Dict.toList + |> Maybe.map + (Dict.toList + >> List.filter (\( _, encounter ) -> Date.compare encounter.startDate limitDate == LT) + ) |> Maybe.withDefault [] -- Sort DESC, by date and sequence number. |> List.sortWith (\( _, e1 ) ( _, e2 ) -> compareAcuteIllnessEncounterDataDesc e1 e2) @@ -439,7 +485,7 @@ viewAcuteIllnessFollowUpItem language currentDate db ( participantId, personId ) |> Maybe.withDefault 1 in diagnosis - |> Maybe.map (viewAcuteIllnessFollowUpEntry language currentDate ( participantId, personId ) item encounterSequenceNumber) + |> Maybe.map (AcuteIllnessFollowUpEntry participantId personId item encounterSequenceNumber) else Nothing @@ -449,21 +495,21 @@ viewAcuteIllnessFollowUpItem language currentDate db ( participantId, personId ) viewAcuteIllnessFollowUpEntry : Language -> NominalDate - -> ( IndividualEncounterParticipantId, PersonId ) - -> AcuteIllnessFollowUpItem - -> Int - -> AcuteIllnessDiagnosis + -> AcuteIllnessFollowUpEntry -> Html Msg -viewAcuteIllnessFollowUpEntry language currentDate ( participantId, personId ) item sequenceNumber diagnosis = +viewAcuteIllnessFollowUpEntry language currentDate entry = let + item = + entry.item + dueOption = followUpDueOptionByDate currentDate item.dateMeasured item.value assessment = - [ p [] [ text <| translate language <| Translate.AcuteIllnessDiagnosis diagnosis ] ] + [ p [] [ text <| translate language <| Translate.AcuteIllnessDiagnosis entry.diagnosis ] ] popupData = - FollowUpAcuteIllness <| FollowUpAcuteIllnessData personId item.personName participantId sequenceNumber + FollowUpAcuteIllness <| FollowUpAcuteIllnessData entry.personId item.personName entry.participantId entry.newEncounterSequenceNumber in viewFollowUpEntry language dueOption item.personName popupData assessment @@ -477,17 +523,20 @@ viewPrenatalPane : -> Html Msg viewPrenatalPane language currentDate itemsDict db model = let + limitDate = + -- Set limit date for tomorrow, so that we + -- load all available follow ups. + Date.add Days 1 currentDate + entries = - Dict.map (viewPrenatalFollowUpItem language currentDate db) itemsDict - |> Dict.values - |> List.filterMap identity + generatePrenatalFollowUpEntries language currentDate limitDate itemsDict db content = if List.isEmpty entries then [ translateText language Translate.NoMatchesFound ] else - entries + List.map (viewPrenatalFollowUpEntry language currentDate) entries in div [ class "pane" ] [ viewItemHeading language AntenatalEncounter @@ -496,16 +545,37 @@ viewPrenatalPane language currentDate itemsDict db model = ] -viewPrenatalFollowUpItem : Language -> NominalDate -> ModelIndexedDb -> ( IndividualEncounterParticipantId, PersonId ) -> PrenatalFollowUpItem -> Maybe (Html Msg) -viewPrenatalFollowUpItem language currentDate db ( participantId, personId ) item = +generatePrenatalFollowUpEntries : + Language + -> NominalDate + -> NominalDate + -> Dict ( IndividualEncounterParticipantId, PersonId ) PrenatalFollowUpItem + -> ModelIndexedDb + -> List PrenatalFollowUpEntry +generatePrenatalFollowUpEntries language currentDate limitDate itemsDict db = + Dict.map (generatePrenatalFollowUpEntryData language currentDate limitDate db) itemsDict + |> Dict.values + |> Maybe.Extra.values + + +generatePrenatalFollowUpEntryData : + Language + -> NominalDate + -> NominalDate + -> ModelIndexedDb + -> ( IndividualEncounterParticipantId, PersonId ) + -> PrenatalFollowUpItem + -> Maybe PrenatalFollowUpEntry +generatePrenatalFollowUpEntryData language currentDate limitDate db ( participantId, personId ) item = let - outcome = + dateConcludedCriteria = Dict.get participantId db.individualParticipants |> Maybe.andThen RemoteData.toMaybe - |> Maybe.andThen .outcome + |> Maybe.andThen .dateConcluded + |> Maybe.map (\dateConcluded -> Date.compare dateConcluded limitDate) in - if isJust outcome then - -- Pregnancy was concluded, so we do not need to follow up on it. + if dateConcludedCriteria == Just LT then + -- Pregnancy was concluded before limit date, so we do not need to follow up on it. Nothing else @@ -513,7 +583,10 @@ viewPrenatalFollowUpItem language currentDate db ( participantId, personId ) ite allEncountersWithIds = Dict.get participantId db.prenatalEncountersByParticipant |> Maybe.andThen RemoteData.toMaybe - |> Maybe.map Dict.toList + |> Maybe.map + (Dict.toList + >> List.filter (\( _, encounter ) -> Date.compare encounter.startDate limitDate == LT) + ) |> Maybe.withDefault [] -- Sort DESC |> List.sortWith (\( _, e1 ) ( _, e2 ) -> Date.compare e2.startDate e1.startDate) @@ -536,9 +609,9 @@ viewPrenatalFollowUpItem language currentDate db ( participantId, personId ) ite Nothing else - viewPrenatalFollowUpEntry language - currentDate - ( participantId, personId ) + PrenatalFollowUpEntry + participantId + personId item encounter.encounterType hasNurseEncounter @@ -551,16 +624,12 @@ viewPrenatalFollowUpItem language currentDate db ( participantId, personId ) ite ) -viewPrenatalFollowUpEntry : - Language - -> NominalDate - -> ( IndividualEncounterParticipantId, PersonId ) - -> PrenatalFollowUpItem - -> PrenatalEncounterType - -> Bool - -> Html Msg -viewPrenatalFollowUpEntry language currentDate ( participantId, personId ) item encounterType hasNurseEncounter = +viewPrenatalFollowUpEntry : Language -> NominalDate -> PrenatalFollowUpEntry -> Html Msg +viewPrenatalFollowUpEntry language currentDate entry = let + item = + entry.item + dueOption = followUpDueOptionByDate currentDate item.dateMeasured item.value.options @@ -570,11 +639,11 @@ viewPrenatalFollowUpEntry language currentDate ( participantId, personId ) item popupData = FollowUpPrenatal <| FollowUpPrenatalData - personId + entry.personId item.personName - participantId - encounterType - hasNurseEncounter + entry.participantId + entry.encounterType + entry.hasNurseEncounter item.dateMeasured in viewFollowUpEntry language dueOption item.personName popupData assessment diff --git a/client/src/elm/Pages/HomeVisitActivity/Fetch.elm b/client/src/elm/Pages/HomeVisitActivity/Fetch.elm index 3ad0d69e33..0129ad2bc1 100644 --- a/client/src/elm/Pages/HomeVisitActivity/Fetch.elm +++ b/client/src/elm/Pages/HomeVisitActivity/Fetch.elm @@ -3,6 +3,7 @@ module Pages.HomeVisitActivity.Fetch exposing (fetch) import AssocList as Dict import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb) +import Maybe.Extra import Pages.HomeVisitEncounter.Fetch import RemoteData exposing (RemoteData(..)) @@ -26,5 +27,5 @@ fetch id db = Pages.HomeVisitEncounter.Fetch.fetch id db ++ -- We pull data of all Group measuments, to be able to -- determine latest weight measurement that was taken for child. - List.filterMap identity + Maybe.Extra.values [ Maybe.map Backend.Model.FetchChildMeasurements personId ] diff --git a/client/src/elm/Pages/HomeVisitEncounter/Fetch.elm b/client/src/elm/Pages/HomeVisitEncounter/Fetch.elm index 4225e07562..bfac81fb7b 100644 --- a/client/src/elm/Pages/HomeVisitEncounter/Fetch.elm +++ b/client/src/elm/Pages/HomeVisitEncounter/Fetch.elm @@ -5,6 +5,7 @@ import Backend.Entities exposing (..) import Backend.IndividualEncounterParticipant.Model exposing (IndividualEncounterType(..)) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) import Backend.Utils exposing (resolveIndividualParticipantForPerson) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -65,7 +66,7 @@ fetch id db = nutritionEncountersIds |> List.map FetchNutritionMeasurements in - List.filterMap identity + Maybe.Extra.values [ Maybe.map FetchIndividualEncounterParticipant participantId , Maybe.map FetchPerson personId , Maybe.map FetchHomeVisitEncountersForParticipant participantId diff --git a/client/src/elm/Pages/NutritionActivity/Fetch.elm b/client/src/elm/Pages/NutritionActivity/Fetch.elm index f11425c398..855523ee6b 100644 --- a/client/src/elm/Pages/NutritionActivity/Fetch.elm +++ b/client/src/elm/Pages/NutritionActivity/Fetch.elm @@ -3,6 +3,7 @@ module Pages.NutritionActivity.Fetch exposing (fetch) import AssocList as Dict import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb) +import Maybe.Extra import Pages.NutritionEncounter.Fetch import RemoteData exposing (RemoteData(..)) @@ -24,5 +25,5 @@ fetch id db = |> Maybe.map .person in Pages.NutritionEncounter.Fetch.fetch id db - ++ List.filterMap identity + ++ Maybe.Extra.values [ Maybe.map Backend.Model.FetchChildMeasurements personId ] diff --git a/client/src/elm/Pages/NutritionEncounter/Fetch.elm b/client/src/elm/Pages/NutritionEncounter/Fetch.elm index b7a3652fd3..95971c854e 100644 --- a/client/src/elm/Pages/NutritionEncounter/Fetch.elm +++ b/client/src/elm/Pages/NutritionEncounter/Fetch.elm @@ -3,6 +3,7 @@ module Pages.NutritionEncounter.Fetch exposing (fetch) import AssocList as Dict import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -38,7 +39,7 @@ fetch id db = encountersIds |> List.map FetchNutritionMeasurements in - List.filterMap identity + Maybe.Extra.values [ Maybe.map FetchIndividualEncounterParticipant participantId , Maybe.map FetchPerson personId , Maybe.map FetchNutritionEncountersForParticipant participantId diff --git a/client/src/elm/Pages/Page.elm b/client/src/elm/Pages/Page.elm index b7f3645650..763c3c0ce0 100644 --- a/client/src/elm/Pages/Page.elm +++ b/client/src/elm/Pages/Page.elm @@ -1,4 +1,4 @@ -module Pages.Page exposing (DashboardPage(..), Page(..), SessionPage(..), UserPage(..)) +module Pages.Page exposing (AcuteIllnessDashboardPage(..), ChwDashboardPage(..), DashboardPage(..), NurseDashboardPage(..), Page(..), SessionPage(..), UserPage(..)) {-| A module that defines a type which controls what the user wishes to be shown at the moment. @@ -172,10 +172,28 @@ type UserPage -} type DashboardPage = MainPage - | StatsPage + | NursePage NurseDashboardPage + | ChwPage ChwDashboardPage + + +type NurseDashboardPage + = StatsPage | CaseManagementPage +type ChwDashboardPage + = AcuteIllnessPage AcuteIllnessDashboardPage + | NutritionPage + | AntenatalPage + + +type AcuteIllnessDashboardPage + = OverviewPage + | Covid19Page + | MalariaPage + | GastroPage + + {-| We group together the pages that can only be viewed with an EditableSession ... it makes function signatures nicer, since we can specify require a `SessionPage` with an `EditableSession`. There is also some markup which is relevant just to these, diff --git a/client/src/elm/Pages/PageNotFound/View.elm b/client/src/elm/Pages/PageNotFound/View.elm index 83bf37c372..ed53fedbd4 100644 --- a/client/src/elm/Pages/PageNotFound/View.elm +++ b/client/src/elm/Pages/PageNotFound/View.elm @@ -14,8 +14,7 @@ view : Language -> String -> Html Msg view language url = div [ class "wrap wrap-alt-2" ] - [ div - [ class "ui segment center aligned" ] + [ div [ class "ui segment center aligned" ] [ h2 [] [ text <| translate language Trans.PageNotFoundMsg ] , h4 [] [ text url ] , button diff --git a/client/src/elm/Pages/PinCode/View.elm b/client/src/elm/Pages/PinCode/View.elm index ae509a958d..506f3f9be4 100644 --- a/client/src/elm/Pages/PinCode/View.elm +++ b/client/src/elm/Pages/PinCode/View.elm @@ -12,7 +12,7 @@ import Gizra.Html exposing (emptyNode, showIf) import Html exposing (..) import Html.Attributes exposing (..) import Html.Events exposing (onClick, onInput, onSubmit) -import Pages.Page exposing (DashboardPage(..), Page(..), UserPage(..)) +import Pages.Page exposing (DashboardPage(..), NurseDashboardPage(..), Page(..), UserPage(..)) import Pages.PinCode.Model exposing (..) import RemoteData exposing (RemoteData(..), WebData) import Translate exposing (Language, translate) diff --git a/client/src/elm/Pages/PregnancyOutcome/Fetch.elm b/client/src/elm/Pages/PregnancyOutcome/Fetch.elm index b12e5bde21..eefe1f43a0 100644 --- a/client/src/elm/Pages/PregnancyOutcome/Fetch.elm +++ b/client/src/elm/Pages/PregnancyOutcome/Fetch.elm @@ -3,6 +3,7 @@ module Pages.PregnancyOutcome.Fetch exposing (fetch) import AssocList as Dict import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -32,7 +33,7 @@ fetch participantId db = encountersIds |> List.map FetchPrenatalMeasurements in - List.filterMap identity + Maybe.Extra.values [ Maybe.map FetchPerson personId , Maybe.map FetchPrenatalEncounter lastEncounterId ] diff --git a/client/src/elm/Pages/PrenatalEncounter/Fetch.elm b/client/src/elm/Pages/PrenatalEncounter/Fetch.elm index 10ea625403..81b3f66d35 100644 --- a/client/src/elm/Pages/PrenatalEncounter/Fetch.elm +++ b/client/src/elm/Pages/PrenatalEncounter/Fetch.elm @@ -3,6 +3,7 @@ module Pages.PrenatalEncounter.Fetch exposing (fetch) import AssocList as Dict import Backend.Entities exposing (..) import Backend.Model exposing (ModelIndexedDb, MsgIndexedDb(..)) +import Maybe.Extra import RemoteData exposing (RemoteData(..)) @@ -39,7 +40,7 @@ fetch id db = encountersIds |> List.map FetchPrenatalMeasurements in - List.filterMap identity + Maybe.Extra.values [ Maybe.map FetchIndividualEncounterParticipant participantId , Maybe.map FetchPerson personId , Maybe.map FetchPrenatalEncountersForParticipant participantId diff --git a/client/src/elm/Pages/PrenatalEncounter/Utils.elm b/client/src/elm/Pages/PrenatalEncounter/Utils.elm index f66dd855fc..08e87a1c1a 100644 --- a/client/src/elm/Pages/PrenatalEncounter/Utils.elm +++ b/client/src/elm/Pages/PrenatalEncounter/Utils.elm @@ -389,7 +389,7 @@ activityCompleted currentDate data activity = False PregnancyOutcome -> - isJust data.participant.endDate + isJust data.participant.dateConcluded resolveNextStepsTasks : NominalDate -> AssembledData -> List NextStepsTask diff --git a/client/src/elm/Pages/PrenatalParticipant/Utils.elm b/client/src/elm/Pages/PrenatalParticipant/Utils.elm index 7b2499bb14..a76101e822 100644 --- a/client/src/elm/Pages/PrenatalParticipant/Utils.elm +++ b/client/src/elm/Pages/PrenatalParticipant/Utils.elm @@ -7,12 +7,12 @@ import Maybe.Extra exposing (isJust) {-| Preganancy is considered 'active' if it does not have it's end -date set, and it's EDD date is not set, or, EDD date is less than +date and outcome set, or it's EDD date is not set, or, EDD date is less than 3 month overdue. -} isPregnancyActive : NominalDate -> IndividualEncounterParticipant -> Bool isPregnancyActive currentDate session = - if isJust session.endDate then + if isJust session.endDate && isJust session.outcome then False else diff --git a/client/src/elm/Pages/Router.elm b/client/src/elm/Pages/Router.elm index f8ac841aa3..089f94d3cd 100644 --- a/client/src/elm/Pages/Router.elm +++ b/client/src/elm/Pages/Router.elm @@ -67,11 +67,35 @@ pageToFragment current = MainPage -> "main" - StatsPage -> - "stats" + NursePage nurseDashboardPage -> + case nurseDashboardPage of + StatsPage -> + "stats" - CaseManagementPage -> - "case-management" + CaseManagementPage -> + "case-management" + + ChwPage chwDashboardPage -> + case chwDashboardPage of + AcuteIllnessPage acuteIllnessSubPage -> + case acuteIllnessSubPage of + OverviewPage -> + "acute-illness" + + Covid19Page -> + "covid-19" + + MalariaPage -> + "malaria" + + GastroPage -> + "gastro" + + NutritionPage -> + "nutrition" + + AntenatalPage -> + "antenatal" in Just ("dashboard/" ++ url) @@ -272,8 +296,14 @@ parseDashboardPage : Parser (DashboardPage -> c) c parseDashboardPage = oneOf [ map MainPage (s "main") - , map StatsPage (s "stats") - , map CaseManagementPage (s "case-management") + , map (NursePage StatsPage) (s "stats") + , map (NursePage CaseManagementPage) (s "case-management") + , map (ChwPage <| AcuteIllnessPage OverviewPage) (s "acute-illness") + , map (ChwPage <| AcuteIllnessPage Covid19Page) (s "covid-19") + , map (ChwPage <| AcuteIllnessPage MalariaPage) (s "malaria") + , map (ChwPage <| AcuteIllnessPage GastroPage) (s "gastro") + , map (ChwPage NutritionPage) (s "nutrition") + , map (ChwPage AntenatalPage) (s "antenatal") ] diff --git a/client/src/elm/Pages/Session/Update.elm b/client/src/elm/Pages/Session/Update.elm index 3114671f43..c83c978c7c 100644 --- a/client/src/elm/Pages/Session/Update.elm +++ b/client/src/elm/Pages/Session/Update.elm @@ -88,7 +88,7 @@ updateFoundSession currentDate zscores sessionId session db msg model = (\childId -> [ Maybe.map (Backend.Session.Model.MeasurementOutMsgChild childId) updateReturns.outMsg ] - |> List.filterMap identity + |> Maybe.Extra.values |> List.map (App.Model.MsgIndexedDb << Backend.Model.MsgSession sessionId) ) |> Maybe.withDefault [] @@ -138,7 +138,7 @@ updateFoundSession currentDate zscores sessionId session db msg model = (\motherId -> [ Maybe.map (Backend.Session.Model.MeasurementOutMsgMother motherId) updateReturns.outMsg ] - |> List.filterMap identity + |> Maybe.Extra.values |> List.map (App.Model.MsgIndexedDb << Backend.Model.MsgSession sessionId) ) |> Maybe.withDefault [] diff --git a/client/src/elm/Restful/Endpoint.elm b/client/src/elm/Restful/Endpoint.elm index 80cc4be6fd..98ff6c9758 100644 --- a/client/src/elm/Restful/Endpoint.elm +++ b/client/src/elm/Restful/Endpoint.elm @@ -80,6 +80,7 @@ import Http exposing (Error(..), expectJson) import HttpBuilder exposing (..) import Json.Decode as JD exposing (Decoder, field, index, list) import Json.Encode exposing (Value) +import Maybe.Extra import Task exposing (Task) @@ -836,7 +837,7 @@ withOffsetAndRange backend_ offset range = Maybe.map (\r -> ( backend_.rangeParam, String.fromInt r )) range in [ offsetParam, rangeParam ] - |> List.filterMap identity + |> Maybe.Extra.values |> withQueryParams diff --git a/client/src/elm/Restful/Login.elm b/client/src/elm/Restful/Login.elm index 767baf4d77..463be60d58 100644 --- a/client/src/elm/Restful/Login.elm +++ b/client/src/elm/Restful/Login.elm @@ -181,6 +181,7 @@ import Http exposing (Error(..), expectJson) import HttpBuilder exposing (withExpect, withHeader, withQueryParams) import Json.Decode as JD exposing (Decoder, field) import Json.Encode exposing (Value) +import Maybe.Extra import RemoteData exposing (RemoteData(..), WebData) import Restful.Endpoint exposing (AccessToken, BackendUrl, appendUrl) import Task exposing (Task) @@ -1229,7 +1230,7 @@ encodeCredentials config credentials = Maybe.map (\encoder -> ( "user", encoder credentials.user )) config.encodeUser in [ encodedAccessToken, encodedUser ] - |> List.filterMap identity + |> Maybe.Extra.values |> Json.Encode.object |> Json.Encode.encode 0 diff --git a/client/src/elm/SyncManager/Decoder.elm b/client/src/elm/SyncManager/Decoder.elm index 7d6be19102..e75e8a4c96 100644 --- a/client/src/elm/SyncManager/Decoder.elm +++ b/client/src/elm/SyncManager/Decoder.elm @@ -684,7 +684,7 @@ decodeBackendAuthorityEntity uuidDecoder identifierDecoder = "statistics" -> doDecode - Backend.Dashboard.Decoder.decodeDashboardStats + Backend.Dashboard.Decoder.decodeDashboardStatsRaw BackendAuthorityDashboardStats "symptoms_general" -> @@ -737,6 +737,7 @@ decodeIndexDbSaveResult = succeed IndexDbSaveResult |> required "table" decodeIndexDbSaveResultTable |> required "status" decodeIndexDbSaveStatus + |> required "timestamp" string decodeIndexDbSaveResultTable : Decoder IndexDbSaveResultTable diff --git a/client/src/elm/SyncManager/Model.elm b/client/src/elm/SyncManager/Model.elm index 6d2e59044c..616472f635 100644 --- a/client/src/elm/SyncManager/Model.elm +++ b/client/src/elm/SyncManager/Model.elm @@ -4,7 +4,7 @@ import AssocList exposing (Dict) import Backend.AcuteIllnessEncounter.Model exposing (AcuteIllnessEncounter) import Backend.Clinic.Model exposing (Clinic) import Backend.Counseling.Model exposing (CounselingSchedule, CounselingTopic) -import Backend.Dashboard.Model exposing (DashboardStats) +import Backend.Dashboard.Model exposing (DashboardStatsRaw) import Backend.Entities exposing (HealthCenterId) import Backend.HealthCenter.Model exposing (CatchmentArea, HealthCenter) import Backend.HomeVisitEncounter.Model exposing (HomeVisitEncounter) @@ -65,7 +65,7 @@ type BackendAuthorityEntity | BackendAuthorityCorePhysicalExam (BackendEntity CorePhysicalExam) | BackendAuthorityCounselingSession (BackendEntity CounselingSession) | BackendAuthorityDangerSigns (BackendEntity DangerSigns) - | BackendAuthorityDashboardStats (BackendEntity DashboardStats) + | BackendAuthorityDashboardStats (BackendEntity DashboardStatsRaw) | BackendAuthorityExposure (BackendEntity Exposure) | BackendAuthorityFamilyPlanning (BackendEntity FamilyPlanning) | BackendAuthorityFollowUp (BackendEntity FollowUp) @@ -450,6 +450,7 @@ type UploadPhotoError type alias IndexDbSaveResult = { table : IndexDbSaveResultTable , status : IndexDbSaveStatus + , timestamp : String } @@ -543,6 +544,7 @@ type Msg | RefreshPage | BackendAuthorityFetch | BackendAuthorityFetchHandle (Zipper SyncInfoAuthority) (WebData (DownloadSyncResponse BackendAuthorityEntity)) + | BackendAuthorityFetchedDataSavedHandle String | BackendAuthorityDashboardStatsFetch | BackendAuthorityDashboardStatsFetchHandle (Zipper SyncInfoAuthority) (WebData (DownloadSyncResponse BackendAuthorityEntity)) -- This is the main entry point for the Sync loop. This will dispatch a call @@ -551,6 +553,7 @@ type Msg | BackendFetchPhotos | BackendGeneralFetch | BackendGeneralFetchHandle (WebData (DownloadSyncResponse BackendGeneralEntity)) + | BackendGeneralFetchedDataSavedHandle String -- Fetch a deferred photo from the server. | BackendDeferredPhotoFetch (Maybe IndexDbQueryDeferredPhotoResultRecord) | BackendDeferredPhotoFetchHandle IndexDbQueryDeferredPhotoResultRecord (WebData ()) @@ -561,10 +564,8 @@ type Msg | BackendPhotoUploadAuthority | BackendUploadAuthority (Maybe IndexDbQueryUploadAuthorityResultRecord) | BackendUploadAuthorityHandle IndexDbQueryUploadAuthorityResultRecord (WebData ()) - | BackendAuthorityFetchedDataSavedHandle | BackendUploadGeneral (Maybe IndexDbQueryUploadGeneralResultRecord) | BackendUploadGeneralHandle IndexDbQueryUploadGeneralResultRecord (WebData ()) - | BackendGeneralFetchedDataSavedHandle | BackendUploadPhotoAuthorityHandle (RemoteData UploadPhotoError (Maybe IndexDbQueryUploadPhotoResultRecord)) | BackendReportState Int | BackendReportSyncIncident SyncIncidentType diff --git a/client/src/elm/SyncManager/Update.elm b/client/src/elm/SyncManager/Update.elm index 50c054db57..7cfad6d7a1 100644 --- a/client/src/elm/SyncManager/Update.elm +++ b/client/src/elm/SyncManager/Update.elm @@ -62,6 +62,10 @@ update currentDate currentTime activePage dbVersion device msg model = List.map toRevisionFunc backendEntities |> Backend.Model.HandleRevisions |> App.Model.MsgIndexedDb + + requestTimestamp = + Time.posixToMillis model.downloadRequestTime + |> String.fromInt in case msg of MsgDebouncer subMsg -> @@ -175,7 +179,7 @@ update currentDate currentTime activePage dbVersion device msg model = [] |> List.reverse in - ( sendSyncedDataToIndexDb { table = "Authority", data = dataToSend, shard = currentZipper.uuid } + ( sendSyncedDataToIndexDb { table = "Authority", data = dataToSend, shard = currentZipper.uuid, timestamp = requestTimestamp } , { model | downloadAuthorityResponse = webData } ) @@ -191,94 +195,101 @@ update currentDate currentTime activePage dbVersion device msg model = (maybeHttpError webData "Backend.SyncManager.Update" "BackendAuthorityFetchHandle") [] - BackendAuthorityFetchedDataSavedHandle -> - Maybe.map2 - (\zipper data -> - let - currentZipper = - Zipper.current zipper + BackendAuthorityFetchedDataSavedHandle timestamp -> + if requestTimestamp /= timestamp then + -- Request timestamp does not match. This indicates that timeout + -- has occured, and another request was issued instead. + -- Therefore, we drop this request. + noChange - deferredPhotosCmd = - -- Prepare a list of the photos, so we - -- could grab them in a later time. - let - dataToSend = - data.entities - |> List.foldl - (\entity accum -> - case SyncManager.Utils.getPhotoFromBackendAuthorityEntity entity of - Just photoUrl -> - (entity - |> SyncManager.Utils.getBackendAuthorityEntityIdentifier - |> SyncManager.Encoder.encodeDataForDeferredPhotos photoUrl - ) - :: accum - - Nothing -> - accum - ) - [] - |> List.reverse - in - if List.isEmpty dataToSend then - Cmd.none + else + Maybe.map2 + (\zipper data -> + let + currentZipper = + Zipper.current zipper - else - sendSyncedDataToIndexDb { table = "DeferredPhotos", data = dataToSend, shard = currentZipper.uuid } + deferredPhotosCmd = + -- Prepare a list of the photos, so we + -- could grab them in a later time. + let + dataToSend = + data.entities + |> List.foldl + (\entity accum -> + case SyncManager.Utils.getPhotoFromBackendAuthorityEntity entity of + Just photoUrl -> + (entity + |> SyncManager.Utils.getBackendAuthorityEntityIdentifier + |> SyncManager.Encoder.encodeDataForDeferredPhotos photoUrl + ) + :: accum + + Nothing -> + accum + ) + [] + |> List.reverse + in + if List.isEmpty dataToSend then + Cmd.none + + else + sendSyncedDataToIndexDb { table = "DeferredPhotos", data = dataToSend, shard = currentZipper.uuid, timestamp = "" } - appMsgs = - [ handleNewRevisionsMsg backendAuthorityEntityToRevision data.entities ] + appMsgs = + [ handleNewRevisionsMsg backendAuthorityEntityToRevision data.entities ] - syncInfoAuthorities = - let - status = - if data.revisionCount == 0 then - Success + syncInfoAuthorities = + let + status = + if data.revisionCount == 0 then + Success - else - currentZipper.status + else + currentZipper.status - lastFetchedRevisionId = - data.entities - |> List.sortBy (SyncManager.Utils.getBackendAuthorityEntityIdentifier >> .revision) - |> List.reverse - |> List.head - |> Maybe.map (SyncManager.Utils.getBackendAuthorityEntityIdentifier >> .revision) - |> Maybe.withDefault currentZipper.lastFetchedRevisionId - in - Zipper.mapCurrent - (\old -> - { old - | lastFetchedRevisionId = lastFetchedRevisionId - , lastSuccesfulContact = Time.posixToMillis currentTime - , remainingToDownload = data.revisionCount - , status = status + lastFetchedRevisionId = + data.entities + |> List.sortBy (SyncManager.Utils.getBackendAuthorityEntityIdentifier >> .revision) + |> List.reverse + |> List.head + |> Maybe.map (SyncManager.Utils.getBackendAuthorityEntityIdentifier >> .revision) + |> Maybe.withDefault currentZipper.lastFetchedRevisionId + in + Zipper.mapCurrent + (\old -> + { old + | lastFetchedRevisionId = lastFetchedRevisionId + , lastSuccesfulContact = Time.posixToMillis currentTime + , remainingToDownload = data.revisionCount + , status = status + } + ) + zipper + + modelWithSyncStatus = + SyncManager.Utils.determineSyncStatus activePage + { model + | syncStatus = SyncDownloadAuthority model.downloadAuthorityResponse + , syncInfoAuthorities = Just syncInfoAuthorities } - ) - zipper + in + SubModelReturn + modelWithSyncStatus + (Cmd.batch + [ deferredPhotosCmd - modelWithSyncStatus = - SyncManager.Utils.determineSyncStatus activePage - { model - | syncStatus = SyncDownloadAuthority model.downloadAuthorityResponse - , syncInfoAuthorities = Just syncInfoAuthorities - } - in - SubModelReturn - modelWithSyncStatus - (Cmd.batch - [ deferredPhotosCmd - - -- Send to JS the updated revision ID. We send the entire list. - , sendSyncInfoAuthoritiesCmd syncInfoAuthorities - ] - ) - (maybeHttpError model.downloadAuthorityResponse "Backend.SyncManager.Update" "BackendAuthorityFetchedDataSavedHandle") - appMsgs - ) - model.syncInfoAuthorities - (RemoteData.toMaybe model.downloadAuthorityResponse) - |> Maybe.withDefault noChange + -- Send to JS the updated revision ID. We send the entire list. + , sendSyncInfoAuthoritiesCmd syncInfoAuthorities + ] + ) + (maybeHttpError model.downloadAuthorityResponse "Backend.SyncManager.Update" "BackendAuthorityFetchedDataSavedHandle") + appMsgs + ) + model.syncInfoAuthorities + (RemoteData.toMaybe model.downloadAuthorityResponse) + |> Maybe.withDefault noChange BackendAuthorityDashboardStatsFetch -> case model.syncStatus of @@ -386,7 +397,7 @@ update currentDate currentTime activePage dbVersion device msg model = ) |> Maybe.withDefault currentZipper.statsCacheHash in - ( sendSyncedDataToIndexDb { table = "AuthorityStats", data = dataToSend, shard = currentZipper.uuid } + ( sendSyncedDataToIndexDb { table = "AuthorityStats", data = dataToSend, shard = currentZipper.uuid, timestamp = "" } , cacheHash , [ handleNewRevisionsMsg backendAuthorityEntityToRevision data.entities ] ) @@ -675,7 +686,7 @@ update currentDate currentTime activePage dbVersion device msg model = |> List.foldl (\entity accum -> SyncManager.Utils.getDataToSendGeneral entity accum) [] |> List.reverse in - ( sendSyncedDataToIndexDb { table = "General", data = dataToSend, shard = "" } + ( sendSyncedDataToIndexDb { table = "General", data = dataToSend, shard = "", timestamp = requestTimestamp } , { model | downloadGeneralResponse = webData } ) @@ -691,77 +702,84 @@ update currentDate currentTime activePage dbVersion device msg model = (maybeHttpError webData "Backend.SyncManager.Update" "BackendGeneralFetchHandle") [] - BackendGeneralFetchedDataSavedHandle -> - Maybe.map - (\data -> - let - -- We have successfully saved the entities, so - -- we can delete them fom the `nodeChanges` table. - -- We will do it, by their localId. - deleteLocalIdsCmd = - let - localIds = - List.map (SyncManager.Utils.getBackendGeneralEntityIdentifier >> .uuid) - data.entities - in - if List.isEmpty localIds then - Cmd.none + BackendGeneralFetchedDataSavedHandle timestamp -> + if requestTimestamp /= timestamp then + -- Request timestamp does not match. This indicates that timeout + -- has occured, and another request was issued instead. + -- Therefore, we drop this request. + noChange - else - sendLocalIdsForDelete { type_ = "General", uuid = localIds } + else + Maybe.map + (\data -> + let + -- We have successfully saved the entities, so + -- we can delete them fom the `nodeChanges` table. + -- We will do it, by their localId. + deleteLocalIdsCmd = + let + localIds = + List.map (SyncManager.Utils.getBackendGeneralEntityIdentifier >> .uuid) + data.entities + in + if List.isEmpty localIds then + Cmd.none + + else + sendLocalIdsForDelete { type_ = "General", uuid = localIds } - appMsgs = - [ Backend.Model.ResetFailedToFetchAuthorities |> App.Model.MsgIndexedDb - , handleNewRevisionsMsg backendGeneralEntityToRevision data.entities - ] + appMsgs = + [ Backend.Model.ResetFailedToFetchAuthorities |> App.Model.MsgIndexedDb + , handleNewRevisionsMsg backendGeneralEntityToRevision data.entities + ] - syncInfoGeneral = - let - status = - if data.revisionCount == 0 then - Success + syncInfoGeneral = + let + status = + if data.revisionCount == 0 then + Success - else - model.syncInfoGeneral.status + else + model.syncInfoGeneral.status - lastFetchedRevisionId = - data.entities - |> List.sortBy (SyncManager.Utils.getBackendGeneralEntityIdentifier >> .revision) - |> List.reverse - |> List.head - |> Maybe.map (SyncManager.Utils.getBackendGeneralEntityIdentifier >> .revision) - |> Maybe.withDefault model.syncInfoGeneral.lastFetchedRevisionId - in - model.syncInfoGeneral - |> (\info -> - { info - | lastFetchedRevisionId = lastFetchedRevisionId - , lastSuccesfulContact = Time.posixToMillis currentTime - , remainingToDownload = data.revisionCount - , deviceName = data.deviceName - , status = status - } - ) + lastFetchedRevisionId = + data.entities + |> List.sortBy (SyncManager.Utils.getBackendGeneralEntityIdentifier >> .revision) + |> List.reverse + |> List.head + |> Maybe.map (SyncManager.Utils.getBackendGeneralEntityIdentifier >> .revision) + |> Maybe.withDefault model.syncInfoGeneral.lastFetchedRevisionId + in + model.syncInfoGeneral + |> (\info -> + { info + | lastFetchedRevisionId = lastFetchedRevisionId + , lastSuccesfulContact = Time.posixToMillis currentTime + , remainingToDownload = data.revisionCount + , deviceName = data.deviceName + , status = status + } + ) - modelWithSyncStatus = - SyncManager.Utils.determineSyncStatus activePage - { model - | syncStatus = SyncDownloadGeneral model.downloadGeneralResponse - , syncInfoGeneral = syncInfoGeneral - } - in - SubModelReturn - modelWithSyncStatus - (Cmd.batch - [ deleteLocalIdsCmd - , sendSyncInfoGeneralCmd syncInfoGeneral - ] - ) - (maybeHttpError model.downloadAuthorityResponse "Backend.SyncManager.Update" "BackendGeneralFetchedDataSavedHandle") - appMsgs - ) - (RemoteData.toMaybe model.downloadGeneralResponse) - |> Maybe.withDefault noChange + modelWithSyncStatus = + SyncManager.Utils.determineSyncStatus activePage + { model + | syncStatus = SyncDownloadGeneral model.downloadGeneralResponse + , syncInfoGeneral = syncInfoGeneral + } + in + SubModelReturn + modelWithSyncStatus + (Cmd.batch + [ deleteLocalIdsCmd + , sendSyncInfoGeneralCmd syncInfoGeneral + ] + ) + (maybeHttpError model.downloadAuthorityResponse "Backend.SyncManager.Update" "BackendGeneralFetchedDataSavedHandle") + appMsgs + ) + (RemoteData.toMaybe model.downloadGeneralResponse) + |> Maybe.withDefault noChange SetLastFetchedRevisionIdAuthority zipper revisionId -> let @@ -1645,7 +1663,7 @@ update currentDate currentTime activePage dbVersion device msg model = activePage dbVersion device - BackendAuthorityFetchedDataSavedHandle + (BackendAuthorityFetchedDataSavedHandle indexDbSaveResult.timestamp) model IndexDbSaveResultTableGeneral -> @@ -1655,7 +1673,7 @@ update currentDate currentTime activePage dbVersion device msg model = activePage dbVersion device - BackendGeneralFetchedDataSavedHandle + (BackendGeneralFetchedDataSavedHandle indexDbSaveResult.timestamp) model _ -> @@ -1837,7 +1855,7 @@ subscriptions model = {-| Send to JS data we have synced, e.g. `person`, `health center`, etc. -} -port sendSyncedDataToIndexDb : { table : String, data : List String, shard : String } -> Cmd msg +port sendSyncedDataToIndexDb : { table : String, data : List String, shard : String, timestamp : String } -> Cmd msg {-| Send to JS the information about General sync. diff --git a/client/src/elm/SyncManager/Utils.elm b/client/src/elm/SyncManager/Utils.elm index 2858f0ba4d..1771956c53 100644 --- a/client/src/elm/SyncManager/Utils.elm +++ b/client/src/elm/SyncManager/Utils.elm @@ -858,7 +858,7 @@ encodeBackendAuthorityEntity entity = encode Backend.Measurement.Encoder.encodeDangerSigns identifier BackendAuthorityDashboardStats identifier -> - encode Backend.Dashboard.Encoder.encodeDashboardStats identifier + encode Backend.Dashboard.Encoder.encodeDashboardStatsRaw identifier BackendAuthorityExposure identifier -> encode Backend.Measurement.Encoder.encodeExposure identifier diff --git a/client/src/elm/Translate.elm b/client/src/elm/Translate.elm index 45b63ac535..8633828b8d 100644 --- a/client/src/elm/Translate.elm +++ b/client/src/elm/Translate.elm @@ -78,6 +78,7 @@ import Pages.Dashboard.Model as Dashboard ( BeneficiariesTableLabels(..) , DashboardFilter(..) , DashboardSubFilter(..) + , FeverCause(..) , FilterPeriod(..) , FilterProgramType(..) ) @@ -197,34 +198,57 @@ type Adherence type Dashboard - = BeneficiariesLabel + = AcuteIllnessDiagnosed + | BeneficiariesLabel | BeneficiariesTableColumnLabel BeneficiariesTableLabels | BeneficiariesTableLabel | BoysFilterLabel + | CallsTo114 | CaseManagementFirstWordHelper | CaseManagementHelper | CaseManagementLabel + | ChildrenWhoDied | CompletedProgramLabel + | CommunityLevelCases + | ComplicatedMalariaReferredToHC + | ComplicatedGIInfectionsReferredToHc + | CurrentPregnancies + | DiagnosisUndetermined + | DiagnosedCases | FamilyPlanningLabel | FamilyPlanningOutOfWomen { total : Int, useFamilyPlanning : Int } + | FamilyThatMoved + | FeversByCause + | FeverCause FeverCause + | FeverOfUnknownOrigin | Filter DashboardFilter | FilterProgramType FilterProgramType | Filters | GirlsFilterLabel | GoodNutritionLabel + | HomeDeliveries + | HealthFacilityDeliveries + | HealthCenterReferrals | IncidenceOf | LastUpdated | LoadingDataGeneral | MissedSessionsLabel | Moderate | ModeratelyMalnourished + | MothersInANC | NewBeneficiaries + | NewbornsInCare | NewCasesLabel + | NewCasesPerMonth + | NewPregnancy | NoDataGeneral | NoDataForPeriod + | PatientsManagedAtHome + | PatientCurrentlyUnderCare | PercentageLabel FilterPeriod | PeriodFilter FilterPeriod | ProgramType + | ResolvedCases | Severe | SeverelyMalnourished | StatisticsFirstWordHelper @@ -234,7 +258,13 @@ type Dashboard | TotalBeneficiaries | TotalMalnourished | TotalEncountersLabel + | TotalAssessment + | UncomplicatedMalariaByChws + | UncomplicatedMalariaInPregnancyReferredToHc + | UncomplicatedGIInfectionByCHWS | UseFamilyPlanning + | Within4MonthsOfDueDate + | WithDangerSigns type TranslationId @@ -399,6 +429,7 @@ type TranslationId | CreateGroupEncounter | CreateRelationship | CreateTrainingGroupEncounters + | ChwDashboardLabel | DeleteTrainingGroupEncounters | DashboardLabel | CurrentlyPregnant @@ -442,6 +473,7 @@ type TranslationId | EgaWeeks | EmptyString | EncounterTypeFileterLabel IndividualEncounterType + | EncounterTypePageLabel ChwDashboardPage | EncounterTypeFollowUpQuestion IndividualEncounterType | EncounterTypeFollowUpLabel IndividualEncounterType | EndEncounter @@ -2543,6 +2575,11 @@ translationSet trans = , kinyarwanda = Just "Aratwite" } + ChwDashboardLabel -> + { english = "CHW Snapshot" + , kinyarwanda = Just "Ishusho y'ibyagezweho" + } + DeleteTrainingGroupEncounters -> { english = "Delete All Training Group Encounters" , kinyarwanda = Nothing @@ -2870,6 +2907,40 @@ translationSet trans = , kinyarwanda = Nothing } + EncounterTypePageLabel page -> + case page of + AcuteIllnessPage subPage -> + case subPage of + OverviewPage -> + { english = "Overview" + , kinyarwanda = Just "Ishusho Rusange" + } + + Covid19Page -> + { english = "COVID-19" + , kinyarwanda = Nothing + } + + MalariaPage -> + { english = "Malaria" + , kinyarwanda = Just "Malariya" + } + + GastroPage -> + { english = "Gastro" + , kinyarwanda = Just "Indwara yo mu nda" + } + + NutritionPage -> + { english = "Child Nutrition" + , kinyarwanda = Just "Imirire y'Umwana" + } + + AntenatalPage -> + { english = "Antenatal Care" + , kinyarwanda = Just "Isuzuma ku Mugore Utwite" + } + EncounterTypeFollowUpLabel encounterType -> case encounterType of AcuteIllnessEncounter -> @@ -7820,6 +7891,11 @@ translateDashboard trans = , kinyarwanda = Nothing } + AcuteIllnessDiagnosed -> + { english = "Acute Illness Diagnosed" + , kinyarwanda = Just "Uburwayi bufatiyeho bwasuzumwe" + } + BeneficiariesTableColumnLabel label -> case label of New -> @@ -7852,6 +7928,11 @@ translateDashboard trans = , kinyarwanda = Just "Umuhungu" } + CallsTo114 -> + { english = "Calls to 114" + , kinyarwanda = Just "Inshuro bahamagaye 114" + } + CaseManagementFirstWordHelper -> { english = "Review" , kinyarwanda = Nothing @@ -7867,11 +7948,46 @@ translateDashboard trans = , kinyarwanda = Just "Kuvura Uburwayi" } + ChildrenWhoDied -> + { english = "Children Who Died" + , kinyarwanda = Nothing + } + CompletedProgramLabel -> { english = "Completed Program" , kinyarwanda = Nothing } + CurrentPregnancies -> + { english = "Currently Pregnant Women" + , kinyarwanda = Just "Abagore basanzwe batwite" + } + + CommunityLevelCases -> + { english = "Community Level Cases" + , kinyarwanda = Just "Umubare w'ababonetse ku rwego rw'umudugudu" + } + + ComplicatedMalariaReferredToHC -> + { english = "Complicated Malaria Referred to HC" + , kinyarwanda = Just "Abarwaye Malariya y'ikigatu boherejwe ku Kigo Nderabuzima" + } + + ComplicatedGIInfectionsReferredToHc -> + { english = "Complicated GI Infections Referred to Health Center" + , kinyarwanda = Just "Uburwayi bwo munda bukomeye bwoherejwe ku kigo nderabuzima" + } + + DiagnosisUndetermined -> + { english = "Diagnosis Undetermined" + , kinyarwanda = Just "Uburwayi budasobanutse" + } + + DiagnosedCases -> + { english = "Diagnosed Cases" + , kinyarwanda = Just "Umubare w'indwara zavuwe" + } + FamilyPlanningLabel -> { english = "Family Planning" , kinyarwanda = Nothing @@ -7882,21 +7998,63 @@ translateDashboard trans = , kinyarwanda = Nothing } + FamilyThatMoved -> + { english = "Families Who Moved" + , kinyarwanda = Nothing + } + + FeversByCause -> + { english = "Fevers by Cause" + , kinyarwanda = Just "Impamvu zateye umuriro" + } + + FeverCause cause -> + case cause of + FeverCauseCovid19 -> + { english = "COVID-19" + , kinyarwanda = Nothing + } + + FeverCauseMalaria -> + { english = "Malaria" + , kinyarwanda = Just "Malariya" + } + + FeverCauseRespiratory -> + { english = "Respiratory" + , kinyarwanda = Nothing + } + + FeverCauseGI -> + { english = "Gastrointeritis" + , kinyarwanda = Just "Indwara yo mu nda" + } + + FeverCauseUnknown -> + { english = "Unknown" + , kinyarwanda = Just "Ntibizwi" + } + + FeverOfUnknownOrigin -> + { english = " Fever of Unknown Origin" + , kinyarwanda = Just "Umuriro utazwi icyawuteye" + } + Filter filter -> case filter of Stunting -> { english = "Stunting" - , kinyarwanda = Nothing + , kinyarwanda = Just "Igwingira" } Underweight -> { english = "Underweight" - , kinyarwanda = Nothing + , kinyarwanda = Just "Ibiro bidahagije" } Wasting -> { english = "Wasting" - , kinyarwanda = Nothing + , kinyarwanda = Just "Kunanuka Bikabije" } Dashboard.MUAC -> @@ -7943,7 +8101,7 @@ translateDashboard trans = Filters -> { english = "Filters" - , kinyarwanda = Nothing + , kinyarwanda = Just "Guhitamo" } GirlsFilterLabel -> @@ -7953,17 +8111,32 @@ translateDashboard trans = GoodNutritionLabel -> { english = "% Good nutrition" - , kinyarwanda = Nothing + , kinyarwanda = Just "% Abafite imirire myiza" + } + + HomeDeliveries -> + { english = "Home Deliveries" + , kinyarwanda = Just "Ababyariye mu Rugo" + } + + HealthFacilityDeliveries -> + { english = "Health Facility Deliveries" + , kinyarwanda = Just "Ababyariye ku Ivuriro" + } + + HealthCenterReferrals -> + { english = "Health Center Referrals" + , kinyarwanda = Just "Aboherejwe ku kigo nderabuzima" } IncidenceOf -> { english = "Incidence of" - , kinyarwanda = Nothing + , kinyarwanda = Just "Umubare w'abana bashya bafite" } LastUpdated -> { english = "Last updated" - , kinyarwanda = Nothing + , kinyarwanda = Just "Ivugurura riheruka" } LoadingDataGeneral -> @@ -7986,16 +8159,36 @@ translateDashboard trans = , kinyarwanda = Nothing } + MothersInANC -> + { english = "Mothers in ANC" + , kinyarwanda = Just "Ababyeyi bari muri serivisi ikurikirana abagore batwite" + } + NewCasesLabel -> { english = "New Cases" , kinyarwanda = Nothing } + NewCasesPerMonth -> + { english = "New cases per month" + , kinyarwanda = Just "Abashya bagaragaye mu kwezi" + } + + NewPregnancy -> + { english = "New Identified Pregnancies" + , kinyarwanda = Just "Abagore bashya batwite" + } + NewBeneficiaries -> { english = "New Beneficiaries" , kinyarwanda = Nothing } + NewbornsInCare -> + { english = "Newborns in Care" + , kinyarwanda = Just "Impinja zikurikiranwa" + } + NoDataGeneral -> { english = "No data for this health center." , kinyarwanda = Nothing @@ -8003,14 +8196,24 @@ translateDashboard trans = NoDataForPeriod -> { english = "No data for the selected period." - , kinyarwanda = Nothing + , kinyarwanda = Just "Nta bipimo bigaragara muri iki gihe wahisemo" + } + + PatientsManagedAtHome -> + { english = "Managed at Home" + , kinyarwanda = Just "Abavuriwe mu Rugo" + } + + PatientCurrentlyUnderCare -> + { english = "Currently Under Care" + , kinyarwanda = Just "Abacyitabwaho" } PercentageLabel period -> case period of Dashboard.OneYear -> { english = "from last year" - , kinyarwanda = Nothing + , kinyarwanda = Just "Guhera umwaka ushize" } Dashboard.ThisMonth -> @@ -8055,6 +8258,11 @@ translateDashboard trans = , kinyarwanda = Nothing } + ResolvedCases -> + { english = " Resolved Cases: Currently in Care" + , kinyarwanda = Just "Abavuwe: Bacyitabwaho" + } + Severe -> { english = "Severe" , kinyarwanda = Nothing @@ -8099,7 +8307,7 @@ translateDashboard trans = TotalBeneficiaries -> { english = "Total Beneficiaries" - , kinyarwanda = Nothing + , kinyarwanda = Just "Umubare w'abana bose bafite" } TotalMalnourished -> @@ -8109,7 +8317,27 @@ translateDashboard trans = TotalEncountersLabel -> { english = "Total encounters completed" - , kinyarwanda = Nothing + , kinyarwanda = Just "Ibikorwa byose byarangiye" + } + + TotalAssessment -> + { english = "Total # of Assessments" + , kinyarwanda = Just "Umubare wose w'Amasuzuma Yakozwe" + } + + UncomplicatedMalariaByChws -> + { english = "Uncomplicated Malaria Managed by CHWs" + , kinyarwanda = Just "Abarwaye Malariya yorohejwe yavuwe n'abajyanama b'ubuzima" + } + + UncomplicatedMalariaInPregnancyReferredToHc -> + { english = "Uncomplicated Malaria in Pregnancy Referred to HC" + , kinyarwanda = Just "Ababyeyi batwite bafite Malariya yoroheje boherejwe ku kigo nderabuzima" + } + + UncomplicatedGIInfectionByCHWS -> + { english = "Uncomplicated GI Infections Managed by CHWs" + , kinyarwanda = Just "Uburwayi bwo mu nda bworoheje bwavuwe n'abajyanama w'ubuzima" } UseFamilyPlanning -> @@ -8117,6 +8345,16 @@ translateDashboard trans = , kinyarwanda = Nothing } + Within4MonthsOfDueDate -> + { english = "Within 4 Months of Due Date" + , kinyarwanda = Just "Inda ibura amezi 4 ngo ivuke" + } + + WithDangerSigns -> + { english = "With Danger Signs" + , kinyarwanda = Just "Abafite Ibimenyetso Mpuruza" + } + translateLoginPhrase : LoginPhrase -> TranslationSet String translateLoginPhrase phrase = diff --git a/client/src/elm/Utils/Json.elm b/client/src/elm/Utils/Json.elm index 0e4fcc0bf7..f8999b8295 100644 --- a/client/src/elm/Utils/Json.elm +++ b/client/src/elm/Utils/Json.elm @@ -1,11 +1,4 @@ -module Utils.Json exposing - ( decodeArray2 - , decodeEmptyArrayAsEmptyDict - , decodeError - , decodeEverySet - , decodeNullAsEmptyArray - , encodeIfExists - ) +module Utils.Json exposing (..) import AssocList as Dict exposing (Dict) import Date exposing (Date) @@ -71,3 +64,8 @@ encodeIfExists name maybeVal encoder = maybeVal |> Maybe.map (\val -> [ ( name, encoder val ) ]) |> Maybe.withDefault [] + + +decodeWithFallback : a -> Decoder a -> Decoder a +decodeWithFallback fallback decoder = + oneOf [ decoder, succeed fallback ] diff --git a/client/src/elm/Utils/NominalDate.elm b/client/src/elm/Utils/NominalDate.elm index c6b974bd9d..0946167e4a 100644 --- a/client/src/elm/Utils/NominalDate.elm +++ b/client/src/elm/Utils/NominalDate.elm @@ -10,6 +10,7 @@ import Form.Init exposing (setGroup, setString) import Form.Validate as Validate exposing (Validation, field) import Gizra.NominalDate exposing (NominalDate, NominalDateRange, diffCalendarMonthsAndDays) import Html exposing (Html) +import Maybe.Extra import Translate exposing (Language, translate) @@ -126,14 +127,14 @@ renderAgeMonthsDaysParts language birthDate now = renderAgeMonthsDaysAbbrev : Language -> NominalDate -> NominalDate -> String renderAgeMonthsDaysAbbrev language birthDate now = renderAgeMonthsDaysParts language birthDate now - |> List.filterMap identity + |> Maybe.Extra.values |> String.join " " renderAgeMonthsDaysHtml : Language -> NominalDate -> NominalDate -> List (Html any) renderAgeMonthsDaysHtml language birthDate now = renderAgeMonthsDaysParts language birthDate now - |> List.filterMap identity + |> Maybe.Extra.values |> List.map Html.text |> List.intersperse (Html.br [] []) diff --git a/client/src/elm/ZScore/View.elm b/client/src/elm/ZScore/View.elm index e4d8e719ff..7981646c32 100644 --- a/client/src/elm/ZScore/View.elm +++ b/client/src/elm/ZScore/View.elm @@ -56,6 +56,7 @@ import Backend.Person.Model exposing (Gender(..)) import Float.Extra import Gizra.Html exposing (emptyNode) import Html exposing (Html) +import Maybe.Extra import RemoteData import Round import String exposing (fromInt) @@ -654,7 +655,7 @@ plotReferenceData config zscoreList = , Just <| makeLine (getPoints 2) "two-line-new" , Just <| makeLine (getPoints 3) "three-line-new" ] - |> List.filterMap identity + |> Maybe.Extra.values |> g [] diff --git a/client/src/js/app.js b/client/src/js/app.js index 09f300bae8..98629a642a 100644 --- a/client/src/js/app.js +++ b/client/src/js/app.js @@ -523,18 +523,19 @@ elmApp.ports.sendSyncedDataToIndexDb.subscribe(function(info) { table.bulkPut(entities) .then(function() { - return sendIndexedDbSaveResult('Success', info.table); + return sendIndexedDbSaveResult('Success', info.table, info.timestamp); }).catch(Dexie.BulkError, function (e) { - return sendIndexedDbSaveResult('Failure', info.table); + return sendIndexedDbSaveResult('Failure', info.table, info.timestamp); }); /** * Report that save operation was successful. */ - function sendIndexedDbSaveResult(status, table) { + function sendIndexedDbSaveResult(status, table, timestamp) { const dataForSend = { 'status': status, - 'table': table + 'table': table, + 'timestamp': timestamp } elmApp.ports.savedAtIndexedDb.send(dataForSend); diff --git a/server/RoboFile.php b/server/RoboFile.php index 576fddd4fa..8e4a50b180 100644 --- a/server/RoboFile.php +++ b/server/RoboFile.php @@ -123,7 +123,10 @@ public function deployPantheon($branchName = 'master') { return; } - $this->_exec("cd $pantheonDirectory && git pull && git add . && git commit -am 'Site update' && git push"); + $push_status = $this->_exec("cd $pantheonDirectory && git pull && git add . && git commit -am 'Site update' && git push")->getExitCode(); + if ($client_sync_result != 0) { + throw new Exception('Failed to push to Pantheon'); + } $pantheonEnv = $branchName == 'master' ? 'dev' : $branchName; $this->deployPantheonSync($pantheonEnv, FALSE); @@ -196,11 +199,41 @@ public function generateReleaseNotes($tag = NULL) { $tag = $latest_tag; } + // Detect organization / repository name from git remote. + $remote = $this->taskExec("git remote get-url origin") + ->printOutput(FALSE) + ->run() + ->getMessage(); + + if (!empty($remote)) { + $origin_parts = preg_split('/[:\/]/', str_replace('.git', '', $remote)); + if (!empty($origin_parts[1]) && !empty($origin_parts[2])) { + $github_org = $origin_parts[1]; + $github_project = $origin_parts[2]; + } + } + + if (!isset($github_org) || !isset($github_project)) { + $this->say('No GitHub project or GitHub organization found, so not trying to fetch details from GitHub API.'); + } + + // This is the heart of the release notes, the git history, we get all the + // merge commits since the specified last version and later on we parse + // the output. Optionally we enrich it with metadata from GitHub REST API. $log = $this->taskExec("git log --merges --pretty=format:'%s¬¬|¬¬%b' $tag..")->printOutput(FALSE)->run()->getMessage(); $lines = explode("\n", $log); $this->say('Copy release notes below'); - echo "Changelog:\n"; + + $this->printReleaseNotesTitle('Changelog'); + + $pull_requests_per_issue = []; + $no_issue_lines = []; + $contributors = []; + $issue_titles = []; + $additions = 0; + $deletions = 0; + $changed_files = 0; foreach ($lines as $line) { $log_messages = explode("¬¬|¬¬", $line); @@ -222,6 +255,16 @@ public function generateReleaseNotes($tag = NULL) { // Whitespace-only log message, not meaningful for changelog. continue; } + $pr_number = $pr_matches[1][0]; + if (isset($github_org)) { + $pr_details = $this->githubApiGet("repos/$github_org/$github_project/pulls/$pr_number"); + if (!empty($pr_details->user)) { + $contributors[] = '@' . $pr_details->user->login; + $additions += $pr_details->additions; + $deletions += $pr_details->deletions; + $changed_files += $pr_details->changed_files; + } + } // The issue number is a required part of the branch name, // So usually we can grab it from the log too, but that's optional @@ -230,12 +273,115 @@ public function generateReleaseNotes($tag = NULL) { preg_match_all('!from [a-zA-Z-_0-9]+/([0-9]+)!', $line, $issue_matches); if (isset($issue_matches[1][0])) { - print "- Issue #{$issue_matches[1][0]}: {$log_messages[1]} (#{$pr_matches[1][0]})\n"; + $issue_number = $issue_matches[1][0]; + if (!isset($issue_titles[$issue_number]) && isset($github_org)) { + $issue_details = $this->githubApiGet("repos/$github_org/$github_project/issues/$issue_number"); + if (!empty($issue_details->title)) { + $issue_titles[$issue_number] = $issue_details->title; + $contributors[] = '@' . $issue_details->user->login; + } + } + + if (isset($issue_titles[$issue_number])) { + $issue_line = "- {$issue_titles[$issue_number]} (#{$issue_number})"; + } + else { + $issue_line = "- Issue #{$issue_number}"; + } + if (!isset($pull_requests_per_issue[$issue_line])) { + $pull_requests_per_issue[$issue_line] = []; + } + $pull_requests_per_issue[$issue_line][] = " - {$log_messages[1]} (#{$pr_matches[1][0]})"; + } + else { + $no_issue_lines[] = "- {$log_messages[1]} (#$pr_number)"; + } + } + + foreach ($pull_requests_per_issue as $issue_line => $pr_lines) { + print $issue_line . "\n"; + foreach ($pr_lines as $pr_line) { + print $pr_line . "\n"; + } + } + + $this->printReleaseNotesSection('', $no_issue_lines); + + if (isset($github_org)) { + $contributors = array_unique($contributors); + sort($contributors); + $this->printReleaseNotesSection('Contributors', $contributors); + + $this->printReleaseNotesSection('Code statistics', [ + "Lines added: $additions", + "Lines deleted: $deletions", + "Files changed: $changed_files", + ]); + } + } + + /** + * Print a section for the release notes. + * + * @param string $title + * Section title. + * @param array $lines + * Bulletpoints. + */ + protected function printReleaseNotesSection(string $title, array $lines) { + if (!empty($title)) { + $this->printReleaseNotesTitle($title); + } + foreach ($lines as $line) { + if (substr($line, 0, 1) == '-') { + print "$line\n"; } else { - print "- {$log_messages[1]} (#{$pr_matches[1][0]})\n"; + print "- $line\n"; } } } + /** + * Print a title for the release notes. + * + * @param string $title + * Section title. + */ + protected function printReleaseNotesTitle($title) { + echo "\n\n## $title\n"; + } + + /** + * Performs a GET request towards GitHub API using personal access token. + * + * @param string $path + * Resource/path to GET. + * + * @return mixed|null + * Decoded response or NULL. + * + * @throws \Exception + */ + protected function githubApiGet($path) { + $token = getenv('GITHUB_ACCESS_TOKEN'); + $username = getenv('GITHUB_USERNAME'); + if (empty($token)) { + throw new Exception('Specify the personal access token in GITHUB_ACCESS_TOKEN environment variable before invoking the release notes generator in order to be able to fetch details of issues and pull requests'); + } + if (empty($username)) { + throw new Exception('Specify the GitHub username in GITHUB_USERNAME environment variable before invoking the release notes generator in order to be able to fetch details of issues and pull requests'); + } + // We might not have a sane Drupal instance, let's not rely on Drupal API + // to generate release notes. + $ch = curl_init('https://api.github.com/' . $path); + curl_setopt($ch, CURLOPT_USERAGENT, 'Drupal Starter Release Notes Generator'); + curl_setopt($ch, CURLOPT_USERPWD, $username . ":" . $token); + curl_setopt($ch, CURLOPT_TIMEOUT, 30); + curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); + $result = curl_exec($ch); + curl_close($ch); + return empty($result) ? NULL : json_decode($result); + } + } diff --git a/server/hedley/modules/custom/hedley_activity/hedley_activity.module b/server/hedley/modules/custom/hedley_activity/hedley_activity.module index 9f4cdea1a7..addd80bc83 100644 --- a/server/hedley/modules/custom/hedley_activity/hedley_activity.module +++ b/server/hedley/modules/custom/hedley_activity/hedley_activity.module @@ -7,7 +7,6 @@ include_once 'hedley_activity.features.inc'; -// Define the measurements content types. define('HEDLEY_ACTIVITY_NUTRITION_ENCOUNTER_CONTENT_TYPE', 'nutrition_encounter'); define('HEDLEY_ACTIVITY_ATTENDANCE_CONTENT_TYPE', 'attendance'); define('HEDLEY_ACTIVITY_FAMILY_PLANNING_CONTENT_TYPE', 'family_planning'); @@ -20,6 +19,17 @@ define('HEDLEY_ACTIVITY_NUTRITION_CONTENT_TYPE', 'nutrition'); define('HEDLEY_ACTIVITY_NUTRITION_NUTRITION_CONTENT_TYPE', 'nutrition_nutrition'); define('HEDLEY_ACTIVITY_WEIGHT_CONTENT_TYPE', 'weight'); define('HEDLEY_ACTIVITY_NUTRITION_WEIGHT_CONTENT_TYPE', 'nutrition_weight'); +define('HEDLEY_ACTIVITY_INDIVIDUAL_PARTICIPANT_CONTENT_TYPE', 'individual_participant'); +define('HEDLEY_ACTIVITY_PRENATAL_ENCOUNTER_CONTENT_TYPE', 'prenatal_encounter'); +define('HEDLEY_ACTIVITY_ACUTE_ILLNESS_ENCOUNTER_CONTENT_TYPE', 'acute_illness_encounter'); +define('HEDLEY_ACTIVITY_SEND_TO_HC_CONTENT_TYPE', 'send_to_hc'); +define('HEDLEY_ACTIVITY_ACUTE_ILLNESS_VITALS_CONTENT_TYPE', 'acute_illness_vitals'); +define('HEDLEY_ACTIVITY_SYMPTOMS_GENERAL_CONTENT_TYPE', 'symptoms_general'); +define('HEDLEY_ACTIVITY_ISOLATION_CONTENT_TYPE', 'isolation'); +define('HEDLEY_ACTIVITY_CALL_114_CONTENT_TYPE', 'call_114'); +define('HEDLEY_ACTIVITY_HC_CONTAC_CONTENT_TYPE', 'hc_contact'); +define('HEDLEY_ACTIVITY_DANGER_SIGNS_CONTENT_TYPE', 'danger_signs'); + const HEDLEY_ACTIVITY_HEIGHT_BUNDLES = [ HEDLEY_ACTIVITY_HEIGHT_CONTENT_TYPE, @@ -316,7 +326,7 @@ function hedley_activity_get_person_measurements_by_period($person_id, array $me $query->fields('node', ['nid', 'created', 'type']); $person_field = 'field_person'; - hedley_stats_join_field_to_query($query, 'node', $person_field); + hedley_general_join_field_to_query($query, 'node', $person_field); $person_field_name = $person_field . '.' . $person_field . '_target_id'; $query->condition($person_field_name, $person_id); @@ -324,9 +334,9 @@ function hedley_activity_get_person_measurements_by_period($person_id, array $me ->condition('type', $measurement_bundles, 'IN') ->condition('status', NODE_PUBLISHED); - hedley_stats_join_field_to_query($query, 'node', 'field_session'); + hedley_general_join_field_to_query($query, 'node', 'field_session'); $date_field = 'field_scheduled_date'; - hedley_stats_join_field_to_query($query, 'node', $date_field, TRUE, "field_session.field_session_target_id"); + hedley_general_join_field_to_query($query, 'node', $date_field, TRUE, "field_session.field_session_target_id"); $date_field_name = $date_field . '.' . $date_field . '_value'; $query->condition($date_field_name, [$period['start'], $period['end']], 'BETWEEN'); diff --git a/server/hedley/modules/custom/hedley_device/hedley_device.module b/server/hedley/modules/custom/hedley_device/hedley_device.module index bfcb732961..ca0be4c159 100644 --- a/server/hedley/modules/custom/hedley_device/hedley_device.module +++ b/server/hedley/modules/custom/hedley_device/hedley_device.module @@ -243,7 +243,7 @@ function hedley_device_assign_shards($node, $wrapper) { case 'session': // Assign shards based on HC of the clinic, to which session belongs. $clinic_id = $wrapper->field_clinic->getIdentifier(); - $shard = hedley_device_shard_by_health_center($clinic_id); + $shard = hedley_general_shard_by_health_center($clinic_id); $shards = !$shard ? [] : [$shard]; break; @@ -264,8 +264,8 @@ function hedley_device_assign_shards($node, $wrapper) { // Participant shards are the union of adult and child shards. $child_id = $wrapper->field_person->getIdentifier(); $adult_id = $wrapper->field_adult->getIdentifier(); - $shards_child = hedley_device_shards_by_person($child_id); - $shards_adult = hedley_device_shards_by_person($adult_id); + $shards_child = hedley_general_shards_by_person($child_id); + $shards_adult = hedley_general_shards_by_person($adult_id); $shards = array_unique(array_merge($shards_child, $shards_adult)); break; @@ -273,8 +273,8 @@ function hedley_device_assign_shards($node, $wrapper) { // Relationship shards are the union of adult and child shards. $child_id = $wrapper->field_related_to->getIdentifier(); $adult_id = $wrapper->field_person->getIdentifier(); - $shards_child = hedley_device_shards_by_person($child_id); - $shards_adult = hedley_device_shards_by_person($adult_id); + $shards_child = hedley_general_shards_by_person($child_id); + $shards_adult = hedley_general_shards_by_person($adult_id); $shards = array_unique(array_merge($shards_child, $shards_adult)); break; @@ -285,14 +285,14 @@ function hedley_device_assign_shards($node, $wrapper) { // Assign shards based on Person of the individual participant, // to which encounter belongs. $person_id = $wrapper->field_individual_participant->field_person->getIdentifier(); - $shards = hedley_device_shards_by_person($person_id); + $shards = hedley_general_shards_by_person($person_id); break; // Handling individual_participant and all kinds of measurements. // Shards are assigned based on Person for which measurement was taken. default: $person_id = $wrapper->field_person->getIdentifier(); - $shards = hedley_device_shards_by_person($person_id); + $shards = hedley_general_shards_by_person($person_id); break; } @@ -302,45 +302,3 @@ function hedley_device_assign_shards($node, $wrapper) { $wrapper->field_shards->set($shards); } - -/** - * Resolve a shard based on HC field of the node. - * - * @param int $nid - * The node ID. - * - * @return int|bool - * Node ID of the shard. False, if shard wasn't successfully resolved. - */ -function hedley_device_shard_by_health_center($nid) { - // We have this check to allow SimpleTest to pass. - if (!$nid) { - return FALSE; - } - - $wrapper = entity_metadata_wrapper('node', $nid); - $shard = $wrapper->field_health_center->getIdentifier(); - - return $shard ? $shard : FALSE; -} - -/** - * Resolve shards based on Person field of the node. - * - * @param int $nid - * The node ID. - * - * @return array - * List of shards node IDs. Empty array, if none are found. - */ -function hedley_device_shards_by_person($nid) { - // We have this check to allow SimpleTest to pass. - if (!$nid) { - return []; - } - - $wrapper = entity_metadata_wrapper('node', $nid); - $shards = $wrapper->field_shards->value(['identifier' => TRUE]); - - return !empty($shards) ? $shards : []; -} diff --git a/server/hedley/modules/custom/hedley_general/hedley_general.module b/server/hedley/modules/custom/hedley_general/hedley_general.module index 3d6dc10a9d..c021e5f3ae 100644 --- a/server/hedley/modules/custom/hedley_general/hedley_general.module +++ b/server/hedley/modules/custom/hedley_general/hedley_general.module @@ -37,7 +37,7 @@ function hedley_general_add_task_to_advanced_queue_by_id($machine_name, $unique_ } /** - * Check whether a specific task exist and not processed yet. + * Check whether a specific task exists, and not yet / being processed. * * @param string $queue_machine_name * The machine name of the queue. @@ -47,20 +47,40 @@ function hedley_general_add_task_to_advanced_queue_by_id($machine_name, $unique_ * The statuses to filter by. * * @return bool - * TRUE if the task exist and not processed yet, otherwise returns FALSE. + * TRUE if the task exists and not and not yet / being processed. */ function hedley_general_advanced_queue_task_exists($queue_machine_name, $title, array $statuses = [ ADVANCEDQUEUE_STATUS_QUEUED, ADVANCEDQUEUE_STATUS_PROCESSING, ]) { - return (bool) db_select('advancedqueue', 'a') - ->fields('a') - ->condition('name', $queue_machine_name) + $tasks = db_select('advancedqueue', 'aq') + ->fields('aq', ['item_id', 'status', 'created']) ->condition('title', $title) + ->condition('name', $queue_machine_name) ->condition('status', $statuses, 'IN') - ->countQuery() + ->range(0, 100) ->execute() - ->fetchField(); + ->fetchAll(); + + foreach ($tasks as $task) { + if ($task->status == ADVANCEDQUEUE_STATUS_QUEUED) { + // Task did not start processing. + return TRUE; + } + + if ($task->status == ADVANCEDQUEUE_STATUS_PROCESSING) { + if (time() - $task->created < variable_get('hedley_aq_task_max_processing_period', 20 * 60)) { + // Task is being processed, and did not exceed allowed time period, + // which is set to 20 minutes, by default. + return TRUE; + } + else { + watchdog('hedley_aq', "AQ task suspected as stuck: $task->item_id"); + } + } + } + + return FALSE; } /** @@ -211,6 +231,7 @@ function hedley_general_get_measurement_types() { 'field_prenatal_encounter', 'field_acute_illness_encounter', 'field_home_visit_encounter', + 'field_well_child_visit_encounter', ]; foreach ($measurement_indicator_fields as $indicator) { @@ -254,3 +275,119 @@ function hedley_general_query_exclude_deleted_alter(QueryAlterableInterface $que ->condition('fd.field_deleted_value', FALSE); $query->condition($or); } + +/** + * Join a field to a DB Select query, and add its main value. + * + * @param SelectQuery $query + * Query to join to. + * @param string $entity_type + * Type of the host entity of the field. Or NULL to avoid filtering the field + * table by entity type. + * @param string $field_name + * Field name. + * @param bool $require + * Whether filter out rows where this field would be NULL. + * @param string $entity_id_selector + * SQL selector for the column by which the field is joined. The entity ID is + * used by default. + * @param string $field_alias + * The field alias. + * + * @throws Exception + */ +function hedley_general_join_field_to_query(SelectQuery $query, $entity_type, $field_name, $require = TRUE, $entity_id_selector = NULL, $field_alias = NULL, $second_value = FALSE) { + $field = field_info_field($field_name); + $table_name = _field_sql_storage_tablename($field); + + if (!$entity_id_selector) { + if (!$entity_type) { + throw new Exception('Entity type is required when ID selector is not specified'); + } + // Set default entity ID selector. + switch ($entity_type) { + case 'user': + $entity_id_selector = 'users.uid'; + break; + + case 'node': + $entity_id_selector = 'node.nid'; + break; + + default: + throw new Exception(format_string(' hedley_general_join_field_to_query() is not implemented for entity_type: "@type"', ['@type' => $entity_type])); + } + } + + switch ($field['type']) { + case 'entityreference': + $column_suffix = 'target_id'; + break; + + case 'image': + case 'file': + $column_suffix = 'fid'; + break; + + default: + $column_suffix = 'value'; + } + + $field_alias = $field_alias ?: $field_name; + $query->addField($field_alias, $field_name . '_' . $column_suffix, $field_alias); + if ($second_value) { + $column_suffix = 'value2'; + $query->addField($field_alias, $field_name . '_' . $column_suffix, $field_alias); + } + + $join = $require ? 'innerJoin' : 'leftJoin'; + $arguments = [':type' => $entity_type]; + $conditions[] = "$entity_id_selector = $field_alias.entity_id"; + if ($entity_type) { + $conditions[] = "$field_alias.entity_type = :type"; + } + + $query->$join($table_name, $field_alias, implode(' AND ', $conditions), $arguments); +} + +/** + * Resolve a shard based on HC field of the node. + * + * @param int $nid + * The node ID. + * + * @return int|bool + * Node ID of the shard. False, if shard wasn't successfully resolved. + */ +function hedley_general_shard_by_health_center($nid) { + // We have this check to allow SimpleTest to pass. + if (!$nid) { + return FALSE; + } + + $wrapper = entity_metadata_wrapper('node', $nid); + $shard = $wrapper->field_health_center->getIdentifier(); + + return !empty($shard) ? $shard : FALSE; +} + +/** + * Resolve shards based on Person field of the node. + * + * @param int $nid + * The node ID. + * + * @return array + * List of shards node IDs. Empty array, if none are found. + */ +function hedley_general_shards_by_person($nid) { + // We have this check to allow SimpleTest to pass. + if (!$nid) { + return []; + } + + $wrapper = entity_metadata_wrapper('node', $nid); + $shards = $wrapper->field_shards->value(['identifier' => TRUE]); + + return !empty($shards) ? $shards : []; +} diff --git a/server/hedley/modules/custom/hedley_migrate/csv/2019-05-3/child.csv b/server/hedley/modules/custom/hedley_migrate/csv/2019-05-3/child.csv deleted file mode 100644 index fed782b33a..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/csv/2019-05-3/child.csv +++ /dev/null @@ -1,252 +0,0 @@ -Unique ID,Mother Unique ID,First Name,Middle Name,Last Name,Birth Date,Estimated (Y/N),National ID,Gender,Ubudehe,Mode of Delivery,Mother Name,Mother ID,Mother ID,Father Name,Father ID,Caregiver Name,Caregiver ID,Province,District,Sector,Cell,Village,Health Center,Clinic -2,2,Caline,,INEZA ,06-05-2017,N,,Female,2,,,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -3,3,Evaliste,,NDUNGUTSE ,30-05-2017,N,,Male,2,,MANIRAFASHA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -4,4,,,UWUMUKIZA,26-08-2017,N,,Male,2,,UWERA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -5,5,,,UWILINGIYIMANA,17-07-2017,N,,Male,2,,RIZAHANANDE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -6,6,,,MUCYO,02-05-2017,N,,Male,2,,MUJAWAYEZU,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,MBOGO,MINAZI, -7,7,,,IZIBYOSE,20-06-2017,N,,Male,2,,NTAWIHA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -8,8,,,NISINGIZWE,30-08-2017,N,,Male,2,,NYIRAMBARUSHIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -9,9,,,NISINGIZWE ,02-05-2017,N,,Female,2,,NAKURE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -10,10,,,TWIZEYUMUKIZA,18-06-2017,N,,Male,2,,NISENGWE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -11,11,Vanessa,,UWIKUNZE ,05-06-2017,N,,Female,2,,NYIRABASHYITSI,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -12,12,,,HABAYIMANA,30-06-2017,N,,Male,2,,MUSABYIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -13,13,,,IZIMPAMVU,30-07-2017,N,,Female,2,,NIRAGIRE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -14,14,,,IGIRANEZA,13-06-2017,N,,Female,2,,UWINGABIRE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -15,15,,,MANIRAFASHA,23-07-2017,N,,Female,2,,NYIRANTEZIMANA,,1198180101429082,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -16,16,,,UKWISHAKA ,13-06-2017,N,,Male,2,,UWIRAGIYE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -17,17,,,NIYOGUSHIMWA,02-08-2017,N,,Male,2,,NYIRAMBITSAYIMANA,,1198980120818015,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,NDEGAMIRE,MINAZI, -18,18,,,MANISHIMWE,07-08-2017,N,,Male,1,,UWIMANIMPAYE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,NDEGAMIRE,MINAZI, -19,19,,,IGISINGIZO,22-06-2017,N,,Female,2,,NYIRANDORIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUNIHI,MINAZI, -20,20,,,NISHIMWE,03-08-2017,N,,Female,2,,UWIFASHIJE,,1198680122136089,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI, -21,21,Novella,,IGIHOZO ,19-05-2017,N,,Female,2,,NYIRAHAVUGUZIGANYA,,1196170036268014,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI, -22,22,,,INEZA ,09-06-2017,N,,Female,2,,NYIRAMUGISHA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI, -23,23,,,IZERIMANA,11-06-2017,N,,Male,2,,IRADUKUNDA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -24,24,Giselle,,IRAGENA ,04-05-2017,N,,Female,2,,TUYISHIMIRE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -25,25,Elissa,,NIYIBIZI ,17-07-2017,N,,Male,2,,KANKUNDIYE,,1198270130839010,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -26,26,,,KURADUSENGE,07-07-2017,N,,Male,2,,MWAMIKAZI,,1199680006014032,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -27,27,Ganza,,UWITUZE ,09-05-2017,N,,Male,2,,NYIRAMAHIRWE,,1199180105530032,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -28,28,,,CYUBAHIRO,03-07-2017,N,,Male,2,,UWIMANA,,1197880087821087,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -29,29,,,IMPANO,30-07-2017,N,,Male,2,,BUCYENSENGE,,1199170101826079,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUNIHI,MINAZI, -30,30,,,NIYOMAHORO,29-06-2017,N,,Female,2,,MUKANDAYISENGA,,119678004405736,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -31,31,,,NTEZIRYAYO,30-07-2017,N,,Male,2,,NTAWUGIRIRINO,,1197380060587083,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -32,32,,,NIYOKWIZERWA,27-07-2017,N,,Male,2,,NIKUZE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI, -33,33,,,TWIZERIMANA,23-07-2017,N,,Male,2,,MUJAWIMANA,,1199370106701019,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -34,34,,,CYIZA,11-08-2017,N,,Male,2,,MUKANDAYISENGA,,11958005002655044,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -35,35,,,UWINEZA,9/8/2017,N,,Female,2,,UGIRIWABO,,1195280032465064,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -36,36,,,IGIRANEZA,31-05-2017,N,,Male,2,,NYIRANIZEYIMANA,,1198780164280065,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -37,37,,,IKUZWE,24-07-2017,N,,Male,2,,YAMURAGIYE,,1199380106665000,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -38,38,,,UWINGENEYE,06-08-2017,N,,Female,2,,NISHIMWE,,1198980117073036,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -39,39,,,NIYOKWIZERWA,09-06-2017,N,,Male,1,,NYIRANGIRIMANA,,119867012230062,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -40,40,,,IGIRANEZA,24-06-2017,N,,Female,1,,ISHIMWE RACHEL,,119970128063030,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -41,41,,,IGIHOZO ,21-08-2017,N,,Male,2,,UWIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -42,42,,,IRANEZEZA,12-08-2017,N,,Female,2,,MUKANTAMBARA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KANKA,MINAZI, -43,43,,,MAJYAMBERE,17-07-2017,N,,Male,2,,UWIMANA,,1198780118184099,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -44,44,,,NIYIGENA,28-07-2017,N,,Female,2,,MUSENGIMANA,,1198780118092024,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -45,45,,,NIYOGISUBIZO,08-08-2017,N,,Female,2,,UWITIJE,,1197680066309000,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -46,46,,,NDIKUMWENAYO,21-06-2017,N,,Male,2,,UWINGABIRE,,119927004782010,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -47,47,,,KAMIKAZI,29-06-2017,N,,Female,2,,MUKAMUGANGA,,1197970084455074,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI, -48,48,,,NIRINGIYIMANA,31/6/2017,N,,Male,1,,NYIRANSENGIMANA,,1198170101419000,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI, -49,49,,,IRADUKUNDA,26-08-2017,N,,Female,2,,NYIRANGENDAHIMANA,,1199670102865009,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -50,50,,,NITANGA,21-07-2017,N,,Male,2,,NYIRANSANZAMAHORO,,1198570121031086,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,BUKONDE,MINAZI, -51,51,,,TUYISENGE,10-07-2017,N,,Female,2,,NYIRANKUNZIMANA,,1198470126335056,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,BUKONDE,MINAZI, -52,52,,,TUYIHIMBAZE,15-08-2017,N,,Male,2,,BIHOYIKI,,1196980047501079,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,NDEGAMIRE,MINAZI, -53,53,,,NDAYIZEYE,28-12-2017,N,,Male,1,,NYIRAMBONABUCYA,,1198570119565072,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI, -54,54,,,IGIRANEZA,11-08-2017,N,,Female,2,,NYIRAMBARUSHIMANA,,1194770014785090,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI, -55,55,,,UWIMANIDUHAYE,30-08-2017,N,,Female,2,,NYAMPUNDU,,1195780034706045,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -56,56,,,IRASUBIZA ,01-12-2017,N,,Female,2,,MUREKATETE,,1198780118156009,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -57,57,,,DUSINGIZIMANA,15-10-2017,N,,Female,1,,NYIRAHABIMANA,,1198380115299061,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI, -58,58,,,TUYIZERE ,19-08-2017,N,,Male,2,,UWAGIRINSHUTI,,1198580121058065,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -59,59,,,NIYOGUSUBIZWA,22-01-2018,N,,Female,2,,MUJAWAMARIYA,,1198870125953082,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI, -60,60,,,HAGENIMANA,15-09-2017,N,,Male,2,,MUSABYEYEZU,,1198180099156065,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI, -61,61,,,NIYOGISUBIZO,26-10-2017,N,,Male,2,,TUYISABE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI, -62,62,,,MUNEZERO,06-11-2017,N,,Female,2,,MUKANDAYAMBAJE,,1199580085750002,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI, -63,63,,,NDAYISABA,02-10-2017,N,,Male,2,,MUKESHIMANA,,1198680122113052,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI, -64,64,,,ISIMBI ,12-10-2017,N,,Female,2,,TWIZERIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI, -65,65,,,ISHIMWE,19-09-2017,N,,Male,2,,NYIRANKUNZURWANDA,,1195680035909079,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,MBOGO,MINAZI, -66,66,,,UWITUZE ,30-11-2017,N,,Female,2,,MUKANSANGA,,1197570064853094,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,MBOGO,MINAZI, -67,67,,,MANIRAKIZA,18-08-2017,N,,Female,1,,NYIRASAFARI,,119780112001099,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,MBOGO,MINAZI, -68,68,,,TUYIZERE ,12-12-2017,N,,Male,1,,MUKAGASANA,,1196880080321016,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI, -69,69,,,MUKANOHERI,24-12-2017,N,,Female,2,,UZAMUKUNDA,,1194980018545004,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI, -70,70,,,IRADUKUNDA,12-07-2017,N,,Male,2,,NYIRANSANZAMAHORO,,119870118338085,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI, -71,71,,,UWASE,08-09-2017,N,,Female,2,,MUSANABERA,,1199580163058005,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -72,72,,,TUMUKUNDE,14-10-2017,N,,Female,1,,MUGWANEZA,,1198270130857198,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -73,73,,,HABIMANA,11-06-2017,N,,Male,2,,NYIRANDIKUBWIMANA,,119848126299037,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -74,74,,,UWAYEZU,20-08-2017,N,,Female,2,,NZAYITURIKI,,1199080122060068,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -75,75,,,UWURUKUNDO,09-08-2017,N,,Female,2,,NYIRAHAFASHIMANA,,1195870041611031,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI, -76,76,,,UWINEZA,13-12-2017,N,,Female,2,,NYIRAHAKIZIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI, -77,77,,,UWITUZE,14-10-2017,N,,Female,2,,MANIKUZWA,,1198070108293039,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI, -78,78,,,HAKIZIMANA,14-11-2017,N,,Male,1,,NYIRANKWIYE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI, -79,79,,,MUPENZI,30-08-2017,N,,Male,2,,UWAMBAJIMANA,,1198980120939067,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI, -80,80,,,MICOMYIZA,17-02-2018,N,,Female,2,,NZAMUKUNDA,,1198270130873040,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI, -81,81,,,IRATUZI,24-11-2017,N,,Female,2,,KAMPIRE,,1199070121912105,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -82,82,,,TWIZEYIMANA,23-05-2017,N,,Male,2,,NYIRANGIRIMANA,,1199070122076084,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -83,83,,,NIYIGENA,17-09-2017,N,,Female,2,,MUKANKAKA,,1198180147394078,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -84,84,,,BERWA,26-11-2017,N,,Male,2,,NIYONAMBAZA,,1198680122064090,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -85,85,Frank,,MUKIZA ,21-12-2017,N,,Male,2,,MUKESHIMANA,,1198170007573043,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -86,86,,,UWIDUHAYE,12-10-2017,N,,Female,2,,MUSANBYIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -87,87,Diane,,IRAKOZE ,15-05-2017,N,,Female,2,,BANYANGIRIKI,,1197380060478093,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -88,88,,,NIYOGISINGIZO,03-04-2017,N,,Male,1,,MANIRAFASHA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -89,89,,,AKIMANIMPAYE,14-11-2017,N,,Female,2,,NTAWUSHIRAGAHINDA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -90,90,,,NDAYISHIMIYE,05-09-2017,N,,Male,2,,IRADUKUNDA,,1199670076965003,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -91,91,,,MANIZABAYO,14-10-2017,N,,Female,2,,UWAMAHORO,,1194870018620093,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -92,92,,,IGIRANEZA,28-10-2017,N,,Female,2,,NYIRAHABIYAKARE,,1198670122097021,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -93,93,,,MUSHIMIRE,14-05-2017,N,,Female,2,,NIYOTWAGIRA,,1199270047783064,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -94,94,Robert,,KWIZERA ,10-12-2017,N,,Male,2,,UZAMUKUNDA,,1199570123995039,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -95,95,,,NIYOMUKIZA,29-09-2017,N,,Female,2,,MUREREYIMANA,,1198380115238046,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -96,96,,,NIYOMUBYEYI,10-12-2017,N,,Female,1,,MUKANYABYENDA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI, -97,97,,,IRAKOZE,12-12-2017,N,,Male,2,,UWIRINGIYIMANA,,1199380106654025,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI, -98,98,Aliane,,UWASE ,24-12-2017,N,,Female,2,,MUSHIMIYIMANA,,1198670122214034,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI, -99,99,,,NIYOMUKIZA ,13-06-2017,N,,Male,2,,MANIRAFASHA,,1200070018096078,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -100,100,,,TUMUKUNDE,03-10-2017,N,,Female,2,,NYIRAMAJYAMBERE,,1198970120806059,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -101,101,,,MIZERO,26-09-2017,N,,Male,2,,MANIRADUKUNDA,,1198880126010052,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUNIHI,MINAZI, -102,102,,,UWAMARIYA,13-08-2017,N,,Female,2,,MBONIRERA,,1198680181414062,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI, -103,103,,,BYOSENIMANA,02-01-2018,N,,Male,2,,MUKASEKURU,,1199080219254037,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI, -104,104,,,UMUTONI,05-08-2017,N,,Male,2,,MUSANGANIRE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI, -105,105,,,UWIMFURA,08-08-2017,N,,Female,2,,MUKAHIGIRO,,1199470185224044,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI, -106,106,Anitha,,IRANEZEZA ANITHA,11-11-2017,N,,Female,2,,IYAMUREMYE,,1199370014813089,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI, -107,107,,,MURENGEZI,28-11-2017,N,,Male,2,,UWIRINGIYIMANA,,1199580113115026,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI, -108,108,,,ISANO,21-05-2017,N,,Male,2,,MUKESHIMANA,,1199080121973028,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI, -109,109,,,DUFITINGABIRE,28-09-2017,N,,Female,2,,NYIRANGAMIJIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI, -110,110,M. Solange,,NIYOBYOSE ,09-11-2017,N,,Female,2,,NDACYAYISENGA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -111,111,,,MUTONIWASE,18-07-2017,N,,Female,2,,NTAWUKENABISHAKA,,1199670102870062,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KABARIMA,MINAZI, -112,112,Christine,,TUYISENGE ,24-08-2017,N,,Female,2,,NYIRANTEZIMANA,,1197570064784056,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KABARIMA,MINAZI, -113,113,,,IRADUKUNDA,07-09-2017,N,,Male,2,,AKIMANIZANYE,,1198180101440075,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KABARIMA,MINAZI, -114,114,,,RUKUNDO,07-09-2017,N,,Male,2,,AKIMANIZANYE,,1198180101440075,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -115,115,,,NIYOGUSHIMWA,02-12-2017,N,,Female,2,,MUSABAMAHORO,,1198280130733093,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -116,116,,,NIYOKWIZERWA,07-01-2018,N,,Female,2,,AKIMANIZANYE,,1199470060497075,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -117,117,,,IRIZABIMBUTO,04-02-2018,N,,Female,2,,TUYISENGE,,1199070124880042,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -118,118,Teta,,UWERA ,10-10-2017,N,,Female,1,,AYINKAMIYE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI, -119,119,,,MANIZABAYO,17-08-2017,N,,Female,1,,MUKANGAMIJE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI, -120,120,,,UTUJENEZA,25-12-2017,N,,Female,2,,ABIMANA,,1199470060515086,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI, -121,121,,,GUTABARWAKWIMANA,30-12-2017,N,,Male,1,,NTAKIRUTINKA,,1199570103612025,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI, -122,122,Manzi,,HIRWA ,11-02-2018,N,,Male,2,,TUYISHIMIRE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -123,123,,,DUSHIMIMANA,12-12-2017,N,,Female,2,,ABINGENEYE,,119970045751046,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -124,124,,,IMENYABAYO,26-09-2017,N,,Female,2,,KAMBUGURIJE,,1198870126103020,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -125,125,,,YANGIRIYENEZA,20-08-2017,N,,Female,2,,NYIRANGENDAHIMANA,,119877011830814,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI, -126,126,,,NIMURAGIRE,28-11-2017,N,,Female,2,,NYIRAMBABARIYE,,1198780118308021,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI, -127,127,,,MUHAWENIMANA,28-10-2017,N,,Female,2,,YADUFASHIJE,,1197870087801017,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI, -128,128,Teta,,ISIMBI ,03-12-2017,N,,Female,2,,NYIRANSANZAMAHORO,,1199770105288007,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI, -129,129,,,NIYOGUSHIMWA,06-07-2017,N,,Male,2,,MUKAMURENZI,,1198770120464061,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI, -130,130,,,TWIZERIMANA,20-07-2017,N,,Male,2,,NYIRABASHYITSI,,1198480126241001,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI, -131,131,M.Fiona,,IKIREZI ,02-06-2017,N,,Female,2,,MUKESHIMANA,,1199070122045033,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI, -132,132,,,UWISHEMA,07-11-2017,N,,Female,2,,TUYISENGE,,1198980120775093,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI, -133,133,,,ANAMBABAZI,15-10-2017,N,,Female,2,,NTAKIZANYIMA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI, -134,134,,,NISHIMWE,01-09-2017,N,,Female,2,,TWIZERIMANA,,1197970085860073,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI, -135,135,Hope,,TUMUKUNDE ,09-01-2018,N,,Female,2,,AKITEGETSE,,1198380096419061,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI, -136,136,,,UWIZEYIMANA,04-11-2017,N,,Female,2,,TUYISHIMIRE,,1199270119317039,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -137,137,,,DUHIRWE,02-11-2017,N,,Female,2,,MANIRAGUHA,,1199080122048088,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -138,138,Cynthia,,AKARABO ,01-11-2017,N,,Female,2,,NYIRANIZEYIMANA,,1195480030158080,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -139,139,,,HASHIMWEYO,06-10-2017,N,,Female,2,,MUKADUNIYA,,1198780118241075,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -140,140,,,UFITAMAHORO,10-06-2017,N,,Male,2,,NYIRABAGENZI,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -141,141,,,MFITUMUKIZA,29-12-2017,N,,Male,2,,NYIRANDIKUBWIMANA,,1199080122040092,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -142,142,,,NIYONSABA,12-09-2017,N,,Male,2,,MANIRAGUHA,,1197770070230044,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -143,143,,,DUKUNDIMANA,11-08-2017,N,,Male,1,,MANIRAGUH HONOLINE,,1198780118104084,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -144,144,,,UWIDUHAYE,18-09-2017,N,,Female,2,,UWIMANIMPAYE,,1199670064284098,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -145,145,,,NIYONKORERA,11-10-2017,N,,Male,2,,YAMBABARIYE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -146,146,,,NYIRANKUNZIMANA,13-10-2017,N,,Female,2,,UWIRAGIYE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -147,147,,,IMENYABAYO,08-10-2017,N,,Male,2,,NTAKIRUTINKA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -148,148,Patrick,,NIYONKURU ,26-01-2018,N,,Male,2,,NYIRANIZEYIMANA,,1199470188318063,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -149,149,,,UMUHOZA ,03-10-2017,N,,Female,1,,NZAMUKOSHA,,1198770118096078,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -150,150,,,NIZEYIMANA,28-10-2017,N,,Female,2,,MUKAMURENZI,,1197870087463063,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -151,151,,,NIYONGIRA,16-12-2017,N,,Male,2,,NYIRAMAHORO,,1198470126164049,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -152,152,,,NIZEYIMANA,14-11-2017,N,,Male,2,,NIYIGENA,,1199170105359019,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KABARIMA,MINAZI, -153,153,,,NDUWAYEZU,24-10-2017,N,,Female,2,,UMUHOZA,,1197270061689047,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI, -154,154,Chance Belinda,,ISIMBI ,29-01-2018,N,,Female,2,,UWAYEZU,,1198880027347090,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -155,155,,,BYUKUSENGE,25-03-2018,N,,Male,2,,MUSABEYEZU,,1199170105436071,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -156,156,Mimi,,IHOZA ,06-04-2018,N,,Female,2,,MASENGESHO,,119967015117089,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI, -157,157,,,DUSHIMIRIMANA,12-12-2017,N,,Male,2,,UMUHIRE,,1199770023030073,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -158,158,,,IRAGENA,12-04-2018,N,,Female,2,,TUYISHIMIRE,,1195980044772094,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -159,159,Alice,,INEZA ,17-10-2017,N,,Female,2,,TWAMBAJEMARIYA,,1199170105385035,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI, -160,160,,,MANIRAGENA,11-03-2018,N,,Female,2,,MUKANKURANGA,,1199470002525008,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -161,161,,,IRIHO,02-02-2018,N,,Male,2,,ISHIMWE RACHEL,,'1199680009528083,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI, -162,162,Alliance,,INEZA ,22-01-2018,N,,Female,2,,NYIRABIZEYIMANA,,1198870123583010,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI, -163,163,,,NDIKUMWENAYO,11-04-2018,N,,Male,2,,DUSABIMANA,,11988701261102033,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -164,164,Yannick,,NSHUTI ,09-02-2018,N,,Male,2,,MUHAWENIMANA,,1199570051681037,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -165,165,Gisa,,IRAKOZE ,04-02-2018,N,,Male,1,,NYIRABAGABE,,1196970015648082,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -166,166,,,ISHIMWE,27-12-2017,N,,Male,2,,NTAMABYARIRO,,1199570028292013,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI, -167,167,Munezero,,IZERE ,06-12-2017,N,,Male,2,,NYIRANSENGIYUMVA,,119917003259058,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI, -168,168,,,IRASUBIZA ,04-03-2018,N,,Female,2,,MUHAWENIMANA,,'1198380115276024,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI, -169,169,,,NDACYAYISENGA,23-04-2018,N,,Male,2,,NIYONSABA,,1198480126150013,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI, -170,170,,,INEZAYURUKUNDO,10-03-2018,N,,Male,1,,NYIRAMAHIRWE,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -171,171,,,NEZERWA,05-01-2018,N,,Female,2,,MUKARWEGO,,1198780118044058,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI, -172,172,,,UWINEZA,05-12-2017,N,,Female,2,,NAKURE,,1198570120985085,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,NDEGAMIRE,MINAZI, -173,173,,,MUCUNGUZI,25-10-2017,N,,Male,2,,NYIRANGARUKIYE,,1198470127548083,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -174,174,,,NSHIMIYUMUREMYI,26-10-2018,N,,Male,2,,NYIRAHABINEZA,,1196680043541086,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -175,175,,,HABIMFURA,25-11-2018,N,,Male,1,,YANKURIJE,,1199670076966090,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -176,176,,,CYUZUZO,14-01-2018,N,,Female,2,,MUKESHIMANA,,1197770070157040,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -177,177,,,NSANZIMANA,20-01-2018,N,,Male,2,,MUKAGASANA,,119927047785038,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -178,178,,,IGIHOZO,21-11-2017,N,,Female,2,,TWIZERIMANA,,1199280119309019,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI, -179,179,,,ISUBIRIZIGIHE,10-09-2017,N,,Male,2,,NDACYAYISENGA,,1198380115328047,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -180,180,,,KUBWIMANA,13-03-2018,N,,Male,2,,NYIRANSABIMANA,,1199670064326033,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI, -181,181,,,IGIRANEZA,26-03-2018,N,,Male,2,,NIYONAMBAZA,,1199470002587196,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI, -182,182,,,IZERIMANA,23-12-2017,N,,Male,2,,NIYOMUKIZA,,1199370031040092,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI, -183,183,,,NZAMBAZIMANA,16-02-2018,N,,Male,2,,NYIRANSABIMANA,,,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -184,184,,,IRIKUMWENATWE,12-12-2017,N,,Male,2,,UWIBAMBE,,1198770118004012,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -185,185,Emmy,,KWIZERA ,14-03-2018,N,,Male,1,,YAMFASHIJE,,1198470126199054,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI, -186,186,,,HAGANZUWERA,22-06-2017,N,,Male,2,,NYIRANDUHUYE,,1199180105414015,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -187,187,,,NTABANGANYIMANA,24-06-2017,N,,Male,2,,NYIRANZUBAHIMANA,,1198570121115047,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI, -188,188,Angelo,,NDAYISHIMIYE ,15-02-2018,N,,Male,2,,MUSABIMANA,,1199270119302016,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI, -189,189,,,IRAKIZA,10-01-2018,N,,Male,1,,MUTUYIMANA,,1199270119307051,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI, -190,190,,,IRASUBIZA ,09-04-2018,N,,Male,2,,NYIRANSABIMANA,,1198801125996089,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI, -191,191,,,TWAMBAJEMARIYA,16-08-2017,N,,Female,2,,NYIRAMAJYAMBERE,,1199370106639090,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI, -192,192,,,NIYOGUSHIMWA,31/4/2018,N,,Male,2,,NYIRANSHIMIYIMANA,,1199470002564073,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI, -193,193,,,IGIRANEZA,08-05-2018,N,,Female,2,,MBABARENGIRENTE,,1198570121011010,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUNIHI,MINAZI, -194,194,,,MUNEZERO,18-02-2018,N,,Female,2,,DUSABEYEZU,,1199470002574147,,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI, -195,195,,,KUBERIMANA,30-03-2018,N,,Female,2,,MUTUYIMANA,,1199670067111002,,,,,,,,,,, -196,196,Uwurukundo,,IZERE ,15-03-2018,N,,Female,2,,UWAMARIYA,,1198270133785083,,,,,,,,,,, -197,197,,,UMUTONI,14-01-2018,N,,Female,1,,MUSABYIMANA,,1198570120994086,,,,,,,,,,, -198,198,Diane,,ITUZE ,04-02-2018,N,,Female,2,,URWIBUTSO,,119987004743048,,,,,,,,,,, -199,199,,,IRASUBIZA ,26-03-2018,N,,Male,2,,DUSABIMANA,,1199070111238003,,,,,,,,,,, -200,200,,,SHIMIRWA,07-12-2017,N,,Male,2,,MUKASHYAKA,,1199170105306018,,,,,,,,,,, -201,201,,,UWINEZA,05-10-2017,N,,Female,2,,MUKANKUNDIYE,,,,,,,,,,,,, -202,202,,,IMPUHWEZAYO,28-04-2018,N,,Female,2,,MUKASHYAKA,,1199070121941096,,,,,,,,,,, -203,203,,,SABUWITEKA,08-02-2018,N,,Female,2,,NYIRAMBARUBUKEYE,,1199580021467026,,,,,,,,,,, -204,204,,,IGIRANEZA,21-09-2017,N,,Male,2,,IGIRANEZA,,1199180105302064,,,,,,,,,,, -205,205,,,NSANZABERA,10-03-2018,N,,Male,2,,NYIRAMAHINGURA,,1198080108294020,,,,,,,,,,, -206,206,,,UWURUKUNDO,05-09-2017,N,,Female,2,,DUSABEMARIYA,,,,,,,,,,,,, -207,207,,,IRATUZI,07-07-2017,N,,Male,2,,NIYONIZERA,,1199670009890071,,,,,,,,,,, -208,208,,,IRASUBIZA ,18-06-2018,N,,Male,2,,NYIRANGIRENTE,,1198270130676023,,,,,,,,,,, -209,209,Mico,,MIZERO ,01-06-2018,N,,Male,2,,NYIRANIZEYIMANA,,,,,,,,,,,,, -210,210,,,NIYIGENA,03-04-2018,N,,Female,2,,NYIRANGIRABANZI,,1197670066413061,,,,,,,,,,, -211,211,,,NIYIKORA,18-09-2017,N,,Male,2,,UWERA,,1199870075081030,,,,,,,,,,, -212,212,,,DUSHIMIMANA,18-12-2017,N,,Male,2,,NYIRANDIKUBWIMANA,,1198570121261028,,,,,,,,,,, -213,213,,,UWUZUYINEMA,28-02-2018,N,,Female,2,,AKIMANA,,,,,,,,,,,,, -214,214,,,UMUKUNZI,04-05-2018,N,,Male,2,,NIYOTWAMBAZA,,119967073835020,,,,,,,,,,, -215,215,,,MUTONIWASE,20-02-2018,N,,Female,2,,NTABANGANYIMANA,,1199070121583066,,,,,,,,,,, -216,216,Angeline,,ISHIMWE ,19-05-2018,N,,Female,2,,KANZAYIRE,,,,,,,,,,,,, -217,217,,,TUMUKUNDE,27-06-2018,N,,Female,2,,NYIRANSENGIMANA,,,,,,,,,,,,, -218,218,,,UWURUKUNDO,26-09-2017,N,,Female,2,,UWUMUREMYI,,,,,,,,,,,,, -219,219,,,IGIHOZO,18-02-2018,N,,Female,2,,MANIRAGUHA,,,,,,,,,,,,, -220,220,,,IGIHOZO,12-02-2018,N,,Female,2,,DUSABENDE,,,,,,,,,,,,, -221,221,,,UWIDUHAYE,10-02-2018,N,,Female,2,,ZANINKA,,,,,,,,,,,,, -222,222,,,IRAKOZE,28-01-2018,N,,Female,2,,NYIRAHABIMANA,,,,,,,,,,,,, -223,223,,,IRADUKUNDA,28-01-2018,N,,Female,2,,NYIRAHABIMANA,,,,,,,,,,,,, -224,224,,,NDAYIZEYE,18-06-2018,N,,Male,2,,MUSABENDE,,,,,,,,,,,,, -225,225,,,TUMUKUNDE MANZI ,08-04-2018,N,,Male,2,,KAMPARA SOLANGE,,,,,,,,,,,,, -226,226,,,DUSHIMIMANA,04-05-2018,N,,Male,2,,UWIRINGIYIMANA,,,,,,,,,,,,, -227,227,,,DUSHIMIRIMANA,30/12/2017,N,,Male,2,,MUSABYIMANA,,1197770070127076,,,,,,,,,,, -228,228,,,TUYISHIMIRE SANDRINE,14-08-2018,N,,Female,2,,BIHOYIKI,,1199870088217075,,,,,,,,,,, -229,229,,,NIZEYIMANA,13/9/2018,N,,Male,2,,MANIRAFASHA,,1198670122160037,,,,,,,,,,, -230,230,,,NTIVUGURUZWA,31/10/2018,N,,Male,2,,NSEKANABANZI,,1199570132314015,,,,,,,,,,, -231,231,,,AHIMANA BERTIN,24/9/2018,N,,Male,2,,TWIZERIMANA,,1199070121928029,,,,,,,,,,, -232,232,,,IRATUZI,17/8/2018,N,,Male,2,,MUKESHIMANA,,1198170101445016,,,,,,,,,,, -233,233,,,HABIYAMBERE,21/8/2018,N,,Male,2,,NYIRAMBARUSHIMANA,,1197770070111066,,,,,,,,,,, -234,234,,,SHIMWA SANO,12/4/2018,N,,Male,2,,NIYONAMBAZA,,1199280119308032,,,,,,,,,,, -235,235,,,MASENGESHO,25/9/2018,N,,Male,2,,NYIRABUHAKE,,1197370060541015,,,,,,,,,,, -236,236,,,UWIDUHAYE,06-10-2018,N,,Male,2,,NYIRABASHYITSI,,1198970120861052,,,,,,,,,,, -237,237,,,DUFITUMUGISHA ,10-05-2018,N,,Male,2,,MUHAWENIMANA,,1198370115375032,,,,,,,,,,, -238,238,,,UWAMARIYA,21/9/2018,N,,Female,2,,MUSABYEMARIYA,,1197670066333048,,,,,,,,,,, -239,239,,,NIYONSABA,08-03-2018,N,,Male,2,,MUKAMURENZI,,1198370115283057,,,,,,,,,,, -240,240,,,NIRAGIRE SARA,16/6/2018,N,,Female,2,,NYIRANSABIMANA,,1199370106593007,,,,,,,,,,, -241,241,,,HABAGUSENGA,31/7/2018,N,,Male,2,,UWIFASHIJE,,1198570121139071,,,,,,,,,,, -242,242,,,IGIRANEZA CLEMENCE,23/7/2018,N,,Female,2,,MUKANDAYISENGA,,1199070234157047,,,,,,,,,,, -243,243,,,TUYISHIMIRE ERIC,24/9/2018,N,,Male,2,,MUKESHIMANA,,1198070108197098,,,,,,,,,,, -244,244,,,GANZA GEMUS,08-07-2018,N,,Male,2,,MUTUYIMANA,,120070001770082,,,,,,,,,,, -245,245,,,MANIRAHO JUSTIN,06-06-2018,N,,Male,2,,TUYISENGE,,1198470123088020,,,,,,,,,,, -246,246,,,ISHIMWE ,06-05-2018,N,,Male,2,,UWAMAHORO,,1199270006482056,,,,,,,,,,, -247,247,,,NIYONIRINGIRA,15/5/2018,N,,Male,2,,NIYITEGEKA,,1198570121116034,,,,,,,,,,, -248,248,,,IRATUZI,07-04-2018,N,,Male,2,,UWAMAHORO,,,,,,,,,,,,, -249,249,,,YUMVAGUSENGA,21/8/2018,N,,Male,2,,UWIMANA,,1199470059029096,,,,,,,,,,, -250,250,,,IRANEZEZA,10-10-2018,N,,Male,2,,UWAMAHORO,,1199570124007010,,,,,,,,,,, -251,251,,,HAKUZIMANA,10-05-2018,N,,Male,2,,NYIRABAZUNGU,,,,,,,,,,,,, -252,252,Legis,,NIYOKWIZERWA ,08-09-2017,N,,Male,2,,MUKAMUGENZA,,,,,,,,,,,,, diff --git a/server/hedley/modules/custom/hedley_migrate/csv/2019-05-3/mother.csv b/server/hedley/modules/custom/hedley_migrate/csv/2019-05-3/mother.csv deleted file mode 100644 index 5d5bbe3a12..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/csv/2019-05-3/mother.csv +++ /dev/null @@ -1,252 +0,0 @@ -Unique ID,First Name,Middle Name,Last Name,Date of Birth,Estimated (Y/N),Mother ID,Gender,Ubudehe,Education level,Profession,Marital Status,HIV Status,Household size,Number of Children,Phone,Province,District,Sector,Cell,Village,Health Center,Clinic,,, -2,,,INEZA ,1/1/1986,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -3,,,MANIRAFASHA,1/1/1981,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -4,,,UWERA,1/1/1989,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -5,,,RIZAHANANDE,1/1/1986,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -6,,,MUJAWAYEZU,,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,MBOGO,MINAZI,,,, -7,,,NTAWIHA,1/1/1992,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -8,,,NYIRAMBARUSHIMANA,1/1/1972,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -9,,,NAKURE,1/1/1982,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -10,,,NISENGWE,1/1/1996,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -11,,,NYIRABASHYITSI,1/1/1991,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -12,,,MUSABYIMANA,1/1/1978,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -13,,,NIRAGIRE,1/1/1991,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -14,,,UWINGABIRE,,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -15,,,NYIRANTEZIMANA,1/1/1973,Y,1198180101429082,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -16,,,UWIRAGIYE,1/1/1993,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -17,,,NYIRAMBITSAYIMANA,,Y,1198980120818015,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,NDEGAMIRE,MINAZI,,,, -18,,,UWIMANIMPAYE,,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,NDEGAMIRE,MINAZI,,,, -19,,,NYIRANDORIMANA,1/1/1987,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUNIHI,MINAZI,,,, -20,,,UWIFASHIJE,1/1/1993,Y,1198680122136089,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI,,,, -21,,,NYIRAHAVUGUZIGANYA,1/1/1989,Y,1196170036268014,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI,,,, -22,,,NYIRAMUGISHA,1/1/1986,Y,,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI,,,, -23,,,IRADUKUNDA,1/1/1997,Y,,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -24,,,TUYISHIMIRE,1/1/1994,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -25,,,KANKUNDIYE,1/1/1987,Y,1198270130839010,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -26,,,MWAMIKAZI,1/1/1987,Y,1199680006014032,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -27,,,NYIRAMAHIRWE,1/1/1976,Y,1199180105530032,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -28,,,UWIMANA,1/1/1992,Y,1197880087821087,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -29,,,BUCYENSENGE,1/1/1979,Y,1199170101826079,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUNIHI,MINAZI,,,, -30,,,MUKANDAYISENGA,1/1/1981,Y,119678004405736,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -31,,,NTAWUGIRIRINO,1/1/1996,Y,1197380060587083,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -32,,,NIKUZE,1/1/1985,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI,,,, -33,,,MUJAWIMANA,1/1/1984,Y,1199370106701019,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -34,,,MUKANDAYISENGA,1/1/1969,Y,11958005002655044,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -35,,,UGIRIWABO,1/1/1985,Y,1195280032465064,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -36,,,NYIRANIZEYIMANA,1/1/2000,Y,1198780164280065,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -37,,,YAMURAGIYE,1/1/1995,Y,1199380106665000,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -38,,,NISHIMWE,1/1/1987,Y,1198980117073036,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -39,,,NYIRANGIRIMANA,1/1/1983,Y,119867012230062,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -40,,,ISHIMWE RACHEL,1/1/1988,Y,119970128063030,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -41,,,UWIMANA,1/1/1981,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -42,,,MUKANTAMBARA,1/1/1981,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KANKA,MINAZI,,,, -43,,,UWIMANA,1/1/1995,Y,1198780118184099,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -44,,,MUSENGIMANA,1/1/1986,Y,1198780118092024,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -45,,,UWITIJE,1/1/1956,Y,1197680066309000,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -46,,,UWINGABIRE,1/1/1975,Y,119927004782010,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -47,,,MUKAMUGANGA,1/1/1978,Y,1197970084455074,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI,,,, -48,,,NYIRANSENGIMANA,,Y,1198170101419000,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI,,,, -49,,,NYIRANGENDAHIMANA,1/1/1986,Y,1199670102865009,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -50,,,NYIRANSANZAMAHORO,1/1/1987,Y,1198570121031086,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,BUKONDE,MINAZI,,,, -51,,,NYIRANKUNZIMANA,1/1/1995,Y,1198470126335056,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,BUKONDE,MINAZI,,,, -52,,,BIHOYIKI,1/1/1982,Y,1196980047501079,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,NDEGAMIRE,MINAZI,,,, -53,,,NYIRAMBONABUCYA,1/1/1984,Y,1198570119565072,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI,,,, -54,,,NYIRAMBARUSHIMANA,1/1/1990,Y,1194770014785090,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI,,,, -55,,,NYAMPUNDU,1/1/1995,Y,1195780034706045,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -56,,,MUREKATETE,1/1/1980,Y,1198780118156009,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -57,,,NYIRAHABIMANA,1/1/1989,Y,1198380115299061,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI,,,, -58,,,UWAGIRINSHUTI,1/1/1982,Y,1198580121058065,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -59,,,MUJAWAMARIYA,1/1/1990,Y,1198870125953082,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI,,,, -60,,,MUSABYEYEZU,1/1/1990,Y,1198180099156065,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI,,,, -61,,,TUYISABE,1/1/1981,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI,,,, -62,,,MUKANDAYAMBAJE,1/1/1986,Y,1199580085750002,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI,,,, -63,,,MUKESHIMANA,1/1/1981,Y,1198680122113052,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI,,,, -64,,,TWIZERIMANA,1/1/1973,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI,,,, -65,,,NYIRANKUNZURWANDA,1/1/1996,Y,1195680035909079,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,MBOGO,MINAZI,,,, -66,,,MUKANSANGA,1/1/1996,Y,1197570064853094,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,MBOGO,MINAZI,,,, -67,,,NYIRASAFARI,1/1/1996,Y,119780112001099,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,MBOGO,MINAZI,,,, -68,,,MUKAGASANA,1/1/1986,Y,1196880080321016,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI,,,, -69,,,UZAMUKUNDA,1/1/1992,Y,1194980018545004,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI,,,, -70,,,NYIRANSANZAMAHORO,1/1/1995,Y,119870118338085,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI,,,, -71,,,MUSANABERA,1/1/1987,Y,1199580163058005,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -72,,,MUGWANEZA,1/1/1993,Y,1198270130857198,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -73,,,NYIRANDIKUBWIMANA,1/1/1986,Y,119848126299037,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -74,,,NZAYITURIKI,1/1/2000,Y,1199080122060068,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -75,,,NYIRAHAFASHIMANA,1/1/1989,Y,1195870041611031,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI,,,, -76,,,NYIRAHAKIZIMANA,1/1/1988,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI,,,, -77,,,MANIKUZWA,1/1/1986,Y,1198070108293039,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI,,,, -78,,,NYIRANKWIYE,1/1/1990,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI,,,, -79,,,UWAMBAJIMANA,1/1/1994,Y,1198980120939067,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI,,,, -80,,,NZAMUKUNDA,1/1/1993,Y,1198270130873040,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI,,,, -81,,,KAMPIRE,1/1/1995,Y,1199070121912105,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -82,,,NYIRANGIRIMANA,1/1/1990,Y,1199070122076084,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -83,,,MUKANKAKA,1/1/1996,Y,1198180147394078,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -84,,,NIYONAMBAZA,1/1/1975,Y,1198680122064090,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -85,,,MUKESHIMANA,1/1/1981,Y,1198170007573043,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -86,,,MUSANBYIMANA,1/1/1981,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -87,,,BANYANGIRIKI,1/1/1982,Y,1197380060478093,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -88,,,MANIRAFASHA,1/1/1994,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -89,,,NTAWUSHIRAGAHINDA,1/1/1990,Y,,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -90,,,IRADUKUNDA,1/1/1994,Y,1199670076965003,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -91,,,UWAMAHORO,1/1/1995,Y,1194870018620093,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -92,,,NYIRAHABIYAKARE,1/1/1988,Y,1198670122097021,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -93,,,NIYOTWAGIRA,1/1/1987,Y,1199270047783064,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -94,,,UZAMUKUNDA,1/1/1987,Y,1199570123995039,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -95,,,MUREREYIMANA,1/1/1978,Y,1198380115238046,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -96,,,MUKANYABYENDA,1/1/1991,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI,,,, -97,,,UWIRINGIYIMANA,1/1/1987,Y,1199380106654025,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI,,,, -98,,,MUSHIMIYIMANA,1/1/1984,Y,1198670122214034,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI,,,, -99,,,MANIRAFASHA,1/1/1990,Y,1200070018096078,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -100,,,NYIRAMAJYAMBERE,1/1/1989,Y,1198970120806059,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -101,,,MANIRADUKUNDA,1/1/1979,Y,1198880126010052,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUNIHI,MINAZI,,,, -102,,,MBONIRERA,1/1/1995,Y,1198680181414062,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI,,,, -103,,,MUKASEKURU,1/1/1992,Y,1199080219254037,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI,,,, -104,,,MUSANGANIRE,1/1/1990,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI,,,, -105,,,MUKAHIGIRO,,Y,1199470185224044,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI,,,, -106,,,IYAMUREMYE,1/1/1987,Y,1199370014813089,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI,,,, -107,,,UWIRINGIYIMANA,1/1/1990,Y,1199580113115026,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI,,,, -108,,,MUKESHIMANA,1/1/1987,Y,1199080121973028,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYARUBUYE,MINAZI,,,, -109,,,NYIRANGAMIJIMANA,1/1/1978,Y,,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI,,,, -110,,,NDACYAYISENGA,1/1/1991,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -111,,,NTAWUKENABISHAKA,1/1/1972,Y,1199670102870062,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KABARIMA,MINAZI,,,, -112,,,NYIRANTEZIMANA,1/1/1977,Y,1197570064784056,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KABARIMA,MINAZI,,,, -113,,,AKIMANIZANYE,1/1/1994,Y,1198180101440075,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KABARIMA,MINAZI,,,, -114,,,AKIMANIZANYE,1/1/1987,Y,1198180101440075,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -115,,,MUSABAMAHORO,1/1/1996,Y,1198280130733093,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -116,,,AKIMANIZANYE,1/1/1994,Y,1199470060497075,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -117,,,TUYISENGE,1/1/1991,Y,1199070124880042,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -118,,,AYINKAMIYE,1/1/1996,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI,,,, -119,,,MUKANGAMIJE,1/1/1997,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI,,,, -120,,,ABIMANA,1/1/1991,Y,1199470060515086,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI,,,, -121,,,NTAKIRUTINKA,1/1/1994,Y,1199570103612025,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI,,,, -122,,,TUYISHIMIRE,1/1/1996,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -123,,,ABINGENEYE,1/1/1988,Y,119970045751046,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -124,,,KAMBUGURIJE,1/1/1988,Y,1198870126103020,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -125,,,NYIRANGENDAHIMANA,1/1/1995,Y,119877011830814,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUTARA,MINAZI,,,, -126,,,NYIRAMBABARIYE,,Y,1198780118308021,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI,,,, -127,,,YADUFASHIJE,1/1/1995,Y,1197870087801017,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI,,,, -128,,,NYIRANSANZAMAHORO,1/1/1991,Y,1199770105288007,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GAHARO,MINAZI,,,, -129,,,MUKAMURENZI,1/1/1983,Y,1198770120464061,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI,,,, -130,,,NYIRABASHYITSI,1/1/1984,Y,1198480126241001,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GIHINGA,MINAZI,,,, -131,,,MUKESHIMANA,1/1/1987,Y,1199070122045033,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI,,,, -132,,,TUYISENGE,1/1/1985,Y,1198980120775093,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI,,,, -133,,,NTAKIZANYIMA,1/1/1982,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI,,,, -134,,,TWIZERIMANA,,Y,1197970085860073,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI,,,, -135,,,AKITEGETSE,1/1/1996,Y,1198380096419061,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI,,,, -136,,,TUYISHIMIRE,1/1/1977,Y,1199270119317039,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -137,,,MANIRAGUHA,1/1/1992,Y,1199080122048088,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -138,,,NYIRANIZEYIMANA,1/1/1992,Y,1195480030158080,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -139,,,MUKADUNIYA,1/1/1983,Y,1198780118241075,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -140,,,NYIRABAGENZI,1/1/1996,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -141,,,NYIRANDIKUBWIMANA,1/1/1994,Y,1199080122040092,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -142,,,MANIRAGUHA,1/1/1993,Y,1197770070230044,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -143,,,MANIRAGUH HONOLINE,1/1/1987,Y,1198780118104084,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -144,,,UWIMANIMPAYE,1/1/1984,Y,1199670064284098,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -145,,,YAMBABARIYE,1/1/1991,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -146,,,UWIRAGIYE,1/1/1985,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -147,,,NTAKIRUTINKA,1/1/1992,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -148,,,NYIRANIZEYIMANA,1/1/1992,Y,1199470188318063,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -149,,,NZAMUKOSHA,1/1/1988,Y,1198770118096078,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -150,,,MUKAMURENZI,1/1/1993,Y,1197870087463063,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -151,,,NYIRAMAHORO,1/1/1994,Y,1198470126164049,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -152,,,NIYIGENA,1/1/1985,Y,1199170105359019,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KABARIMA,MINAZI,,,, -153,,,UMUHOZA,1/1/1994,Y,1197270061689047,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI,,,, -154,,,UWAYEZU,1/1/1996,Y,1198880027347090,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -155,,,MUSABEYEZU,1/1/1982,Y,1199170105436071,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -156,,,MASENGESHO,1/1/1985,Y,119967015117089,Female,1,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI,,,, -157,,,UMUHIRE,1/1/1998,Y,1199770023030073,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -158,,,TUYISHIMIRE,1/1/1990,Y,1195980044772094,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -159,,,TWAMBAJEMARIYA,1/1/1991,Y,1199170105385035,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI,,,, -160,,,MUKANKURANGA,1/1/1990,Y,1199470002525008,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -161,,,ISHIMWE RACHEL,1/1/1995,Y,'1199680009528083,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI,,,, -162,,,NYIRABIZEYIMANA,1/1/1991,Y,1198870123583010,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI,,,, -163,,,DUSABIMANA,1/1/1980,Y,11988701261102033,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -164,,,MUHAWENIMANA,1/1/1996,Y,1199570051681037,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -165,,,NYIRABAGABE,1/1/1982,Y,1196970015648082,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -166,,,NTAMABYARIRO,1/1/1976,Y,1199570028292013,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,SARABUYE,MINAZI,,,, -167,,,NYIRANSENGIYUMVA,1/1/1998,Y,119917003259058,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI,,,, -168,,,MUHAWENIMANA,1/1/1985,Y,'1198380115276024,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI,,,, -169,,,NIYONSABA,1/1/1996,Y,1198480126150013,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,GITARAGWE,MINAZI,,,, -170,,,NYIRAMAHIRWE,1/1/1990,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -171,,,MUKARWEGO,1/1/1995,Y,1198780118044058,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHOMBO,MINAZI,,,, -172,,,NAKURE,1/1/1977,Y,1198570120985085,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,NDEGAMIRE,MINAZI,,,, -173,,,NYIRANGARUKIYE,1/1/1998,Y,1198470127548083,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -174,,,NYIRAHABINEZA,1/1/1986,Y,1196680043541086,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -175,,,YANKURIJE,1/1/1995,Y,1199670076966090,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -176,,,MUKESHIMANA,1/1/1990,Y,1197770070157040,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -177,,,MUKAGASANA,1/1/1981,Y,119927047785038,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -178,,,TWIZERIMANA,1/1/1977,Y,1199280119309019,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GASANGWA,MINAZI,,,, -179,,,NDACYAYISENGA,1/1/1992,Y,1198380115328047,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -180,,,NYIRANSABIMANA,1/1/1973,Y,1199670064326033,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI,,,, -181,,,NIYONAMBAZA,1/1/1989,Y,1199470002587196,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,GISOVU,MINAZI,,,, -182,,,NIYOMUKIZA,1/1/1983,Y,1199370031040092,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,NYANZA,MINAZI,,,, -183,,,NYIRANSABIMANA,1/1/1976,Y,,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -184,,,UWIBAMBE,1/1/1983,Y,1198770118004012,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -185,,,YAMFASHIJE,1/1/1993,Y,1198470126199054,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,KIGEYO,MINAZI,,,, -186,,,NYIRANDUHUYE,1/1/1985,Y,1199180105414015,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -187,,,NYIRANZUBAHIMANA,1/1/1990,Y,1198570121115047,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GIHORORO,MINAZI,,,, -188,,,MUSABIMANA,1/1/1980,Y,1199270119302016,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,KABUGA,MINAZI,,,, -189,,,MUTUYIMANA,1/1/2000,Y,1199270119307051,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,NYABITARE,MINAZI,,,, -190,,,NYIRANSABIMANA,1/1/1984,Y,1198801125996089,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,GASIHO,GAHUNDA,MINAZI,,,, -191,,,NYIRAMAJYAMBERE,1/1/1992,Y,1199370106639090,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MURAMBI,MUSAVE,MINAZI,,,, -192,,,NYIRANSHIMIYIMANA,1/1/1985,Y,1199470002564073,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,KIVUBA,MINAZI,,,, -193,,,MBABARENGIRENTE,1/1/1994,Y,1198570121011010,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,RABA,MUNIHI,MINAZI,,,, -194,,,DUSABEYEZU,1/1/1995,Y,1199470002574147,Female,2,Primary School,farmer,,NEG,,,,NORTHERN PROVINCE,GAKENKE,MINAZI,MUNYANA,GITWA,MINAZI,,,, -195,,,MUTUYIMANA,1996,,1199670067111002,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -196,,,UWAMARIYA,1982,,1198270133785083,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -197,,,MUSABYIMANA,1985,,1198570120994086,,,Primary School,farmer,,POSITIVE,,,,,,,,,,,,, -198,,,URWIBUTSO,1998,,119987004743048,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -199,,,DUSABIMANA,1990,,1199070111238003,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -200,,,MUKASHYAKA,1991,,1199170105306018,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -201,,,MUKANKUNDIYE,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -202,,,MUKASHYAKA,1990,,1199070121941096,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -203,,,NYIRAMBARUBUKEYE,1995,,1199580021467026,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -204,,,IGIRANEZA,1991,,1199180105302064,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -205,,,NYIRAMAHINGURA,1980,,1198080108294020,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -206,,,DUSABEMARIYA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -207,,,NIYONIZERA,1996,,1199670009890071,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -208,,,NYIRANGIRENTE,1982,,1198270130676023,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -209,,,NYIRANIZEYIMANA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -210,,,NYIRANGIRABANZI,1976,,1197670066413061,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -211,,,UWERA,1998,,1199870075081030,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -212,,,NYIRANDIKUBWIMANA,1985,,1198570121261028,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -213,,,AKIMANA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -214,,,NIYOTWAMBAZA,1996,,119967073835020,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -215,,,NTABANGANYIMANA,1990,,1199070121583066,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -216,,,KANZAYIRE,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -217,,,NYIRANSENGIMANA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -218,,,UWUMUREMYI,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -219,,,MANIRAGUHA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -220,,,DUSABENDE,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -221,,,ZANINKA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -222,,,NYIRAHABIMANA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -223,,,NYIRAHABIMANA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -224,,,MUSABENDE,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -225,,,KAMPARA SOLANGE,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -226,,,UWIRINGIYIMANA,1995,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -227,,,MUSABYIMANA,1977,,1197770070127076,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -228,,,BIHOYIKI,1998,,1199870088217075,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -229,,,MANIRAFASHA,1986,,1198670122160037,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -230,,,NSEKANABANZI,1995,,1199570132314015,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -231,,,TWIZERIMANA,1990,,1199070121928029,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -232,,,MUKESHIMANA,1981,,1198170101445016,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -233,,,NYIRAMBARUSHIMANA,1977,,1197770070111066,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -234,,,NIYONAMBAZA,1992,,1199280119308032,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -235,,,NYIRABUHAKE,1973,,1197370060541015,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -236,,,NYIRABASHYITSI,1989,,1198970120861052,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -237,,,MUHAWENIMANA,1983,,1198370115375032,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -238,,,MUSABYEMARIYA,1976,,1197670066333048,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -239,,,MUKAMURENZI,1983,,1198370115283057,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -240,,,NYIRANSABIMANA,1993,,1199370106593007,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -241,,,UWIFASHIJE,1985,,1198570121139071,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -242,,,MUKANDAYISENGA,1990,,1199070234157047,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -243,,,MUKESHIMANA,1980,,1198070108197098,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -244,,,MUTUYIMANA,2000,,120070001770082,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -245,,,TUYISENGE,1984,,1198470123088020,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -246,,,UWAMAHORO,1992,,1199270006482056,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -247,,,NIYITEGEKA,1985,,1198570121116034,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -248,,,UWAMAHORO,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -249,,,UWIMANA,1994,,1199470059029096,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -250,,,UWAMAHORO,1995,,1199570124007010,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -251,,,NYIRABAZUNGU,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, -252,,,MUKAMUGENZA,,,,,,Primary School,farmer,,NEG,,,,,,,,,,,,, diff --git a/server/hedley/modules/custom/hedley_migrate/csv/acute_findings.csv b/server/hedley/modules/custom/hedley_migrate/csv/acute_findings.csv new file mode 100644 index 0000000000..09635fc3d8 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/acute_findings.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_findings_signs_general,field_findings_signs_respiratory +194,74,2020-06-19,188,1592244289,1,none,none +195,35,2017-12-16,188,1592244289,1,lethargic-or-unconscious|poor-suck|sunken-eyes,stridor|nasal-flaring +196,81,2020-08-07,188,1592244289,1,poor-skin-turgor|jaundice,severe-wheezing|sub-costal-retractions diff --git a/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_danger_signs.csv b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_danger_signs.csv new file mode 100644 index 0000000000..f4b9fc23ec --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_danger_signs.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_acute_illness_danger_signs +194,74,2020-06-19,188,1592244289,1,condition-not-improving|convulsions diff --git a/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_encounter.csv b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_encounter.csv new file mode 100644 index 0000000000..7c12a0ec66 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_encounter.csv @@ -0,0 +1,2 @@ +id,field_individual_participant,field_scheduled_date,created,field_acute_illness_diagnosis +1,3,2020-11-20,1592244289,covid19 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_muac.csv b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_muac.csv new file mode 100644 index 0000000000..cf410fa49a --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_muac.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_muac +194,74,2020-06-19,188,1592244289,1,12 +195,35,2017-12-16,188,1592244289,1,11.4 +196,81,2020-08-07,188,1592244289,1,13.6 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_nutrition.csv b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_nutrition.csv new file mode 100644 index 0000000000..d24de743f3 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_nutrition.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_nutrition_signs +194,74,2020-06-19,188,1592244289,1,none +195,35,2017-12-16,188,1592244289,1,poor-appetite|brittle-hair|brittle-hair|dry-skin +196,81,2020-08-07,188,1592244289,1,abdominal-distension|poor-appetite|brittle-hair diff --git a/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_vitals.csv b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_vitals.csv new file mode 100644 index 0000000000..ef54ba6846 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/acute_illness_vitals.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_respiratory_rate,field_body_temperature +194,74,2020-06-19,188,1592244289,1,22,37.1 +195,35,2017-12-16,188,1592244289,1,45,38.2 +196,81,2020-08-07,188,1592244289,1,34,39.2 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/attendance.csv b/server/hedley/modules/custom/hedley_migrate/csv/attendance.csv index 7974cfb93e..4be4754010 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/attendance.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/attendance.csv @@ -1 +1 @@ -id,field_person,field_date_measured,field_nurse,field_session,created,field_attended \ No newline at end of file +id,field_person,field_date_measured,field_nurse,created,field_session,field_attended \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/breast_exam.csv b/server/hedley/modules/custom/hedley_migrate/csv/breast_exam.csv new file mode 100644 index 0000000000..995539a51c --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/breast_exam.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_breast,field_breast_self_exam +194,74,2020-06-19,188,1592244289,1,normal,1 +195,35,2017-12-16,188,1592244289,1,mass|infection,0 +196,81,2020-08-07,188,1592244289,1,discharge|infection,1 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/call_114.csv b/server/hedley/modules/custom/hedley_migrate/csv/call_114.csv new file mode 100644 index 0000000000..16fbc35b44 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/call_114.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_114_contact,field_114_recommendation,field_site_recommendation +194,74,2020-06-19,188,1592244289,1,none,,, +195,35,2017-12-16,188,1592244289,1,contact-site,send-to-hc,team-to-village +196,81,2020-08-07,188,1592244289,1,contact-site|call-114,none-no-answer|none-other,team-to-village|n-a diff --git a/server/hedley/modules/custom/hedley_migrate/csv/child_fbf.csv b/server/hedley/modules/custom/hedley_migrate/csv/child_fbf.csv new file mode 100644 index 0000000000..b65358020e --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/child_fbf.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_session,field_distributed_amount,field_distribution_notice +219,67,2020-06-19,190,1592244289,209,8,complete +220,35,2017-12-16,190,1592244289,208,5.5,lack-of-stock +221,71,2020-08-07,190,1592244289,209,7.2,other \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/chw_deploy/village.csv b/server/hedley/modules/custom/hedley_migrate/csv/chw_deploy/village.csv deleted file mode 100644 index 104f73b126..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/csv/chw_deploy/village.csv +++ /dev/null @@ -1,191 +0,0 @@ -1,Amajyaruguru,Gakenke,Coko,Kiruku,Buhuri,7094 -2,Amajyaruguru,Gakenke,Coko,Kiruku,Bukamba,7094 -3,Amajyaruguru,Gakenke,Coko,Kiruku,Bushagashi,7094 -4,Amajyaruguru,Gakenke,Coko,Kiruku,Gatare,7094 -5,Amajyaruguru,Gakenke,Coko,Kiruku,Mucumazo,7094 -6,Amajyaruguru,Gakenke,Coko,Kiruku,Ntarabana,7094 -7,Amajyaruguru,Gakenke,Coko,Kiruku,Nyamasuka,7094 -8,Amajyaruguru,Gakenke,Coko,Kiruku,Rubuguma,7094 -9,Amajyaruguru,Gakenke,Coko,Nyanza,Baramba,7094 -10,Amajyaruguru,Gakenke,Coko,Nyanza,Gikamba,7094 -11,Amajyaruguru,Gakenke,Coko,Nyanza,Gitaba,7094 -12,Amajyaruguru,Gakenke,Coko,Nyanza,Kavumu,7094 -13,Amajyaruguru,Gakenke,Coko,Nyanza,Tumba,7094 -14,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,7089 -15,Amajyaruguru,Gakenke,Coko,Mbirima,Burengo,7089 -16,Amajyaruguru,Gakenke,Coko,Mbirima,Bushyama,7089 -17,Amajyaruguru,Gakenke,Coko,Mbirima,Matovu,7089 -18,Amajyaruguru,Gakenke,Coko,Mbirima,Mbogo,7089 -19,Amajyaruguru,Gakenke,Coko,Mbirima,Murambi,7089 -20,Amajyaruguru,Gakenke,Coko,Mbirima,Rwahi,7089 -21,Amajyaruguru,Gakenke,Coko,Mbirima,Shyunga,7089 -22,Amajyaruguru,Gakenke,Coko,Nyange,Buhara,7089 -23,Amajyaruguru,Gakenke,Coko,Nyange,Gaseke,7089 -24,Amajyaruguru,Gakenke,Coko,Nyange,Karambo,7089 -25,Amajyaruguru,Gakenke,Coko,Nyange,Karoli,7089 -26,Amajyaruguru,Gakenke,Coko,Nyange,Musasa,7089 -27,Amajyaruguru,Gakenke,Coko,Nyange,Ntobwe,7089 -28,Amajyaruguru,Gakenke,Coko,Nyange,Vumandi,7089 -29,Amajyaruguru,Gakenke,Rushashi,Mbogo,Bushoka,7091 -30,Amajyaruguru,Gakenke,Rushashi,Mbogo,Buzoza,7091 -31,Amajyaruguru,Gakenke,Rushashi,Mbogo,Gisanze,7091 -32,Amajyaruguru,Gakenke,Rushashi,Mbogo,Gitongo,7091 -33,Amajyaruguru,Gakenke,Rushashi,Mbogo,Nyabitare,7091 -34,Amajyaruguru,Gakenke,Rushashi,Shyombwe,Gatare,7091 -35,Amajyaruguru,Gakenke,Rushashi,Shyombwe,Gatwa,7091 -36,Amajyaruguru,Gakenke,Rushashi,Shyombwe,Gihororo,7091 -37,Amajyaruguru,Gakenke,Rushashi,Shyombwe,Murara,7091 -38,Amajyaruguru,Gakenke,Gashenyi,Rukura,Gahihi,7091 -39,Amajyaruguru,Gakenke,Gashenyi,Rukura,Gikoro,7091 -40,Amajyaruguru,Gakenke,Gashenyi,Rukura,Kara,7091 -41,Amajyaruguru,Gakenke,Gashenyi,Rukura,Kirambo,7091 -42,Amajyaruguru,Gakenke,Gashenyi,Rukura,Murandi,7091 -43,Amajyaruguru,Gakenke,Gashenyi,Rukura,Nyamataha,7091 -44,Amajyaruguru,Gakenke,Minazi,Gasiho,Gahombo,7095 -45,Amajyaruguru,Gakenke,Minazi,Gasiho,Gahunda,7095 -46,Amajyaruguru,Gakenke,Minazi,Gasiho,Gasangwa,7095 -47,Amajyaruguru,Gakenke,Minazi,Gasiho,Gihinga,7095 -48,Amajyaruguru,Gakenke,Minazi,Gasiho,Kabarima,7095 -49,Amajyaruguru,Gakenke,Minazi,Gasiho,Kigeyo,7095 -50,Amajyaruguru,Gakenke,Minazi,Gasiho,Mbogo,7095 -51,Amajyaruguru,Gakenke,Minazi,Munyana,Gihororo,7095 -52,Amajyaruguru,Gakenke,Minazi,Munyana,Gitwa,7095 -53,Amajyaruguru,Gakenke,Minazi,Munyana,Kanka,7095 -54,Amajyaruguru,Gakenke,Minazi,Munyana,Kivuba,7095 -55,Amajyaruguru,Gakenke,Minazi,Munyana,Nyabitare,7095 -56,Amajyaruguru,Gakenke,Minazi,Murambi,Gisovu,7095 -57,Amajyaruguru,Gakenke,Minazi,Murambi,Kabuga,7095 -58,Amajyaruguru,Gakenke,Minazi,Murambi,Musave,7095 -59,Amajyaruguru,Gakenke,Minazi,Murambi,Nyanza,7095 -60,Amajyaruguru,Gakenke,Minazi,Murambi,Nyarubuye,7095 -61,Amajyaruguru,Gakenke,Minazi,Raba,Bukonde,7095 -62,Amajyaruguru,Gakenke,Minazi,Raba,Gaharo,7095 -63,Amajyaruguru,Gakenke,Minazi,Raba,Gitaragwe,7095 -64,Amajyaruguru,Gakenke,Minazi,Raba,Munihi,7095 -65,Amajyaruguru,Gakenke,Minazi,Raba,Mutara,7095 -66,Amajyaruguru,Gakenke,Minazi,Raba,Ndegamire,7095 -67,Amajyaruguru,Gakenke,Minazi,Raba,Sarabuye,7095 -68,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,7090 -69,Amajyaruguru,Gakenke,Muhondo,Busake,Gikikira,7090 -70,Amajyaruguru,Gakenke,Muhondo,Busake,Kibirizi,7090 -71,Amajyaruguru,Gakenke,Muhondo,Busake,Nyakabanda,7090 -72,Amajyaruguru,Gakenke,Muhondo,Bwenda,Gahama,7090 -73,Amajyaruguru,Gakenke,Muhondo,Bwenda,Gatare,7090 -74,Amajyaruguru,Gakenke,Muhondo,Bwenda,Gitaba,7090 -75,Amajyaruguru,Gakenke,Muhondo,Bwenda,Kimanama,7090 -76,Amajyaruguru,Gakenke,Muhondo,Bwenda,Nketsi,7090 -77,Amajyaruguru,Gakenke,Muhondo,Gasiza,Gahabwa,7090 -78,Amajyaruguru,Gakenke,Muhondo,Gasiza,Gahinga,7090 -79,Amajyaruguru,Gakenke,Muhondo,Gasiza,Gahondo,7090 -80,Amajyaruguru,Gakenke,Muhondo,Gasiza,Gasiza,7090 -81,Amajyaruguru,Gakenke,Muhondo,Gasiza,Kabeza,7090 -82,Amajyaruguru,Gakenke,Muhondo,Gihinga,Base,7090 -83,Amajyaruguru,Gakenke,Muhondo,Gihinga,Gihinga,7090 -84,Amajyaruguru,Gakenke,Muhondo,Gihinga,Karehe,7090 -85,Amajyaruguru,Gakenke,Muhondo,Gihinga,Samuduha,7090 -86,Amajyaruguru,Gakenke,Muhondo,Gihinga,Taba,7090 -87,Amajyaruguru,Gakenke,Muhondo,Huro,Cura,7090 -88,Amajyaruguru,Gakenke,Muhondo,Huro,Gitwa,7090 -89,Amajyaruguru,Gakenke,Muhondo,Huro,Huro,7090 -90,Amajyaruguru,Gakenke,Muhondo,Huro,Kabuga,7090 -91,Amajyaruguru,Gakenke,Muhondo,Huro,Rubona,7090 -92,Amajyaruguru,Gakenke,Muhondo,Musagara,Akara,7090 -93,Amajyaruguru,Gakenke,Muhondo,Musagara,Cyenda,7090 -94,Amajyaruguru,Gakenke,Muhondo,Musagara,Giteme,7090 -95,Amajyaruguru,Gakenke,Muhondo,Musagara,Karobagire,7090 -96,Amajyaruguru,Gakenke,Muhondo,Musenyi,Buhinya,7090 -97,Amajyaruguru,Gakenke,Muhondo,Musenyi,Gakuyu,7090 -98,Amajyaruguru,Gakenke,Muhondo,Musenyi,Kigali,7090 -99,Amajyaruguru,Gakenke,Muhondo,Musenyi,Musenyi,7090 -100,Amajyaruguru,Gakenke,Muhondo,Ruganda,Gisozi,7090 -101,Amajyaruguru,Gakenke,Muhondo,Ruganda,Kinyonzo,7090 -102,Amajyaruguru,Gakenke,Muhondo,Ruganda,Mubuga,7090 -103,Amajyaruguru,Gakenke,Muhondo,Ruganda,Ranzi,7090 -104,Amajyaruguru,Gakenke,Muhondo,Ruganda,Ruganda,7090 -105,Amajyaruguru,Gakenke,Muhondo,Rwinkuba,Cyimbogo,7090 -106,Amajyaruguru,Gakenke,Muhondo,Rwinkuba,Kanyana,7090 -107,Amajyaruguru,Gakenke,Muhondo,Rwinkuba,Ruhorobero,7090 -108,Amajyaruguru,Gakenke,Muyongwe,Gisiza,Gitanda,7096 -109,Amajyaruguru,Gakenke,Muyongwe,Gisiza,Kabingo,7096 -110,Amajyaruguru,Gakenke,Muyongwe,Gisiza,Kiyebe,7096 -111,Amajyaruguru,Gakenke,Muyongwe,Gisiza,Muramba,7096 -112,Amajyaruguru,Gakenke,Muyongwe,Gisiza,Ruhoko,7096 -113,Amajyaruguru,Gakenke,Muyongwe,Gisiza,Sanzare,7096 -114,Amajyaruguru,Gakenke,Muyongwe,Karyango,Gikombe,7096 -115,Amajyaruguru,Gakenke,Muyongwe,Karyango,Kibingo,7096 -116,Amajyaruguru,Gakenke,Muyongwe,Karyango,Mahaha,7096 -117,Amajyaruguru,Gakenke,Muyongwe,Karyango,Mugera,7096 -118,Amajyaruguru,Gakenke,Muyongwe,Nganzo,Muhororo,7096 -119,Amajyaruguru,Gakenke,Muyongwe,Nganzo,Nganzo,7096 -120,Amajyaruguru,Gakenke,Muyongwe,Nganzo,Ngoma,7096 -121,Amajyaruguru,Gakenke,Muyongwe,Nganzo,Nyarubuye,7096 -122,Amajyaruguru,Gakenke,Muyongwe,Nganzo,Vugangoma,7096 -123,Amajyaruguru,Gakenke,Muyongwe,Va,Bukwera,7092 -124,Amajyaruguru,Gakenke,Muyongwe,Va,Businde,7092 -125,Amajyaruguru,Gakenke,Muyongwe,Va,Gikombe,7092 -126,Amajyaruguru,Gakenke,Muyongwe,Va,Mutoyi,7092 -127,Amajyaruguru,Gakenke,Muyongwe,Va,Ranzi,7092 -128,Amajyaruguru,Gakenke,Muyongwe,Bumba,Bumba,7092 -129,Amajyaruguru,Gakenke,Muyongwe,Bumba,Buzu,7092 -130,Amajyaruguru,Gakenke,Muyongwe,Bumba,Gikoro,7092 -131,Amajyaruguru,Gakenke,Muyongwe,Bumba,Gitovu,7092 -132,Amajyaruguru,Gakenke,Muyongwe,Bumba,Gitwe,7092 -133,Amajyaruguru,Gakenke,Muyongwe,Bumba,Mataba,7092 -134,Amajyaruguru,Gakenke,Muyongwe,Bumba,Shiru,7092 -135,Amajyaruguru,Gakenke,Rushashi,Rwankuba,Giheta,7092 -136,Amajyaruguru,Gakenke,Rushashi,Rwankuba,Ka7093,7092 -137,Amajyaruguru,Gakenke,Rushashi,Rwankuba,Ngambi,7092 -138,Amajyaruguru,Gakenke,Rushashi,Rwankuba,Ruganda,7092 -139,Amajyaruguru,Gakenke,Rushashi,Rwankuba,Rwamabega,7092 -140,Amajyaruguru,Gakenke,Rushashi,Burimba,Kabuye,7093 -141,Amajyaruguru,Gakenke,Rushashi,Burimba,Kara,7093 -142,Amajyaruguru,Gakenke,Rushashi,Burimba,Kivumu,7093 -143,Amajyaruguru,Gakenke,Rushashi,Busanane,Gisenyi,7093 -144,Amajyaruguru,Gakenke,Rushashi,Busanane,Gisiza,7093 -145,Amajyaruguru,Gakenke,Rushashi,Busanane,Kanzuki,7093 -146,Amajyaruguru,Gakenke,Rushashi,Busanane,Nyakagezi,7093 -147,Amajyaruguru,Gakenke,Rushashi,Joma,Kineza,7093 -148,Amajyaruguru,Gakenke,Rushashi,Joma,Mataba,7093 -149,Amajyaruguru,Gakenke,Rushashi,Joma,Mwifuzo,7093 -150,Amajyaruguru,Gakenke,Rushashi,Joma,Nyagasozi,7093 -151,Amajyaruguru,Gakenke,Rushashi,Joma,Rugarama,7093 -152,Amajyaruguru,Gakenke,Rushashi,Kageyo,Kabeza,7093 -153,Amajyaruguru,Gakenke,Rushashi,Kageyo,Kabona,7093 -154,Amajyaruguru,Gakenke,Rushashi,Kageyo,Karambi,7093 -155,Amajyaruguru,Gakenke,Rushashi,Kageyo,Murambi,7093 -156,Amajyaruguru,Gakenke,Rushashi,Kageyo,Nganzo,7093 -157,Amajyaruguru,Gakenke,Rushashi,Razi,Gahinga,7093 -158,Amajyaruguru,Gakenke,Rushashi,Razi,Gikongoro,7093 -159,Amajyaruguru,Gakenke,Rushashi,Razi,Kirwa,7093 -160,Amajyaruguru,Gakenke,Rushashi,Razi,Nkoto,7093 -161,Amajyaruguru,Gakenke,Rushashi,Razi,Nyangoyi,7093 -162,Amajyaruguru,Gakenke,Ruli,Busoro,Congoli,7088 -163,Amajyaruguru,Gakenke,Ruli,Busoro,Cyoganyoni,7088 -164,Amajyaruguru,Gakenke,Ruli,Busoro,Gitaba,7088 -165,Amajyaruguru,Gakenke,Ruli,Busoro,Kabare,7088 -166,Amajyaruguru,Gakenke,Ruli,Busoro,Kibirizi,7088 -167,Amajyaruguru,Gakenke,Ruli,Busoro,Nkoto,7088 -168,Amajyaruguru,Gakenke,Ruli,Busoro,Rugaragara,7088 -169,Amajyaruguru,Gakenke,Ruli,Gikingo,Bushoka,7088 -170,Amajyaruguru,Gakenke,Ruli,Gikingo,Gatwa,7088 -171,Amajyaruguru,Gakenke,Ruli,Gikingo,Kabingo,7088 -172,Amajyaruguru,Gakenke,Ruli,Gikingo,Karango,7088 -173,Amajyaruguru,Gakenke,Ruli,Gikingo,Nyamugari,7088 -174,Amajyaruguru,Gakenke,Ruli,Gikingo,Rumasa,7088 -175,Amajyaruguru,Gakenke,Ruli,Jango,Gatagara,7088 -176,Amajyaruguru,Gakenke,Ruli,Jango,Gihura,7088 -177,Amajyaruguru,Gakenke,Ruli,Jango,Gitonde,7088 -178,Amajyaruguru,Gakenke,Ruli,Jango,Kinyonzo,7088 -179,Amajyaruguru,Gakenke,Ruli,Jango,Mubuga,7088 -180,Amajyaruguru,Gakenke,Ruli,Jango,Murehe,7088 -181,Amajyaruguru,Gakenke,Ruli,Ruli,Bariza,7088 -182,Amajyaruguru,Gakenke,Ruli,Ruli,Gahondo,7088 -183,Amajyaruguru,Gakenke,Ruli,Ruli,Gataba,7088 -184,Amajyaruguru,Gakenke,Ruli,Ruli,Mugambazi,7088 -185,Amajyaruguru,Gakenke,Ruli,Ruli,Ngayake,7088 -186,Amajyaruguru,Gakenke,Ruli,Ruli,Nyakarambi,7088 -187,Amajyaruguru,Gakenke,Ruli,Rwesero,Gatare,7088 -188,Amajyaruguru,Gakenke,Ruli,Rwesero,Gisizi,7088 -189,Amajyaruguru,Gakenke,Ruli,Rwesero,Mabago,7088 -190,Amajyaruguru,Gakenke,Ruli,Rwesero,Mugwato,7088 -191,Amajyaruguru,Gakenke,Ruli,Rwesero,Nyarunyinya,7088 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/clinic.csv b/server/hedley/modules/custom/hedley_migrate/csv/clinic.csv index 5f6be6d81f..ff10d22246 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/clinic.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/clinic.csv @@ -1,7 +1,7 @@ id,title,field_group_type,field_health_center,created 92,Nyange I,fbf,4,1592244289 93,Nyagne II,pmtct,4,1592244289 -94,Muhondo I,fbf,5,1592244289 -95,Muhondo II,pmtct,5,1592244289 -96,Nyagne III,achi,4,1592244289 -97,Muhondo III,achi,5,1592244289 +94,Nyagne III,achi,4,1592244289 +95,Muhondo I,fbf,5,1592244289 +96,Muhondo II,pmtct,5,1592244289 +97,Muhondo III,achi,5,1592244289 \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/core_physical_exam.csv b/server/hedley/modules/custom/hedley_migrate/csv/core_physical_exam.csv new file mode 100644 index 0000000000..694283f241 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/core_physical_exam.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_head_hair,field_eyes,field_neck,field_heart,field_heart_murmur,field_lungs,field_abdomen,field_hands,field_legs +194,74,2020-06-19,188,1592244289,1,brittle-hair,pale-conjuctiva,enlarged-thyroid|enlarged-lymph-nodes,irregular-rhythm,1,wheezes,tender-to-palpitation-left-upper|hernia,normal,edema diff --git a/server/hedley/modules/custom/hedley_migrate/csv/danger_signs.csv b/server/hedley/modules/custom/hedley_migrate/csv/danger_signs.csv new file mode 100644 index 0000000000..c2f0e5a2d1 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/danger_signs.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_danger_signs +194,74,2020-06-19,188,1592244289,1,difficulty-breathing|fever diff --git a/server/hedley/modules/custom/hedley_migrate/csv/exposure.csv b/server/hedley/modules/custom/hedley_migrate/csv/exposure.csv new file mode 100644 index 0000000000..9aa9e85758 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/exposure.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_exposure +194,74,2020-06-19,188,1592244289,1,covid19-symptoms +195,35,2017-12-16,188,1592244289,1,none +196,81,2020-08-07,188,1592244289,1,covid19-symptoms|none diff --git a/server/hedley/modules/custom/hedley_migrate/csv/family_planning.csv b/server/hedley/modules/custom/hedley_migrate/csv/family_planning.csv index a6544b978e..ff77ddf160 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/family_planning.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/family_planning.csv @@ -1,21 +1,21 @@ -id,field_person,field_date_measured,field_nurse,field_session,created,field_family_planning_signs -194,74,2020-06-19,,191,1592244289,none|implant|none -195,35,2017-12-16,,190,1592244289,none|implant|implant|cycle-counting -196,81,2020-08-07,,191,1592244289,lactation-amenorrhea|none|implant|hysterectomy -197,61,2021-07-01,,191,1592244289,injection|necklace -198,53,2022-01-20,,190,1592244289,iud|implant|vasectomy -199,49,2019-10-23,,191,1592244289,hysterectomy|tubal-ligatures|hysterectomy|pill -200,80,2019-01-29,,191,1592244289,lactation-amenorrhea|spermicide -201,86,2021-09-11,,191,1592244289,iud|iud -202,62,2023-10-08,,190,1592244289,tubal-ligatures|lactation-amenorrhea|condoms -203,69,2018-01-26,,190,1592244289,vasectomy|spermicide|lactation-amenorrhea|vasectomy -204,34,2017-01-28,,190,1592244289,auto-observation|iud|vasectomy|pill -205,84,2021-05-02,,192,1592244289,condoms|vasectomy|cycle-counting -206,91,2021-02-16,,192,1592244289,cycle-counting|necklace -207,85,2023-08-04,,193,1592244289,spermicide|cycle-counting|tubal-ligatures -208,50,2017-11-15,,192,1592244289,lactation-amenorrhea|hysterectomy|condoms -209,7,2023-01-17,,193,1592244289,condoms|pill -210,16,2020-04-05,,192,1592244289,necklace|tubal-ligatures -211,80,2023-04-22,,192,1592244289,vasectomy|auto-observation|cycle-counting -212,61,2023-05-08,,193,1592244289,pill|iud -213,12,2020-07-29,,192,1592244289,implant|iud|cycle-counting \ No newline at end of file +id,field_person,field_date_measured,field_nurse,created,field_session,field_family_planning_signs +227,67,2020-06-19,191,1592244289,209,none|implant|none +228,35,2017-12-16,191,1592244289,208,none|implant|implant|cycle-counting +229,71,2020-08-07,191,1592244289,209,lactation-amenorrhea|none|implant|hysterectomy +230,54,2021-07-01,191,1592244289,209,injection|necklace +231,46,2022-01-20,191,1592244289,208,iud|implant|vasectomy +232,42,2019-10-23,191,1592244289,209,hysterectomy|tubal-ligatures|hysterectomy|pill +233,86,2019-01-29,191,1592244289,209,lactation-amenorrhea|spermicide +234,88,2021-09-11,191,1592244289,209,iud|iud +235,55,2023-10-08,191,1592244289,208,tubal-ligatures|lactation-amenorrhea|condoms +236,62,2018-01-26,191,1592244289,208,vasectomy|spermicide|lactation-amenorrhea|vasectomy +237,34,2017-01-28,191,1592244289,208,auto-observation|iud|vasectomy|pill +238,74,2021-05-02,191,1592244289,210,condoms|vasectomy|cycle-counting +239,87,2021-02-16,191,1592244289,210,cycle-counting|necklace +240,75,2023-08-04,191,1592244289,211,spermicide|cycle-counting|tubal-ligatures +241,43,2017-11-15,191,1592244289,210,lactation-amenorrhea|hysterectomy|condoms +242,7,2023-01-17,191,1592244289,211,condoms|pill +243,16,2020-04-05,191,1592244289,210,necklace|tubal-ligatures +244,86,2023-04-22,191,1592244289,210,vasectomy|auto-observation|cycle-counting +245,54,2023-05-08,191,1592244289,211,pill|iud +246,12,2020-07-29,191,1592244289,210,implant|iud|cycle-counting \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/hc_contact.csv b/server/hedley/modules/custom/hedley_migrate/csv/hc_contact.csv new file mode 100644 index 0000000000..0a402332c1 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/hc_contact.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_hc_contact,field_hc_recommendation,field_hc_response_time,field_ambulance_arrival_time +194,74,2020-06-19,188,1592244289,1,none,n-a,n-a,n-a +195,35,2017-12-16,188,1592244289,1,contact-hc,come-to-hc,less-than-30m|2h-1d,n-a +196,81,2020-08-07,188,1592244289,1,contact-hc,chw-monitoring,1h-2h,n-a diff --git a/server/hedley/modules/custom/hedley_migrate/csv/health_education.csv b/server/hedley/modules/custom/hedley_migrate/csv/health_education.csv new file mode 100644 index 0000000000..c59950ec26 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/health_education.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_health_education_signs +194,74,2020-06-19,188,1592244289,1,education-for-diagnosis diff --git a/server/hedley/modules/custom/hedley_migrate/csv/height.csv b/server/hedley/modules/custom/hedley_migrate/csv/height.csv index 077d3ae632..1c51df7630 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/height.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/height.csv @@ -1,21 +1,21 @@ -id,field_person,field_date_measured,field_nurse,field_session,created,field_height,field_zscore_age -214,82,2019-09-08,,191,1592244289,84,0.231998 -215,39,2023-01-06,,191,1592244289,109, -216,19,2017-07-13,,190,1592244289,119, -217,73,2020-06-18,,191,1592244289,60,-8.66428 -218,19,2019-03-17,,191,1592244289,37, -219,80,2021-06-13,,191,1592244289,92,-0.378823 -220,86,2017-09-18,,190,1592244289,87, -221,25,2021-08-07,,190,1592244289,160, -222,19,2018-10-22,,190,1592244289,134, -223,53,2017-02-23,,190,1592244289,103, -224,13,2023-03-29,,191,1592244289,70, -225,42,2020-03-02,,192,1592244289,86, -226,50,2017-02-22,,193,1592244289,98, -227,54,2021-09-01,,192,1592244289,103,1.1539 -228,46,2022-11-09,,193,1592244289,141, -229,45,2022-02-28,,192,1592244289,51, -230,40,2018-04-17,,192,1592244289,104, -231,91,2018-09-10,,193,1592244289,141, -232,29,2017-12-18,,192,1592244289,140, -233,55,2018-04-24,,193,1592244289,143, \ No newline at end of file +id,field_person,field_date_measured,field_nurse,created,field_session,field_height,field_zscore_age +250,72,2019-09-08,190,1592244289,209,84,0.243676 +251,36,2023-01-06,190,1592244289,209,109, +252,19,2017-07-13,190,1592244289,208,119, +253,66,2020-06-18,190,1592244289,209,60,-8.65916 +254,19,2019-03-17,190,1592244289,209,37, +255,86,2021-06-13,190,1592244289,209,92,-0.372429 +256,88,2017-09-18,190,1592244289,208,87, +257,25,2021-08-07,190,1592244289,208,160, +258,19,2018-10-22,190,1592244289,208,134, +259,46,2017-02-23,190,1592244289,208,103, +260,13,2023-03-29,190,1592244289,209,70, +261,39,2020-03-02,190,1592244289,210,86, +262,43,2017-02-22,190,1592244289,211,98, +263,47,2021-09-01,190,1592244289,210,103,1.15945 +264,82,2022-11-09,190,1592244289,211,141, +265,81,2022-02-28,190,1592244289,210,51, +266,37,2018-04-17,190,1592244289,210,104, +267,87,2018-09-10,190,1592244289,211,141, +268,29,2017-12-18,190,1592244289,210,140, +269,48,2018-04-24,190,1592244289,211,143, \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/individual_participant.csv b/server/hedley/modules/custom/hedley_migrate/csv/individual_participant.csv index e93d9264ee..c39782d961 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/individual_participant.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/individual_participant.csv @@ -1,2 +1,4 @@ -id,field_person,field_expected,field_encounter_type -1,6,2019-04-27,antenatal +id,field_person,field_expected,field_encounter_type,field_date_concluded,field_outcome,field_outcome_location,field_expected_date_concluded,created +1,6,2019-04-27,antenatal,2019-06-28,live-at-term,home,2019-06-21,1592244289 +2,6,2020-10-27,nutrition,,,,,1592244289 +3,6,2020-10-29,acute-illness,,,,,1592244289 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/isolation.csv b/server/hedley/modules/custom/hedley_migrate/csv/isolation.csv new file mode 100644 index 0000000000..22590aee7e --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/isolation.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_isolation,field_reason_for_not_isolating +194,74,2020-06-19,188,1592244289,1,none,no-space|can-not-separate| +195,35,2017-12-16,188,1592244289,1,patient-isolated|sign-on-door,n-a +196,81,2020-08-07,188,1592244289,1,sign-on-door|health-education,too-ill diff --git a/server/hedley/modules/custom/hedley_migrate/csv/lactation.csv b/server/hedley/modules/custom/hedley_migrate/csv/lactation.csv new file mode 100644 index 0000000000..7ea92336ba --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/lactation.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_session,field_lactation_signs +273,67,2020-06-19,190,1592244289,209,none|breastfeeding +274,35,2017-12-16,190,1592244289,208,none +275,71,2020-08-07,190,1592244289,209,breastfeeding \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/last_menstrual_period.csv b/server/hedley/modules/custom/hedley_migrate/csv/last_menstrual_period.csv new file mode 100644 index 0000000000..da7687534e --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/last_menstrual_period.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_last_menstrual_period,field_confident +194,74,2020-06-19,188,1592244289,1,2020-09-19,0 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/malaria_testing.csv b/server/hedley/modules/custom/hedley_migrate/csv/malaria_testing.csv new file mode 100644 index 0000000000..888f46ea19 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/malaria_testing.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_malaria_rapid_test +194,74,2020-06-19,188,1592244289,1,positive +195,35,2017-12-16,188,1592244289,1,negative +196,81,2020-08-07,188,1592244289,1,indeterminate diff --git a/server/hedley/modules/custom/hedley_migrate/csv/medical_history.csv b/server/hedley/modules/custom/hedley_migrate/csv/medical_history.csv new file mode 100644 index 0000000000..912850832c --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/medical_history.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_medical_history +194,74,2020-06-19,188,1592244289,1,cardiac-disease|asthma|hiv diff --git a/server/hedley/modules/custom/hedley_migrate/csv/medication.csv b/server/hedley/modules/custom/hedley_migrate/csv/medication.csv new file mode 100644 index 0000000000..be26f3c564 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/medication.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_medication +194,74,2020-06-19,188,1592244289,1,iron-and-folic-acid-supplement|deworming-pill diff --git a/server/hedley/modules/custom/hedley_migrate/csv/medication_distribution.csv b/server/hedley/modules/custom/hedley_migrate/csv/medication_distribution.csv new file mode 100644 index 0000000000..a36a717a9e --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/medication_distribution.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_prescribed_medication,field_non_administration_reason +194,74,2020-06-19,188,1592244289,1,none,none +195,35,2017-12-16,188,1592244289,1,lemon-juice-or-honey|zinc,zinc-other +196,81,2020-08-07,188,1592244289,1,amoxicillin|coartem|ors,ors-patient-declined|coartem-known-allergy diff --git a/server/hedley/modules/custom/hedley_migrate/csv/missing.csv b/server/hedley/modules/custom/hedley_migrate/csv/missing.csv deleted file mode 100644 index 9fbc1c934e..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/csv/missing.csv +++ /dev/null @@ -1,157 +0,0 @@ -id,field_session,field_date_measured,field_child,field_weight,field_height,field_muac -missing_1,2324,2018-04-05,1965,10.2,78,13.8 -missing_2,2324,2018-04-05,3666,7.4,68.5,12.8 -missing_3,4059,2018-07-19,3666,8.4,72.4,13.5 -missing_4,2324,2018-04-05,1950,8.6,74,13.7 -missing_5,4059,2018-07-19,1950,9.8,79.2,13.5 -missing_6,2324,2018-04-05,1956,8.3,71,14.5 -missing_7,4059,2018-07-19,1956,9.4,73,15.3 -missing_8,2324,2018-04-05,1944,9.4,78.3,14.5 -missing_9,4059,2018-07-19,1944,10.3,83,13.7 -missing_10,2324,2018-04-05,1952,9.5,72,15.2 -missing_11,4059,2018-07-19,1952,9.2,75.6,15 -missing_12,2324,2018-04-05,1982,10.1,78,14.5 -missing_13,4059,2018-07-19,1982,11,82.3,15 -missing_14,2324,2018-04-05,1954,9.6,72,15 -missing_15,4059,2018-07-19,1954,10.6,75.7,15.2 -missing_16,2324,2018-04-05,1959,7.8,69,13.7 -missing_17,4059,2018-07-19,1959,8.8,72.5,13.5 -missing_18,2324,2018-04-05,1963,11.3,85.6,14.1 -missing_19,4059,2018-07-19,1963,12.2,90,14 -missing_20,2311,2018-04-05,1466,13.4,90,15 -missing_21,4058,2018-07-19,1466,14.1,91.2,15.5 -missing_22,2311,2018-04-05,1464,13.1,94,14 -missing_23,4058,2018-07-19,1464,13.8,95.1,14.3 -missing_24,2311,2018-04-05,1208,16.8,104,15 -missing_25,4058,2018-07-19,1208,17.9,106.2,15 -missing_26,2311,2018-04-05,3571,17,100,15.5 -missing_27,4058,2018-07-19,3571,17.8,102.7,16.2 -missing_28,2311,2018-04-05,1479,14.2,97,15 -missing_29,4058,2018-07-19,1479,15.3,98.2,15.1 -missing_30,2311,2018-04-05,1351,15.9,99,16 -missing_31,4058,2018-07-19,1351,17,100.2,16 -missing_32,2311,2018-04-05,1433,15.6,96.5,14.5 -missing_33,4058,2018-07-19,1433,14.1,98.5,15.2 -missing_34,2311,2018-04-05,3567,15.1,101.5,14.5 -missing_35,4058,2018-07-19,3567,16.2,104.3,15 -missing_36,2311,2018-04-05,3561,8.2,71,12.7 -missing_37,2311,2018-04-05,1452,14.7,102,14.5 -missing_38,2311,2018-04-05,1515,19.7,104.5,17 -missing_39,2311,2018-04-05,3563,6.2,65.9,12 -missing_40,2311,2018-04-05,1501,13.2,93.5,14 -missing_41,4058,2018-07-19,1501,13.8,97.2,14.2 -missing_42,2311,2018-04-05,3565,8.3,63,n/a -missing_43,2311,2018-04-05,1459,16.4,101,16 -missing_44,4058,2018-07-19,1459,18.5,102,16.8 -missing_45,2311,2018-04-05,1325,19.5,111.2,16.5 -missing_46,4058,2018-07-19,1325,19.3,112.3,15.2 -missing_47,2311,2018-04-05,3569,18.6,107,17 -missing_48,4058,2018-07-19,3569,19.3,109.3,16.3 -missing_49,2311,2018-04-05,1400,14.3,94.2,16 -missing_50,4058,2018-07-19,1400,15.2,96.7,15.5 -missing_51,2311,2018-04-05,1508,13.9,102,13.5 -missing_52,4058,2018-07-19,1508,15.1,104.3,13.3 -missing_53,2311,2018-04-05,3573,16.4,100.5,15 -missing_54,4058,2018-07-19,3573,16.8,102.3,15 -missing_55,2311,2018-04-05,1471,14.5,95.5,15.5 -missing_56,4058,2018-07-19,1471,15.3,96.3,15.6 -missing_57,2311,2018-04-05,1359,14.5,106,14.5 -missing_58,4058,2018-07-19,1359,16.6,107.1,107.1 -missing_59,2311,2018-04-05,1281,15.6,104,15 -missing_60,4058,2018-07-19,1281,17.2,106,15 -missing_61,2311,2018-04-05,1342,18.8,109,15.5 -missing_62,4058,2018-07-19,1342,19.1,111.2,14.8 -missing_63,2309,2018-04-05,2026,18.4,108,16 -missing_64,3669,2018-07-18,2026,18.4,108,16.9 -missing_65,2309,2018-04-05,2030,17.5,100,16 -missing_66,3669,2018-07-18,2030,17.5,103.5,16.9 -missing_67,2309,2018-04-05,1880,16,98,17 -missing_68,3669,2018-07-18,1880,15.7,99,17 -missing_69,2309,2018-04-05,2062,12.9,94,14.5 -missing_70,3669,2018-07-18,2062,14.6,96,15.5 -missing_71,2309,2018-04-05,3583,17.3,101.2,16 -missing_72,3669,2018-07-18,3583,17.2,103.1,16 -missing_73,2309,2018-04-05,3599,14.2,95.5,15 -missing_74,3669,2018-07-18,3599,14.5,98,15 -missing_75,2309,2018-04-05,2075,18.8,103,16.5 -missing_76,3669,2018-07-18,2075,17.1,104,15.5 -missing_77,3669,2018-07-18,2079,16.1,107.5,15.5 -missing_78,2309,2018-04-05,2079,15.4,106.5,14 -missing_79,2309,2018-04-05,3585,18.5,106,15 -missing_80,3669,2018-07-18,3585,19,106.5,15 -missing_81,2309,2018-04-05,2089,18.2,107.5,16 -missing_82,3669,2018-07-18,2089,18.1,109,15.9 -missing_83,2309,2018-04-05,3592,18.5,110,16 -missing_84,3669,2018-07-18,3592,19.7,110.5,16.5 -missing_85,2309,2018-04-05,2093,15.1,98,15 -missing_86,3669,2018-07-18,2093,15.4,99.9,14.6 -missing_87,2309,2018-04-05,2102,13.1,95,14 -missing_88,3669,2018-07-18,2102,14.3,96.5,15 -missing_89,2309,2018-04-05,2126,20,107,17.2 -missing_90,3669,2018-07-18,2126,20.1,108.5,17.6 -missing_91,2309,2018-04-05,2139,16.5,102,16 -missing_92,3669,2018-07-18,2139,17.1,108.6,15.5 -missing_93,2309,2018-04-05,2147,16.7,104,15.5 -missing_94,3669,2018-07-18,2147,17.3,107,16 -missing_95,2309,2018-04-05,1925,16.5,105.5,15.2 -missing_96,3669,2018-07-18,1925,16.4,106.5,15.5 -missing_97,2309,2018-04-05,2158,20.2,109,15.5 -missing_98,3669,2018-07-18,2158,20.3,111,14.9 -missing_99,2309,2018-04-05,2161,15.8,99.5,15 -missing_100,3669,2018-07-18,2161,16.2,101.3,15.5 -missing_101,2309,2018-04-05,2172,15.4,103.5,15 -missing_102,3669,2018-07-18,2172,15.8,104.7,14.9 -missing_103,2309,2018-04-05,3157,16.8,108.2,15 -missing_104,3669,2018-07-18,3157,17.6,110,15.8 -missing_105,2309,2018-04-05,2182,18.7,101,17 -missing_106,3669,2018-07-18,2182,19.7,104,17 -missing_107,2309,2018-04-05,2187,17.4,107,16 -missing_108,3669,2018-07-18,2187,17.7,108,16 -missing_109,2309,2018-04-05,1869,14.8,89.5,17 -missing_110,3669,2018-07-18,1869,15.5,92,16.8 -missing_111,2309,2018-04-05,2195,15.9,99.2,15 -missing_112,3669,2018-07-18,2195,16,100.5,15.5 -missing_113,2309,2018-04-05,1795,15.8,104,15.5 -missing_114,3669,2018-07-18,1795,18.1,106.3,15.6 -missing_115,2309,2018-04-05,1796,17.8,106,16.5 -missing_116,3669,2018-07-18,1796,19,107.2,17 -missing_117,2309,2018-04-05,1798,15.3,98,15 -missing_118,3669,2018-07-18,1798,16.5,101.4,15.5 -missing_119,2309,2018-04-05,1799,19,111.5,15.5 -missing_120,3669,2018-07-18,1799,20.1,113.2,16 -missing_121,2309,2018-04-05,3586,18.2,105.5,15.5 -missing_122,3669,2018-07-18,3586,19.8,106.1,17.2 -missing_123,2309,2018-04-05,1801,17.5,105.5,15.5 -missing_124,3669,2018-07-18,1801,20.2,106.5,17.1 -missing_125,2309,2018-04-05,3587,14.6,102,14 -missing_126,3669,2018-07-18,3587,15.2,104,14 -missing_127,2309,2018-04-05,1805,16.9,96.7,18 -missing_128,3669,2018-07-18,1805,17.1,99,16.8 -missing_129,2309,2018-04-05,1807,16.1,99,16 -missing_130,3669,2018-07-18,1807,16.5,102,15.8 -missing_131,2309,2018-04-05,1810,15.3,101.2,15.5 -missing_132,3669,2018-07-18,1810,14,102,16 -missing_133,2309,2018-04-05,1811,14.5,101,15.5 -missing_134,3669,2018-07-18,1811,15.1,102.2,15.5 -missing_135,2309,2018-04-05,1812,16.1,100.5,15 -missing_137,2309,2018-04-05,3588,17.9,108,15.5 -missing_138,3669,2018-07-18,3588,19,111,15.5 -missing_139,2309,2018-04-05,1819,17.3,103,16.5 -missing_140,3669,2018-07-18,1819,17.5,105,16 -missing_141,2309,2018-04-05,1823,15.3,98,15 -missing_142,3669,2018-07-18,1823,15.8,105,16.2 -missing_143,2309,2018-04-05,3590,15.1,103,14 -missing_144,3669,2018-07-18,3590,15.7,104.5,15.3 -missing_145,2309,2018-04-05,3593,19.9,112.5,16 -missing_146,3669,2018-07-18,3593,20,114.3,15.6 -missing_147,2309,2018-04-05,4528,17.6,103,16 -missing_149,2309,2018-04-05,1842,17.3,103.5,16.5 -missing_150,3669,2018-07-18,1842,17.3,105,16.8 -missing_151,2309,2018-04-05,3595,17,109,15.5 -missing_152,3669,2018-07-18,3595,17.4,110.5,15.3 -missing_153,2309,2018-04-05,3597,20.4,114,16 -missing_154,3669,2018-07-18,3597,20.3,116,17.5 -missing_155,2309,2018-04-05,1862,18.3,102,17.5 -missing_156,3669,2018-07-18,1862,19.4,106,17.3 -missing_157,2309,2018-04-05,1866,15.8,100,16 -missing_158,3669,2018-07-18,1866,16.5,102.5,16.5 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/mother_fbf.csv b/server/hedley/modules/custom/hedley_migrate/csv/mother_fbf.csv new file mode 100644 index 0000000000..d2aa2f9ccc --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/mother_fbf.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_session,field_distributed_amount,field_distribution_notice +285,67,2020-06-19,191,1592244289,209,2.5,complete +286,35,2017-12-16,191,1592244289,208,1.5,lack-of-stock +287,71,2020-08-07,191,1592244289,209,1.2,other \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/muac.csv b/server/hedley/modules/custom/hedley_migrate/csv/muac.csv index 8b796f053f..149518b11f 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/muac.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/muac.csv @@ -1,21 +1,21 @@ -id,field_person,field_date_measured,field_nurse,field_session,created,field_muac -235,84,2023-01-13,,191,1592244289,26 -236,10,2020-10-16,,190,1592244289,32 -237,88,2018-03-10,,191,1592244289,33 -238,62,2020-10-20,,191,1592244289,33 -239,63,2020-01-17,,191,1592244289,22 -240,47,2023-04-23,,191,1592244289,26 -241,21,2021-12-08,,191,1592244289,32 -242,26,2017-09-03,,190,1592244289,39 -243,91,2020-11-03,,191,1592244289,23 -244,74,2021-11-01,,190,1592244289,23 -245,64,2019-01-22,,193,1592244289,23 -246,40,2022-06-08,,193,1592244289,31 -247,91,2019-01-30,,193,1592244289,23 -248,67,2021-07-08,,192,1592244289,25 -249,54,2023-05-04,,192,1592244289,16 -250,14,2017-06-29,,193,1592244289,14 -251,81,2019-05-14,,192,1592244289,16 -252,34,2022-01-02,,193,1592244289,11 -253,88,2023-10-01,,193,1592244289,33 -254,8,2021-03-13,,193,1592244289,11 \ No newline at end of file +id,field_person,field_date_measured,field_nurse,created,field_session,field_muac +288,74,2023-01-13,191,1592244289,209,26 +289,10,2020-10-16,191,1592244289,208,32 +290,90,2018-03-10,191,1592244289,209,33 +291,55,2020-10-20,191,1592244289,209,33 +292,56,2020-01-17,191,1592244289,209,22 +293,83,2023-04-23,191,1592244289,209,26 +294,21,2021-12-08,191,1592244289,209,32 +295,26,2017-09-03,191,1592244289,208,39 +296,87,2020-11-03,191,1592244289,209,23 +297,67,2021-11-01,191,1592244289,208,23 +298,57,2019-01-22,191,1592244289,211,23 +299,37,2022-06-08,191,1592244289,211,31 +300,87,2019-01-30,191,1592244289,211,23 +301,60,2021-07-08,191,1592244289,210,25 +302,47,2023-05-04,191,1592244289,210,16 +303,14,2017-06-29,191,1592244289,211,14 +304,71,2019-05-14,191,1592244289,210,16 +305,34,2022-01-02,191,1592244289,211,11 +306,90,2023-10-01,191,1592244289,211,33 +307,8,2021-03-13,191,1592244289,211,11 \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/nurse.csv b/server/hedley/modules/custom/hedley_migrate/csv/nurse.csv index 08bc59d0c5..ab213441a6 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/nurse.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/nurse.csv @@ -1,3 +1,5 @@ id,title,field_role,field_health_centers,field_villages,field_pin_code,created 188,Maya,nurse,4|5,,1234,1592244289 -189,Jojo,chw,4|5,138|163,2345,1592244289 \ No newline at end of file +189,Jojo,chw,4|5,140|165,2345,1592244289 +190,PhePhe,nurse,4|5,,4321,1592244289 +191,YumYum,chw,4|5,140|165,5432,1592244289 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/nutrition.csv b/server/hedley/modules/custom/hedley_migrate/csv/nutrition.csv index bf18420ae4..0fa742b81d 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/nutrition.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/nutrition.csv @@ -1,21 +1,21 @@ -id,field_person,field_date_measured,field_nurse,field_session,created,field_nutrition_signs -255,40,2017-08-25,,191,1592244289,none|edema|dry-skin -256,47,2017-04-12,,190,1592244289,poor-appetite|dry-skin|poor-appetite|none -257,13,2022-08-30,,191,1592244289,none|brittle-hair|edema|poor-appetite -258,82,2017-01-12,,190,1592244289,dry-skin|dry-skin -259,67,2018-03-15,,191,1592244289,none -260,9,2021-06-04,,190,1592244289,none -261,83,2018-06-03,,192,1592244289,edema|apathy|dry-skin|poor-appetite -262,72,2021-07-07,,192,1592244289,apathy -263,17,2023-04-16,,193,1592244289,brittle-hair|none|none|apathy -264,47,2018-08-05,,192,1592244289,dry-skin|poor-appetite|none|dry-skin -265,59,2018-08-10,,193,1592244289,abdominal-distension|edema|apathy|none -266,55,2017-03-16,,193,1592244289,none|none -267,81,2023-03-19,,193,1592244289,none|poor-appetite -268,73,2023-09-14,,193,1592244289,brittle-hair|none -269,65,2019-05-21,,193,1592244289,edema|brittle-hair|none -270,14,2021-07-26,,192,1592244289,edema|poor-appetite|brittle-hair|edema -271,69,2021-12-22,,193,1592244289,poor-appetite -272,79,2019-01-21,,192,1592244289,abdominal-distension -273,13,2019-06-24,,193,1592244289,poor-appetite|brittle-hair|brittle-hair|dry-skin -274,49,2023-09-08,,193,1592244289,abdominal-distension|poor-appetite|brittle-hair \ No newline at end of file +id,field_person,field_date_measured,field_nurse,created,field_session,field_nutrition_signs +321,37,2017-08-25,190,1592244289,209,none|edema|dry-skin +322,83,2017-04-12,190,1592244289,208,poor-appetite|dry-skin|poor-appetite|none +323,13,2022-08-30,190,1592244289,209,none|brittle-hair|edema|poor-appetite +324,72,2017-01-12,190,1592244289,208,dry-skin|dry-skin +325,60,2018-03-15,190,1592244289,209,none +326,9,2021-06-04,190,1592244289,208,none +327,73,2018-06-03,190,1592244289,210,edema|apathy|dry-skin|poor-appetite +328,65,2021-07-07,190,1592244289,210,apathy +329,17,2023-04-16,190,1592244289,211,brittle-hair|none|none|apathy +330,83,2018-08-05,190,1592244289,210,dry-skin|poor-appetite|none|dry-skin +331,52,2018-08-10,190,1592244289,211,abdominal-distension|edema|apathy|none +332,48,2017-03-16,190,1592244289,211,none|none +333,71,2023-03-19,190,1592244289,211,none|poor-appetite +334,66,2023-09-14,190,1592244289,211,brittle-hair|none +335,58,2019-05-21,190,1592244289,211,edema|brittle-hair|none +336,14,2021-07-26,190,1592244289,210,edema|poor-appetite|brittle-hair|edema +337,62,2021-12-22,190,1592244289,211,poor-appetite +338,85,2019-01-21,190,1592244289,210,abdominal-distension +339,13,2019-06-24,190,1592244289,211,poor-appetite|brittle-hair|brittle-hair|dry-skin +340,42,2023-09-08,190,1592244289,211,abdominal-distension|poor-appetite|brittle-hair \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/nutrition_encounter.csv b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_encounter.csv new file mode 100644 index 0000000000..25bfdcef98 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_encounter.csv @@ -0,0 +1,2 @@ +id,field_individual_participant,field_scheduled_date,created +1991,2,2020-10-27,1592244289 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/nutrition_height.csv b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_height.csv new file mode 100644 index 0000000000..6bdde3b60e --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_height.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_nutrition_encounter,field_height,field_zscore_age +272,79,2019-01-21,188,1592244289,1991,84,0.231998 +273,13,2019-06-24,188,1592244289,1991,109, +274,49,2023-09-08,188,1592244289,1991,72,-1.32 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/nutrition_muac.csv b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_muac.csv new file mode 100644 index 0000000000..8d0a641351 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_muac.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_nutrition_encounter,field_muac +272,79,2019-01-21,188,1592244289,1991,11.4 +273,13,2019-06-24,188,1592244289,1991,12.6 +274,49,2023-09-08,188,1592244289,1991,13 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/nutrition_nutrition.csv b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_nutrition.csv new file mode 100644 index 0000000000..cca8c99ec0 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_nutrition.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_nutrition_encounter,field_nutrition_signs +272,79,2019-01-21,188,1592244289,1991,none +273,13,2019-06-24,188,1592244289,1991,poor-appetite|brittle-hair|brittle-hair|dry-skin +274,49,2023-09-08,188,1592244289,1991,abdominal-distension|poor-appetite|brittle-hair diff --git a/server/hedley/modules/custom/hedley_migrate/csv/nutrition_photo.csv b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_photo.csv new file mode 100644 index 0000000000..63ba2c5933 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_photo.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_nutrition_encounter,field_photo +272,79,2019-01-21,188,1592244289,1991,baby-boy-1.jpg +273,13,2019-06-24,188,1592244289,1991,baby-boy-3.jpg +274,49,2023-09-08,188,1592244289,1991,baby-boy-2.jpg diff --git a/server/hedley/modules/custom/hedley_migrate/csv/nutrition_weight.csv b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_weight.csv new file mode 100644 index 0000000000..3f5ba83efb --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/nutrition_weight.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_nutrition_encounter,field_weight,field_bmi,field_zscore_age,field_zscore_length,field_zscore_bmi +272,79,2019-01-21,188,1592244289,1991,21,,2.43748,, +273,13,2019-06-24,188,1592244289,1991,58,,39.5565,, +274,49,2023-09-08,188,1592244289,1991,25,,,, diff --git a/server/hedley/modules/custom/hedley_migrate/csv/obstetric_history.csv b/server/hedley/modules/custom/hedley_migrate/csv/obstetric_history.csv new file mode 100644 index 0000000000..50b055de61 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/obstetric_history.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_currently_pregnant,field_term_pregnancy,field_preterm_pregnancy,field_stillbirths_at_term,field_stillbirths_preterm,field_abortions,field_live_children +194,74,2020-06-19,188,1592244289,1,1,2,0,1,3,2,1 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/obstetric_history_step2.csv b/server/hedley/modules/custom/hedley_migrate/csv/obstetric_history_step2.csv new file mode 100644 index 0000000000..95e847e66a --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/obstetric_history_step2.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_c_sections,field_c_section_reason,field_previous_delivery_period,field_obstetric_history,field_previous_delivery +194,74,2020-06-19,188,1592244289,1,2,failure-to-progress|other,more-than-5-years,preeclampsia-previous-pregnancy|rh-negative,convulsions-and-unconscious-previous-delivery|partial-placenta-previous-delivery diff --git a/server/hedley/modules/custom/hedley_migrate/csv/obstetrical_exam.csv b/server/hedley/modules/custom/hedley_migrate/csv/obstetrical_exam.csv new file mode 100644 index 0000000000..dec321cb39 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/obstetrical_exam.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_fundal_height,field_fetal_presentation,field_fetal_movement,field_fetal_heart_rate,field_c_section_scar +194,74,2020-06-19,188,1592244289,1,25.1,breech,1,130,horizontal diff --git a/server/hedley/modules/custom/hedley_migrate/csv/person.csv b/server/hedley/modules/custom/hedley_migrate/csv/person.csv index b24a28e1a1..942ee8857a 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/person.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/person.csv @@ -1,87 +1,87 @@ id,title,field_first_name,field_second_name,field_gender,field_birth_date,field_health_center,field_birth_date_estimated,field_hmis_number,field_marital_status,field_education_level,field_ubudehe,field_province,field_district,field_sector,field_cell,field_village,field_hiv_status,field_mode_of_delivery,field_number_of_children,field_photo,field_national_id_number,field_phone_number,created -6,Iradukunda Ariella,Ariella,Iradukunda,female,1995-12-31,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-4.jpg,1199270128356057,0794806678,1592244289 -7,Iradukunda Ines,Ines,Iradukunda,female,1997-01-31,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270104452037,0733124814,1592244289 -8,Iradukunda Anaelle,Anaelle,Iradukunda,female,1998-05-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-7.jpg,1199270156714251,0763657154,1592244289 -9,Iradukunda Queen,Queen,Iradukunda,female,1995-02-04,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-2.jpg,1199270181345450,0776421491,1592244289 -10,Iradukunda Daniella,Daniella,Iradukunda,female,1987-02-02,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270123949852,0723124412,1592244289 -11,Iradukunda Ingrid,Ingrid,Iradukunda,female,1988-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-7.jpg,1199270108917942,0700803061,1592244289 -12,Iradukunda Itta,Itta,Iradukunda,female,1992-02-05,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270188065432,0708873650,1592244289 -13,Iradukunda Stecy,Stecy,Iradukunda,female,1984-01-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-5.jpg,1199270183115977,0714570972,1592244289 -14,Iradukunda Olga,Olga,Iradukunda,female,1988-03-02,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-2.jpg,1199270193228432,0724482588,1592244289 -15,Iradukunda Gossy,Gossy,Iradukunda,female,1997-02-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-4.jpg,1199270157273998,0784644922,1592244289 -16,Iradukunda Elisa,Elisa,Iradukunda,female,1996-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270151283759,0748374472,1592244289 -17,Iradukunda Ange,Ange,Iradukunda,female,1987-08-08,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-2.jpg,1199270151679066,0779957357,1592244289 -18,Iradukunda Daenah,Daenah,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270164045651,0767496737,1592244289 -19,Iradukunda Benitha,Benitha,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270100560182,0707495104,1592244289 -20,Iradukunda Ketsia,Ketsia,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-1.jpg,1199270136357619,0768315110,1592244289 -21,Iradukunda Vanessa,Vanessa,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-4.jpg,1199270164704584,0739358449,1592244289 -22,Iradukunda Aurore,Aurore,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270111982129,0765633311,1592244289 -23,Iradukunda Ollia,Ollia,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-4.jpg,1199270150247541,0774271177,1592244289 -24,Iradukunda Orietta,Orietta,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-1.jpg,1199270174581451,0713351329,1592244289 -25,Iradukunda Huguette,Huguette,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-3.jpg,1199270171909449,0727164944,1592244289 -26,Iradukunda Nadege,Nadege,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270143128494,0751314354,1592244289 -27,Iradukunda Nadia,Nadia,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-4.jpg,1199270158114596,0716063158,1592244289 -28,Iradukunda Larissa,Larissa,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270130014158,0731741061,1592244289 -29,Iradukunda Raissa,Raissa,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270115529736,0794328252,1592244289 -30,Iradukunda Vanette,Vanette,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-6.jpg,1199270175485376,0789845935,1592244289 -31,Iradukunda Sylvana,Sylvana,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-5.jpg,1199270190678710,0794163641,1592244289 -32,Iradukunda Kendra,Kendra,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-5.jpg,1199270186657277,0794382201,1592244289 -33,Iradukunda Ornella,Ornella,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-4.jpg,1199270184031135,0791899521,1592244289 -34,Iradukunda Eva,Eva,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270124408989,0703992487,1592244289 -35,Iradukunda Annet,Annet,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270114047740,0718155400,1592244289 -36,Iradukunda Suzan,Suzan,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-4.jpg,1199270193332048,0799271826,1592244289 -37,Iradukunda Alphonsine,Alphonsine,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270170494599,0797783753,1592244289 -38,Iradukunda Marcelline,Marcelline,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-2.jpg,1199270196191149,0708947087,1592244289 -39,Iradukunda Chantal,Chantal,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270117743225,0729681618,1592244289 -40,Iradukunda Agnes,Agnes,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-5.jpg,1199270169857844,0792580420,1592244289 -41,Iradukunda Pamela,Pamela,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-1.jpg,1199270169350884,0788146091,1592244289 -42,Iradukunda Jeannette,Jeannette,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-7.jpg,1199270161910285,0707762291,1592244289 -43,Iradukunda Antoinette,Antoinette,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270124451049,0713703368,1592244289 -44,Iradukunda Claudette,Claudette,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270183537705,0791346862,1592244289 -45,Iradukunda Claudine,Claudine,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-4.jpg,1199270155815156,0701986737,1592244289 -46,Iradukunda Berthe,Berthe,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270114887927,0711655839,1592244289 -47,Iradukunda Bellancile,Bellancile,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-5.jpg,1199270100438909,0737479204,1592244289 -48,Iradukunda Ernest,Ernest,Iradukunda,male,2018-09-26,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-4.jpg,1199270180467617,0758750596,1592244289 -49,Iradukunda Sylvia,Sylvia,Iradukunda,female,2018-09-30,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-1.jpg,1199270197046270,0748766330,1592244289 -50,Iradukunda Arsene,Arsene,Iradukunda,male,2018-07-05,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-2.jpg,1199270135780640,0753049022,1592244289 -51,Iradukunda Adeline,Adeline,Iradukunda,female,2018-08-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-1.jpg,1199270162700527,0700148834,1592244289 -52,Iradukunda Adela,Adela,Iradukunda,female,2018-02-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-1.jpg,1199270114165135,0764981119,1592244289 -53,Iradukunda Odette,Odette,Iradukunda,female,2018-09-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-3.jpg,1199270130992374,0719780939,1592244289 -54,Iradukunda Julia,Julia,Iradukunda,female,2018-04-05,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-3.jpg,1199270124789633,0752892002,1592244289 -55,Iradukunda Isabelle,Isabelle,Iradukunda,female,2018-10-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-3.jpg,1199270153085209,0700987030,1592244289 -56,Iradukunda Epiphanie,Epiphanie,Iradukunda,female,2018-03-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-4.jpg,1199270176251216,0794345784,1592244289 -57,Iradukunda Yvone,Yvone,Iradukunda,female,2018-03-08,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-2.jpg,1199270187652285,0759112339,1592244289 -58,Iradukunda Rose,Rose,Iradukunda,female,2018-09-09,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-2.jpg,1199270154973528,0713671811,1592244289 -59,Iradukunda Maria,Maria,Iradukunda,female,2018-06-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-1.jpg,1199270109799113,0710989919,1592244289 -60,Iradukunda Anne,Anne,Iradukunda,female,2018-04-06,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-2.jpg,1199270192850305,0751808970,1592244289 -61,Iradukunda Marie,Marie,Iradukunda,female,2018-09-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-3.jpg,1199270154296059,0759794502,1592244289 -62,Iradukunda Soline,Soline,Iradukunda,female,2018-07-05,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-1.jpg,1199270130908205,0723860186,1592244289 -63,Iradukunda Ancille,Ancille,Iradukunda,female,2018-01-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-3.jpg,1199270113607436,0745909711,1592244289 -64,Iradukunda Jacqueline,Jacqueline,Iradukunda,female,2018-09-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-1.jpg,1199270197102451,0764259068,1592244289 -65,Iradukunda Clarisse,Clarisse,Iradukunda,female,2018-02-04,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-4.jpg,1199270195298184,0765089536,1592244289 -66,Iradukunda Anitha,Anitha,Iradukunda,female,2018-07-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-1.jpg,1199270113784903,0782425725,1592244289 -67,Tuyizere Ariella,Ariella,Tuyizere,female,2018-02-06,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-4.jpg,1199270128820025,0743589910,1592244289 -68,Tuyizere Ines,Ines,Tuyizere,female,2018-09-05,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-2.jpg,1199270198707873,0763425283,1592244289 -69,Iradukunda Angelo,Angelo,Iradukunda,male,2018-02-07,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270111828383,0743670072,1592244289 -70,Iradukunda Yannick,Yannick,Iradukunda,male,2018-07-05,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270169505093,0744690767,1592244289 -71,Iradukunda Yvan,Yvan,Iradukunda,male,2018-12-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-1.jpg,1199270185294296,0786202874,1592244289 -72,Iradukunda Ian,Ian,Iradukunda,male,2018-09-08,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-1.jpg,1199270134658321,0797848842,1592244289 -73,Iradukunda Gaelle,Gaelle,Iradukunda,male,2018-10-06,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270187414111,0736577246,1592244289 -74,Iradukunda Christian,Christian,Iradukunda,male,2018-01-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-2.jpg,1199270132335125,0755646451,1592244289 -75,Iradukunda Jean-Luc,Jean-Luc,Iradukunda,male,2018-10-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-1.jpg,1199270188456461,0795859598,1592244289 -76,Iradukunda Steven,Steven,Iradukunda,male,2018-05-26,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-2.jpg,1199270125931945,0783277060,1592244289 -77,Iradukunda Henry,Henry,Iradukunda,male,2018-03-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-2.jpg,1199270109172292,0763774734,1592244289 -78,Iradukunda Olivier,Olivier,Iradukunda,male,2018-10-14,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270116002967,0790182250,1592244289 -79,Iradukunda Jimmy,Jimmy,Iradukunda,male,2018-07-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-2.jpg,1199270111437219,0798062057,1592244289 -80,Iradukunda Rene,Rene,Iradukunda,male,2018-10-16,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270106053760,0747026266,1592244289 -81,Iradukunda Joel,Joel,Iradukunda,male,2018-04-30,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-1.jpg,1199270197843098,0740105185,1592244289 -82,Iradukunda Kyle,Kyle,Iradukunda,male,2018-02-04,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-1.jpg,1199270138837525,0791510050,1592244289 -83,Iradukunda Elyse,Elyse,Iradukunda,male,2018-01-16,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-2.jpg,1199270112504477,0702730348,1592244289 -84,Iradukunda Avi,Avi,Iradukunda,male,2018-09-30,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-3.jpg,1199270162365575,0704189334,1592244289 -85,Iradukunda Liam,Liam,Iradukunda,male,2018-05-07,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-2.jpg,1199270169294529,0798842803,1592244289 -86,Iradukunda Vivens,Vivens,Iradukunda,male,2018-09-30,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-2.jpg,1199270131015939,0791305300,1592244289 -87,Iradukunda Honore,Honore,Iradukunda,male,2018-05-06,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-1.jpg,1199270105408964,0709526392,1592244289 -88,Iradukunda Robert,Robert,Iradukunda,male,2018-01-04,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-2.jpg,1199270155315297,0748190877,1592244289 -89,Iradukunda Patrick,Patrick,Iradukunda,male,2018-08-07,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-1.jpg,1199270198028807,0784584989,1592244289 -90,Iradukunda Janvier,Janvier,Iradukunda,male,2018-11-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-2.jpg,1199270194084086,0751323490,1592244289 -91,Tuyizere Anaelle,Anaelle,Tuyizere,female,1989-06-06,5,,,,,,,,,,,,,,mother-5.jpg,1199270192279588,0700547974,1592244289 \ No newline at end of file +6,Iradukunda Ariella,Ariella,Iradukunda,female,1995-12-31,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-4.jpg,1199270166285559,0715566915,1592244289 +7,Iradukunda Ines,Ines,Iradukunda,female,1997-01-31,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270196137691,0736240277,1592244289 +8,Iradukunda Anaelle,Anaelle,Iradukunda,female,1998-05-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-4.jpg,1199270192154022,0753913276,1592244289 +9,Iradukunda Queen,Queen,Iradukunda,female,1995-02-04,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-4.jpg,1199270168069408,0714857960,1592244289 +10,Iradukunda Daniella,Daniella,Iradukunda,female,1987-02-02,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-4.jpg,1199270148625863,0754551150,1592244289 +11,Iradukunda Ingrid,Ingrid,Iradukunda,female,1988-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270132524602,0742557129,1592244289 +12,Iradukunda Itta,Itta,Iradukunda,female,1992-02-05,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270128258585,0736201047,1592244289 +13,Iradukunda Stecy,Stecy,Iradukunda,female,1984-01-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-4.jpg,1199270148239495,0790985243,1592244289 +14,Iradukunda Olga,Olga,Iradukunda,female,1988-03-02,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270167972281,0764582345,1592244289 +15,Iradukunda Gossy,Gossy,Iradukunda,female,1997-02-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-2.jpg,1199270104390498,0778701773,1592244289 +16,Iradukunda Elisa,Elisa,Iradukunda,female,1996-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270196877103,0706431233,1592244289 +17,Iradukunda Ange,Ange,Iradukunda,female,1987-08-08,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-1.jpg,1199270184143806,0789988133,1592244289 +18,Iradukunda Daenah,Daenah,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270178108217,0766571299,1592244289 +19,Iradukunda Benitha,Benitha,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-1.jpg,1199270128794061,0709885412,1592244289 +20,Iradukunda Ketsia,Ketsia,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-1.jpg,1199270116400902,0716164298,1592244289 +21,Iradukunda Vanessa,Vanessa,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-3.jpg,1199270160344725,0721208858,1592244289 +22,Iradukunda Aurore,Aurore,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-5.jpg,1199270192286670,0700913633,1592244289 +23,Iradukunda Ollia,Ollia,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-5.jpg,1199270131780016,0737872634,1592244289 +24,Iradukunda Orietta,Orietta,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-3.jpg,1199270191724815,0785039488,1592244289 +25,Iradukunda Huguette,Huguette,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-1.jpg,1199270150504575,0794283594,1592244289 +26,Iradukunda Nadege,Nadege,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-2.jpg,1199270166139284,0777359848,1592244289 +27,Iradukunda Nadia,Nadia,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-7.jpg,1199270157291339,0713666260,1592244289 +28,Iradukunda Larissa,Larissa,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-6.jpg,1199270120605306,0755768200,1592244289 +29,Iradukunda Raissa,Raissa,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-7.jpg,1199270110369986,0732713407,1592244289 +30,Iradukunda Vanette,Vanette,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270125371070,0742366662,1592244289 +31,Iradukunda Sylvana,Sylvana,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-7.jpg,1199270177306330,0746164367,1592244289 +32,Iradukunda Kendra,Kendra,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-5.jpg,1199270160697151,0738286073,1592244289 +33,Iradukunda Ornella,Ornella,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-3.jpg,1199270118284233,0702711489,1592244289 +34,Iradukunda Eva,Eva,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-5.jpg,1199270196365075,0784764456,1592244289 +35,Iradukunda Annet,Annet,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-6.jpg,1199270142771755,0716342583,1592244289 +36,Iradukunda Suzan,Suzan,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-2.jpg,1199270106490232,0793927519,1592244289 +37,Iradukunda Alphonsine,Alphonsine,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270197029403,0762583308,1592244289 +38,Iradukunda Marcelline,Marcelline,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-2.jpg,1199270179946295,0724031896,1592244289 +39,Iradukunda Chantal,Chantal,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-2.jpg,1199270178274223,0780214023,1592244289 +40,Iradukunda Agnes,Agnes,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-2.jpg,1199270161985415,0794517919,1592244289 +41,Iradukunda Ernest,Ernest,Iradukunda,male,2018-09-26,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-4.jpg,1199270177498016,0722964859,1592244289 +42,Iradukunda Pamela,Pamela,Iradukunda,female,2018-09-30,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-3.jpg,1199270128970453,0795513768,1592244289 +43,Iradukunda Arsene,Arsene,Iradukunda,male,2018-07-05,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-2.jpg,1199270156210263,0751626745,1592244289 +44,Iradukunda Jeannette,Jeannette,Iradukunda,female,2018-08-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-3.jpg,1199270101876935,0744692860,1592244289 +45,Iradukunda Antoinette,Antoinette,Iradukunda,female,2018-02-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-2.jpg,1199270127274431,0715120215,1592244289 +46,Iradukunda Claudette,Claudette,Iradukunda,female,2018-09-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-3.jpg,1199270107918833,0780032918,1592244289 +47,Iradukunda Claudine,Claudine,Iradukunda,female,2018-04-05,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-2.jpg,1199270135398244,0786688104,1592244289 +48,Iradukunda Berthe,Berthe,Iradukunda,female,2018-10-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-2.jpg,1199270111009124,0704013908,1592244289 +49,Iradukunda Bellancile,Bellancile,Iradukunda,female,2018-03-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-2.jpg,1199270138741800,0783257512,1592244289 +50,Iradukunda Sylvia,Sylvia,Iradukunda,female,2018-03-08,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-1.jpg,1199270162242311,0765036866,1592244289 +51,Iradukunda Adeline,Adeline,Iradukunda,female,2018-09-09,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-2.jpg,1199270172591473,0738804987,1592244289 +52,Iradukunda Adela,Adela,Iradukunda,female,2018-06-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-4.jpg,1199270110273432,0793802050,1592244289 +53,Iradukunda Odette,Odette,Iradukunda,female,2018-04-06,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-4.jpg,1199270117302239,0774597228,1592244289 +54,Iradukunda Julia,Julia,Iradukunda,female,2018-09-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-3.jpg,1199270162196906,0780524586,1592244289 +55,Iradukunda Isabelle,Isabelle,Iradukunda,female,2018-07-05,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-3.jpg,1199270109254245,0738833016,1592244289 +56,Iradukunda Epiphanie,Epiphanie,Iradukunda,female,2018-01-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-3.jpg,1199270191765981,0786331555,1592244289 +57,Iradukunda Yvone,Yvone,Iradukunda,female,2018-09-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-4.jpg,1199270109405364,0761096060,1592244289 +58,Iradukunda Rose,Rose,Iradukunda,female,2018-02-04,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-3.jpg,1199270100758622,0786931102,1592244289 +59,Iradukunda Maria,Maria,Iradukunda,female,2018-07-01,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-1.jpg,1199270136254593,0716177034,1592244289 +60,Iradukunda Anne,Anne,Iradukunda,female,2018-02-06,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-girl-4.jpg,1199270159080605,0783468469,1592244289 +61,Iradukunda Marie,Marie,Iradukunda,female,2018-09-05,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-girl-4.jpg,1199270130245909,0715620441,1592244289 +62,Iradukunda Angelo,Angelo,Iradukunda,male,2018-02-07,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-3.jpg,1199270181166512,0790907655,1592244289 +63,Iradukunda Yannick,Yannick,Iradukunda,male,2018-07-05,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-1.jpg,1199270178299686,0786440050,1592244289 +64,Iradukunda Yvan,Yvan,Iradukunda,male,2018-12-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270158509850,0780948930,1592244289 +65,Iradukunda Ian,Ian,Iradukunda,male,2018-09-08,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270117609457,0794327419,1592244289 +66,Iradukunda Gaelle,Gaelle,Iradukunda,male,2018-10-06,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-2.jpg,1199270173526888,0712780315,1592244289 +67,Iradukunda Christian,Christian,Iradukunda,male,2018-01-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-3.jpg,1199270110232990,0782920141,1592244289 +68,Iradukunda Jean-Luc,Jean-Luc,Iradukunda,male,2018-10-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270183014418,0721525689,1592244289 +69,Iradukunda Steven,Steven,Iradukunda,male,2018-05-26,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270142379316,0787162470,1592244289 +70,Iradukunda Henry,Henry,Iradukunda,male,2018-03-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-2.jpg,1199270113336470,0742265148,1592244289 +71,Iradukunda Olivier,Olivier,Iradukunda,male,2018-04-30,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270178173892,0725871853,1592244289 +72,Iradukunda Jimmy,Jimmy,Iradukunda,male,2018-02-04,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-3.jpg,1199270177771083,0749917555,1592244289 +73,Iradukunda Rene,Rene,Iradukunda,male,2018-01-16,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-2.jpg,1199270102945163,0704977695,1592244289 +74,Iradukunda Joel,Joel,Iradukunda,male,2018-09-30,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-3.jpg,1199270164171667,0783180829,1592244289 +75,Iradukunda Kyle,Kyle,Iradukunda,male,2018-05-07,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-4.jpg,1199270184480474,0747426762,1592244289 +76,Iradukunda Soline,Soline,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270193040110,0763896218,1592244289 +77,Iradukunda Ancille,Ancille,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-1.jpg,1199270143729419,0797852223,1592244289 +78,Iradukunda Jacqueline,Jacqueline,Iradukunda,female,1992-01-03,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,mother-7.jpg,1199270187818687,0736543709,1592244289 +79,Iradukunda Elyse,Elyse,Iradukunda,male,2018-11-04,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270142446702,0736030176,1592244289 +80,Iradukunda Clarisse,Clarisse,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-4.jpg,1199270154265061,0795843727,1592244289 +81,Iradukunda Anitha,Anitha,Iradukunda,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270112675292,0772355912,1592244289 +82,Tuyizere Ariella,Ariella,Tuyizere,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-5.jpg,1199270163720794,0797898182,1592244289 +83,Tuyizere Ines,Ines,Tuyizere,female,1992-01-03,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,mother-6.jpg,1199270189971280,0739750296,1592244289 +84,Iradukunda Avi,Avi,Iradukunda,male,2018-10-14,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270109337587,0797532721,1592244289 +85,Iradukunda Liam,Liam,Iradukunda,male,2018-07-01,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270170021524,0753250697,1592244289 +86,Iradukunda Vivens,Vivens,Iradukunda,male,2018-10-16,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-1.jpg,1199270148923903,0725003150,1592244289 +87,Tuyizere Anaelle,Anaelle,Tuyizere,female,1989-06-06,5,,,,,,,,,,,,,,mother-4.jpg,1199270166165884,0702784342,1592244289 +88,Iradukunda Honore,Honore,Iradukunda,male,2018-09-30,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-3.jpg,1199270123579645,0706723225,1592244289 +89,Iradukunda Robert,Robert,Iradukunda,male,2018-05-06,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-4.jpg,1199270150716038,0780440977,1592244289 +90,Iradukunda Patrick,Patrick,Iradukunda,male,2018-01-04,4,,,,,,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,,,,baby-boy-4.jpg,1199270171661855,0705144494,1592244289 +91,Iradukunda Janvier,Janvier,Iradukunda,male,2018-08-07,5,,,,,,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,,,,baby-boy-4.jpg,1199270128413102,0789637229,1592244289 \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/photo.csv b/server/hedley/modules/custom/hedley_migrate/csv/photo.csv index 88161db700..073f6efd7d 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/photo.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/photo.csv @@ -1,21 +1,21 @@ -id,field_person,field_date_measured,field_nurse,field_session,created,field_photo -275,77,2019-11-14,,190,1592244289,baby-boy-3.jpg -276,11,2021-09-19,,190,1592244289,mother-3.jpg -277,7,2019-09-12,,190,1592244289,mother-2.jpg -278,28,2019-09-21,,190,1592244289,mother-5.jpg -279,50,2017-01-18,,193,1592244289,baby-boy-1.jpg -280,17,2021-10-07,,193,1592244289,mother-5.jpg -281,29,2020-05-07,,192,1592244289,mother-2.jpg -282,53,2023-01-17,,193,1592244289,baby-girl-2.jpg -283,51,2022-06-07,,192,1592244289,baby-girl-2.jpg -284,30,2022-05-07,,192,1592244289,mother-3.jpg -285,34,2023-01-07,,192,1592244289,mother-5.jpg -286,31,2022-03-12,,193,1592244289,mother-2.jpg -287,24,2021-02-21,,192,1592244289,mother-7.jpg -288,84,2023-12-05,,192,1592244289,baby-boy-3.jpg -289,10,2019-02-20,,193,1592244289,mother-7.jpg -290,50,2017-08-11,,193,1592244289,baby-boy-1.jpg -291,27,2020-03-17,,193,1592244289,mother-4.jpg -292,44,2022-08-10,,193,1592244289,mother-1.jpg -293,71,2021-12-08,,192,1592244289,baby-boy-3.jpg -294,82,2018-02-17,,193,1592244289,baby-boy-3.jpg \ No newline at end of file +id,field_person,field_date_measured,field_nurse,created,field_session,field_photo +347,70,2019-11-14,191,1592244289,208,baby-boy-3.jpg +348,11,2021-09-19,191,1592244289,208,mother-5.jpg +349,7,2019-09-12,191,1592244289,208,mother-2.jpg +350,28,2019-09-21,191,1592244289,208,mother-1.jpg +351,43,2017-01-18,191,1592244289,211,baby-boy-1.jpg +352,17,2021-10-07,191,1592244289,211,mother-6.jpg +353,29,2020-05-07,191,1592244289,210,mother-4.jpg +354,46,2023-01-17,191,1592244289,211,baby-girl-1.jpg +355,44,2022-06-07,191,1592244289,210,baby-girl-1.jpg +356,30,2022-05-07,191,1592244289,210,mother-5.jpg +357,34,2023-01-07,191,1592244289,210,mother-6.jpg +358,31,2022-03-12,191,1592244289,211,mother-2.jpg +359,24,2021-02-21,191,1592244289,210,mother-7.jpg +360,74,2023-12-05,191,1592244289,210,baby-boy-1.jpg +361,10,2019-02-20,191,1592244289,211,mother-3.jpg +362,43,2017-08-11,191,1592244289,211,baby-boy-2.jpg +363,27,2020-03-17,191,1592244289,211,mother-6.jpg +364,80,2022-08-10,191,1592244289,211,mother-4.jpg +365,64,2021-12-08,191,1592244289,210,baby-boy-4.jpg +366,72,2018-02-17,191,1592244289,211,baby-boy-1.jpg \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/pmtct_participant.csv b/server/hedley/modules/custom/hedley_migrate/csv/pmtct_participant.csv index 893e587392..0291e0409b 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/pmtct_participant.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/pmtct_participant.csv @@ -1,44 +1,44 @@ id,field_person,field_adult,field_adult_activities,field_expected,field_clinic,created -315,48,6,mother,2018-09-26|2020-11-26,92,1592244289 -316,49,7,mother,2018-09-30|2020-11-30,92,1592244289 -317,50,8,mother,2018-07-05|2020-09-05,92,1592244289 -318,51,9,mother,2018-08-01|2020-10-01,92,1592244289 -319,52,10,mother,2019-05-11|2020-04-04,93,1592244289 -320,53,11,mother,2019-05-11|2020-11-01,93,1592244289 -321,54,12,mother,2019-05-11|2020-06-05,93,1592244289 -322,55,13,mother,2019-05-11|2020-12-01,93,1592244289 -323,56,14,mother,2019-05-11|2020-05-04,93,1592244289 -324,57,15,mother,2019-05-11|2020-05-08,93,1592244289 -325,58,16,mother,2019-05-11|2020-11-09,93,1592244289 -326,59,17,mother,2019-05-11|2020-08-01,93,1592244289 -327,60,18,mother,2019-05-11|2020-06-06,93,1592244289 -328,61,19,mother,2019-05-11|2020-11-01,93,1592244289 -329,62,20,mother,2019-05-11|2020-09-05,93,1592244289 -330,63,21,mother,2019-05-11|2020-03-01,93,1592244289 -331,64,22,mother,2019-05-11|2020-11-01,93,1592244289 -332,65,23,mother,2019-05-11|2020-04-04,93,1592244289 -333,66,24,mother,2019-05-11|2020-09-01,93,1592244289 -334,67,25,mother,2019-05-11|2020-04-06,93,1592244289 -335,68,26,mother,2019-05-11|2020-11-05,93,1592244289 -336,69,27,mother,2019-05-11|2020-04-07,93,1592244289 -337,70,28,mother,2019-05-11|2020-09-05,93,1592244289 -338,71,29,mother,2019-05-11|2021-02-01,93,1592244289 -339,72,30,mother,2019-05-11|2020-11-08,93,1592244289 -340,73,31,mother,2019-05-11|2020-12-06,93,1592244289 -341,74,32,mother,2019-05-11|2020-03-01,93,1592244289 -342,75,33,mother,2019-05-11|2020-12-01,93,1592244289 -343,76,34,mother,2019-05-11|2020-07-26,93,1592244289 -344,77,35,mother,2019-05-11|2020-05-01,93,1592244289 -345,78,36,mother,2019-05-11|2020-12-14,94,1592244289 -346,79,37,mother,2019-05-11|2020-09-01,94,1592244289 -347,80,38,mother,2019-05-11|2020-12-16,94,1592244289 -348,81,39,mother,2019-05-11|2020-06-30,96,1592244289 -349,82,40,mother,2019-05-11|2020-04-04,96,1592244289 -350,83,41,mother,2019-05-11|2020-03-16,96,1592244289 -351,84,42,mother,2019-05-11|2020-11-30,96,1592244289 -352,85,43,mother,2019-05-11|2020-07-07,96,1592244289 -353,86,44,mother,2019-05-11|2020-11-30,97,1592244289 -354,87,45,mother,2019-05-11|2020-07-06,97,1592244289 -355,88,46,mother,2019-05-11|2020-03-04,97,1592244289 -356,89,47,mother,2019-05-11|2020-10-07,97,1592244289 -357,91,90,caregiver,2018-11-04|1991-08-06,94,1592244289 +387,41,6,mother,2018-09-26|2020-11-26,92,1592244289 +388,42,7,mother,2018-09-30|2020-11-30,92,1592244289 +389,43,8,mother,2018-07-05|2020-09-05,92,1592244289 +390,44,9,mother,2018-08-01|2020-10-01,92,1592244289 +391,45,10,mother,2019-05-11|2020-04-04,93,1592244289 +392,46,11,mother,2019-05-11|2020-11-01,93,1592244289 +393,47,12,mother,2019-05-11|2020-06-05,93,1592244289 +394,48,13,mother,2019-05-11|2020-12-01,93,1592244289 +395,49,14,mother,2019-05-11|2020-05-04,93,1592244289 +396,50,15,mother,2019-05-11|2020-05-08,93,1592244289 +397,51,16,mother,2019-05-11|2020-11-09,93,1592244289 +398,52,17,mother,2019-05-11|2020-08-01,93,1592244289 +399,53,18,mother,2019-05-11|2020-06-06,93,1592244289 +400,54,19,mother,2019-05-11|2020-11-01,93,1592244289 +401,55,20,mother,2019-05-11|2020-09-05,93,1592244289 +402,56,21,mother,2019-05-11|2020-03-01,93,1592244289 +403,57,22,mother,2019-05-11|2020-11-01,93,1592244289 +404,58,23,mother,2019-05-11|2020-04-04,93,1592244289 +405,59,24,mother,2019-05-11|2020-09-01,93,1592244289 +406,60,25,mother,2019-05-11|2020-04-06,93,1592244289 +407,61,26,mother,2019-05-11|2020-11-05,93,1592244289 +408,62,27,mother,2019-05-11|2020-04-07,93,1592244289 +409,63,28,mother,2019-05-11|2020-09-05,93,1592244289 +410,64,29,mother,2019-05-11|2021-02-01,93,1592244289 +411,65,30,mother,2019-05-11|2020-11-08,93,1592244289 +412,66,31,mother,2019-05-11|2020-12-06,93,1592244289 +413,67,32,mother,2019-05-11|2020-03-01,93,1592244289 +414,68,33,mother,2019-05-11|2020-12-01,93,1592244289 +415,69,34,mother,2019-05-11|2020-07-26,93,1592244289 +416,70,35,mother,2019-05-11|2020-05-01,93,1592244289 +417,71,36,mother,2019-05-11|2020-06-30,94,1592244289 +418,72,37,mother,2019-05-11|2020-04-04,94,1592244289 +419,73,38,mother,2019-05-11|2020-03-16,94,1592244289 +420,74,39,mother,2019-05-11|2020-11-30,94,1592244289 +421,75,40,mother,2019-05-11|2020-07-07,94,1592244289 +422,84,76,mother,2019-05-11|2020-12-14,95,1592244289 +423,85,77,mother,2019-05-11|2020-09-01,95,1592244289 +424,86,78,mother,2019-05-11|2020-12-16,95,1592244289 +425,87,79,caregiver,2018-11-04|1991-08-06,95,1592244289 +426,88,80,mother,2019-05-11|2020-11-30,97,1592244289 +427,89,81,mother,2019-05-11|2020-07-06,97,1592244289 +428,90,82,mother,2019-05-11|2020-03-04,97,1592244289 +429,91,83,mother,2019-05-11|2020-10-07,97,1592244289 \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/prenatal_encounter.csv b/server/hedley/modules/custom/hedley_migrate/csv/prenatal_encounter.csv index 93d21e0d93..664190b760 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/prenatal_encounter.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/prenatal_encounter.csv @@ -1,2 +1,2 @@ -id,field_individual_participant,field_scheduled_date -1,1,2019-06-05 +id,field_individual_participant,field_scheduled_date,created +1,1,2019-06-05,1592244289 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/prenatal_family_planning.csv b/server/hedley/modules/custom/hedley_migrate/csv/prenatal_family_planning.csv new file mode 100644 index 0000000000..9f9b539b08 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/prenatal_family_planning.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_family_planning_signs +194,74,2020-06-19,188,1592244289,1,spermicide|cycle-counting|tubal-ligatures diff --git a/server/hedley/modules/custom/hedley_migrate/csv/prenatal_nutrition.csv b/server/hedley/modules/custom/hedley_migrate/csv/prenatal_nutrition.csv new file mode 100644 index 0000000000..6ce3870925 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/prenatal_nutrition.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_height,field_weight,field_muac +194,74,2020-06-19,188,1592244289,1,88.2,14.2,12.7 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/prenatal_photo.csv b/server/hedley/modules/custom/hedley_migrate/csv/prenatal_photo.csv new file mode 100644 index 0000000000..df5d3538e7 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/prenatal_photo.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_photo +194,74,2020-06-19,188,1592244289,1,baby-boy-2.jpg diff --git a/server/hedley/modules/custom/hedley_migrate/csv/relationship.csv b/server/hedley/modules/custom/hedley_migrate/csv/relationship.csv index 4febf78bce..369a0df315 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/relationship.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/relationship.csv @@ -1,43 +1,43 @@ id,field_person,field_related_by,field_related_to,created -96,6,parent,48,1592244289 -97,7,parent,49,1592244289 -98,8,parent,50,1592244289 -99,9,parent,51,1592244289 -100,10,parent,52,1592244289 -101,11,parent,53,1592244289 -102,12,parent,54,1592244289 -103,13,parent,55,1592244289 -104,14,parent,56,1592244289 -105,15,parent,57,1592244289 -106,16,parent,58,1592244289 -107,17,parent,59,1592244289 -108,18,parent,60,1592244289 -109,19,parent,61,1592244289 -110,20,parent,62,1592244289 -111,21,parent,63,1592244289 -112,22,parent,64,1592244289 -113,23,parent,65,1592244289 -114,24,parent,66,1592244289 -115,25,parent,67,1592244289 -116,26,parent,68,1592244289 -117,27,parent,69,1592244289 -118,28,parent,70,1592244289 -119,29,parent,71,1592244289 -120,30,parent,72,1592244289 -121,31,parent,73,1592244289 -122,32,parent,74,1592244289 -123,33,parent,75,1592244289 -124,34,parent,76,1592244289 -125,35,parent,77,1592244289 -126,36,parent,78,1592244289 -127,37,parent,79,1592244289 -128,38,parent,80,1592244289 -129,39,parent,81,1592244289 -130,40,parent,82,1592244289 -131,41,parent,83,1592244289 -132,42,parent,84,1592244289 -133,43,parent,85,1592244289 -134,44,parent,86,1592244289 -135,45,parent,87,1592244289 -136,46,parent,88,1592244289 -137,47,parent,89,1592244289 \ No newline at end of file +98,6,parent,41,1592244289 +99,7,parent,42,1592244289 +100,8,parent,43,1592244289 +101,9,parent,44,1592244289 +102,10,parent,45,1592244289 +103,11,parent,46,1592244289 +104,12,parent,47,1592244289 +105,13,parent,48,1592244289 +106,14,parent,49,1592244289 +107,15,parent,50,1592244289 +108,16,parent,51,1592244289 +109,17,parent,52,1592244289 +110,18,parent,53,1592244289 +111,19,parent,54,1592244289 +112,20,parent,55,1592244289 +113,21,parent,56,1592244289 +114,22,parent,57,1592244289 +115,23,parent,58,1592244289 +116,24,parent,59,1592244289 +117,25,parent,60,1592244289 +118,26,parent,61,1592244289 +119,27,parent,62,1592244289 +120,28,parent,63,1592244289 +121,29,parent,64,1592244289 +122,30,parent,65,1592244289 +123,31,parent,66,1592244289 +124,32,parent,67,1592244289 +125,33,parent,68,1592244289 +126,34,parent,69,1592244289 +127,35,parent,70,1592244289 +128,36,parent,71,1592244289 +129,37,parent,72,1592244289 +130,38,parent,73,1592244289 +131,39,parent,74,1592244289 +132,40,parent,75,1592244289 +133,76,parent,84,1592244289 +134,77,parent,85,1592244289 +135,78,parent,86,1592244289 +136,80,parent,88,1592244289 +137,81,parent,89,1592244289 +138,82,parent,90,1592244289 +139,83,parent,91,1592244289 \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/resource.csv b/server/hedley/modules/custom/hedley_migrate/csv/resource.csv new file mode 100644 index 0000000000..15bb63f115 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/resource.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_resources +194,74,2020-06-19,188,1592244289,1,mosquito-net diff --git a/server/hedley/modules/custom/hedley_migrate/csv/send_to_hc.csv b/server/hedley/modules/custom/hedley_migrate/csv/send_to_hc.csv new file mode 100644 index 0000000000..910c8bc295 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/send_to_hc.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_send_to_hc +194,74,2020-06-19,188,1592244289,1,refer-to-hc +195,35,2017-12-16,188,1592244289,1,refer-to-hc|referral-form +196,81,2020-08-07,188,1592244289,1,none diff --git a/server/hedley/modules/custom/hedley_migrate/csv/session.csv b/server/hedley/modules/custom/hedley_migrate/csv/session.csv index aa8c90295d..27088e4541 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/session.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/session.csv @@ -1,5 +1,5 @@ id,field_clinic,field_scheduled_date,created -190,92,2019-02-04|2019-02-04,1592244289 -191,93,2019-03-20|2019-03-20,1592244289 -192,94,2019-03-17|2019-03-17,1592244289 -193,95,2019-01-05|2019-01-05,1592244289 \ No newline at end of file +208,92,2019-02-04|2019-02-04,1592244289 +209,93,2019-03-20|2019-03-20,1592244289 +210,95,2019-03-17|2019-03-17,1592244289 +211,96,2019-01-05|2019-01-05,1592244289 \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/social_history.csv b/server/hedley/modules/custom/hedley_migrate/csv/social_history.csv new file mode 100644 index 0000000000..2d10771cb7 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/social_history.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_social_history,field_partner_hiv_testing +194,74,2020-06-19,188,1592244289,1,accompanied-by-partner|partner-hiv-counseling,indeterminate diff --git a/server/hedley/modules/custom/hedley_migrate/csv/symptoms_general.csv b/server/hedley/modules/custom/hedley_migrate/csv/symptoms_general.csv new file mode 100644 index 0000000000..01c5862fcc --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/symptoms_general.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_fever_period,field_chills_period,field_night_sweats_period,field_body_aches_period,field_headache_period,field_lethargy_period,field_poor_suck_period,field_unable_to_drink_period,field_unable_to_eat_period,field_increased_thirst_period,field_dry_mouth_period,field_severe_weakness_period,field_yellow_eyes_period,field_coke_colored_urine_period,field_convulsions_period,field_spontaneos_bleeding_period +194,74,2020-06-19,188,1592244289,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 +195,35,2017-12-16,188,1592244289,1,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16 +196,81,2020-08-07,188,1592244289,1,0,2,0,4,0,2,0,4,0,2,0,4,0,1,0,3 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/symptoms_gi.csv b/server/hedley/modules/custom/hedley_migrate/csv/symptoms_gi.csv new file mode 100644 index 0000000000..3d00c1a6be --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/symptoms_gi.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_bloody_diarrhea_period,field_non_bloody_diarrhea_period,field_nausea_period,field_vomiting_period,field_abdominal_pain_period,field_symptoms_gi_derived_signs +194,74,2020-06-19,188,1592244289,1,0,0,1,2,3,none +195,35,2017-12-16,188,1592244289,1,2,0,1,6,0,none +196,81,2020-08-07,188,1592244289,1,4,2,1,0,3,intractable-vomiting|none diff --git a/server/hedley/modules/custom/hedley_migrate/csv/symptoms_respiratory.csv b/server/hedley/modules/custom/hedley_migrate/csv/symptoms_respiratory.csv new file mode 100644 index 0000000000..3de3d6918d --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/symptoms_respiratory.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_cough_period,field_shortness_of_breath_period,field_nasal_congestion_period,field_blood_in_sputum_period,field_sore_throat_period,field_loss_of_smell_period,field_stabbing_chest_pain_period +194,74,2020-06-19,188,1592244289,1,0,0,0,0,0,0,0 +195,35,2017-12-16,188,1592244289,1,1,2,3,4,5,6,7 +196,81,2020-08-07,188,1592244289,1,8,0,4,0,1,0,2 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/travel_history.csv b/server/hedley/modules/custom/hedley_migrate/csv/travel_history.csv new file mode 100644 index 0000000000..cc6cffe3cf --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/travel_history.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_travel_history +194,74,2020-06-19,188,1592244289,1,none +195,35,2017-12-16,188,1592244289,1,covid19-country +196,81,2020-08-07,188,1592244289,1,none|covid19-country diff --git a/server/hedley/modules/custom/hedley_migrate/csv/treatment_history.csv b/server/hedley/modules/custom/hedley_migrate/csv/treatment_history.csv new file mode 100644 index 0000000000..ce3f6cf249 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/treatment_history.csv @@ -0,0 +1,4 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_treatment_history +194,74,2020-06-19,188,1592244289,1,none +195,35,2017-12-16,188,1592244289,1,fever-past-six-hours|malaria-today|malaria-past-month +196,81,2020-08-07,188,1592244289,1,malaria-today|malaria-today-helped diff --git a/server/hedley/modules/custom/hedley_migrate/csv/treatment_ongoing.csv b/server/hedley/modules/custom/hedley_migrate/csv/treatment_ongoing.csv new file mode 100644 index 0000000000..b361c35a24 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/treatment_ongoing.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_acute_illness_encounter,field_treatment_ongoing,field_reason_for_not_taking,field_missed_doses,field_adverse_events +194,74,2020-06-19,188,1592244289,1,taken-as-prescribed|feel-better,none,0,diarrhea|fatigue diff --git a/server/hedley/modules/custom/hedley_migrate/csv/village.csv b/server/hedley/modules/custom/hedley_migrate/csv/village.csv index 65b96632d7..39f7ec9f62 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/village.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/village.csv @@ -1,5 +1,5 @@ id,field_province,field_district,field_sector,field_cell,field_village,field_health_center,created -138,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,4,1592244289 -161,Amajyaruguru,Gakenke,Coko,Nyange,Buhara,4,1592244289 -163,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,5,1592244289 -186,Amajyaruguru,Gakenke,Muhondo,Bwenda,Gahama,5,1592244289 \ No newline at end of file +140,Amajyaruguru,Gakenke,Coko,Mbirima,Akanduga,4,1592244289 +163,Amajyaruguru,Gakenke,Coko,Nyange,Buhara,4,1592244289 +165,Amajyaruguru,Gakenke,Muhondo,Busake,Busake,5,1592244289 +188,Amajyaruguru,Gakenke,Muhondo,Bwenda,Gahama,5,1592244289 \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/csv/vitals.csv b/server/hedley/modules/custom/hedley_migrate/csv/vitals.csv new file mode 100644 index 0000000000..9d73748d0e --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/csv/vitals.csv @@ -0,0 +1,2 @@ +id,field_person,field_date_measured,field_nurse,created,field_prenatal_encounter,field_sys,field_dia,field_heart_rate,field_respiratory_rate,field_body_temperature +194,74,2020-06-19,188,1592244289,1,1.5,2.5,88,22,37.2 diff --git a/server/hedley/modules/custom/hedley_migrate/csv/weight.csv b/server/hedley/modules/custom/hedley_migrate/csv/weight.csv index 53a2708659..2812f2c9a2 100644 --- a/server/hedley/modules/custom/hedley_migrate/csv/weight.csv +++ b/server/hedley/modules/custom/hedley_migrate/csv/weight.csv @@ -1,21 +1,21 @@ -id,field_person,field_date_measured,field_nurse,field_session,created,field_weight,field_bmi,field_zscore_age,field_zscore_length,field_zscore_bmi -295,86,2022-04-15,,191,1592244289,21,,2.43748,, -296,48,2019-07-04,,191,1592244289,58,,39.5565,, -297,76,2018-04-09,,191,1592244289,25,,,, -298,23,2018-10-16,,190,1592244289,44,,,, -299,47,2018-12-16,,190,1592244289,41,,,, -300,9,2017-01-31,,190,1592244289,25,,,, -301,23,2021-05-15,,190,1592244289,24,,,, -302,69,2019-12-11,,190,1592244289,14,,1.53024,, -303,77,2023-08-23,,193,1592244289,37,,4.94997,, -304,59,2018-11-01,,192,1592244289,20,,11.4886,, -305,76,2019-04-29,,193,1592244289,48,,29.3895,, -306,60,2019-11-28,,192,1592244289,11,,0.29873,, -307,38,2018-08-05,,192,1592244289,47,,,, -308,17,2023-04-04,,192,1592244289,41,,,, -309,39,2021-10-12,,193,1592244289,21,,,, -310,35,2020-01-15,,193,1592244289,47,,,, -311,79,2023-09-15,,193,1592244289,41,,6.43781,, -312,71,2020-06-26,,192,1592244289,10,,-0.945971,, -313,86,2022-04-11,,192,1592244289,23,,3.17047,, -314,41,2017-09-22,,193,1592244289,35,,,, \ No newline at end of file +id,field_person,field_date_measured,field_nurse,created,field_session,field_weight,field_bmi,field_zscore_age,field_zscore_length,field_zscore_bmi +367,88,2022-04-15,191,1592244289,209,21,,2.44069,, +368,41,2019-07-04,191,1592244289,209,58,,39.6101,, +369,69,2018-04-09,191,1592244289,209,25,,,, +370,23,2018-10-16,191,1592244289,208,44,,,, +371,83,2018-12-16,191,1592244289,208,41,,,, +372,9,2017-01-31,191,1592244289,208,25,,,, +373,23,2021-05-15,191,1592244289,208,24,,,, +374,62,2019-12-11,191,1592244289,208,14,,1.53549,, +375,70,2023-08-23,191,1592244289,211,37,,4.95393,, +376,52,2018-11-01,191,1592244289,210,20,,11.5239,, +377,69,2019-04-29,191,1592244289,211,48,,29.4216,, +378,53,2019-11-28,191,1592244289,210,11,,0.303886,, +379,78,2018-08-05,191,1592244289,210,47,,,, +380,17,2023-04-04,191,1592244289,210,41,,,, +381,36,2021-10-12,191,1592244289,211,21,,,, +382,35,2020-01-15,191,1592244289,211,47,,,, +383,85,2023-09-15,191,1592244289,211,41,,6.44274,, +384,64,2020-06-26,191,1592244289,210,10,,-0.940649,, +385,88,2022-04-11,191,1592244289,210,23,,3.17412,, +386,38,2017-09-22,191,1592244289,211,35,,,, \ No newline at end of file diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateBase.php b/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateBase.php index 0bb14d2d26..61b1e790ca 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateBase.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateBase.php @@ -24,13 +24,6 @@ abstract class HedleyMigrateBase extends Migration { */ protected $bundle = NULL; - /** - * The CSV columns. - * - * @var array - */ - protected $csvColumns = []; - /** * Additional columns not in the CSV. * @@ -46,32 +39,48 @@ abstract class HedleyMigrateBase extends Migration { protected $fields = []; /** - * Fields which we can map in a standard way. + * A sub-directory where we can find the CSV for this migration. * - * @var array + * @var string */ - protected $simpleMappings = []; + protected $csvPrefix = ''; /** - * Fields with multi-values that we can map in a standard way. + * The name of our key field. * - * @var array + * @var string */ - protected $simpleMultipleMappings = []; + protected $keyName = 'id'; /** - * A sub-directory where we can find the CSV for this migration. + * Returns list of columns in CSV file. * - * @var string + * @return array + * List of columns in CSV file. */ - protected $csvPrefix = ''; + protected function csvColumns() { + return []; + } /** - * The name of our key field. + * Returns list of fields that we can map in a standard way. * - * @var string + * @return array + * List of fields that we can map in a standard way. */ - protected $keyName = 'id'; + protected function simpleMappings() { + return []; + } + + /** + * Returns list of fields with multi-values that we can map in a standard way. + * + * @return array + * List of fields with multi-values that we can map in a standard way. + */ + protected function simpleMultipleMappings() { + return []; + } /** * HedleyMigrateBase constructor. @@ -92,7 +101,8 @@ public function __construct($arguments) { $source_file = $this->getMigrateDirectory() . '/csv/' . $this->csvPrefix . $this->bundle . '.csv'; - foreach ($this->csvColumns as $column_name) { + $columnsCsv = $this->csvColumns(); + foreach ($columnsCsv as $column_name) { $this->columns[] = [$column_name, $column_name]; } $this->source = new MigrateSourceCSV($source_file, $this->columns, ['header_rows' => 1], $this->fields); @@ -111,10 +121,11 @@ public function __construct($arguments) { $this->map = new MigrateSQLMap($this->machineName, $key, $this->destination->getKeySchema($this->entityType)); // Add simple mappings. - if ($this->simpleMappings) { - $this->addSimpleMappings(drupal_map_assoc($this->simpleMappings)); + $mappingsSimple = $this->simpleMappings(); + if (!empty($mappingsSimple)) { + $this->addSimpleMappings(drupal_map_assoc($mappingsSimple)); } - foreach ($this->simpleMultipleMappings as $field) { + foreach ($this->simpleMultipleMappings() as $field) { $this ->addFieldMapping($field, $field) ->separator('|'); @@ -126,24 +137,23 @@ public function __construct($arguments) { ->addFieldMapping('uid', 'author') ->defaultValue(1); // Map the title field to the default title. - if (in_array('title', $this->csvColumns)) { + if (in_array('title', $columnsCsv)) { $this->addFieldMapping('title', 'title'); } - elseif (in_array('title_field', $this->csvColumns)) { + elseif (in_array('title_field', $columnsCsv)) { $this->addFieldMapping('title', 'title_field'); } - if (in_array('created', $this->csvColumns)) { + if (in_array('created', $columnsCsv)) { $this->addFieldMapping('created', 'created'); } } elseif ($this->entityType == 'taxonomy_term') { // Map the translated name field to the default term name. - if (in_array('name', $this->csvColumns)) { + if (in_array('name', $columnsCsv)) { $this->addFieldMapping('name', 'name'); } } - } /** @@ -177,9 +187,22 @@ public function avatarProcess($name) { * * @return int * A timestamp. + * + * @throws \Exception */ public function dateProcess($date) { - return strtotime($date); + // The source material uses several date formats. + $trimmed = trim($date); + + if (empty($trimmed)) { + return $trimmed; + } + + if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { + return DateTime::createFromFormat('!Y-m-d', $trimmed, new DateTimeZone("UTC"))->getTimestamp(); + } + + throw new Exception("$date was not a recognized date format."); } /** @@ -234,17 +257,4 @@ public function date2Process($date) { ]; } - /** - * Add date fields. - * - * @param array $field_names - * The date related field names. - */ - public function addDateFields(array $field_names) { - foreach ($field_names as $field_name) { - $this->addFieldMapping($field_name, $field_name) - ->callbacks([$this, 'dateProcess']); - } - } - } diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateMissing.php b/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateMissing.php deleted file mode 100644 index 44ef7d3924..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateMissing.php +++ /dev/null @@ -1,174 +0,0 @@ - 'MigrateDestinationNode', - 'taxonomy_term' => 'MigrateDestinationTerm', - ]; - - // Add default settings, only for nodes, terms and multifields. - if (empty($destination_classes[$this->entityType])) { - return; - } - - $this->description = "Import Missing {$this->bundle}"; - - $source_file = $this->getMigrateDirectory() . '/csv/missing.csv'; - - $columns = []; - foreach ($this->csvColumns as $column_name) { - $columns[] = [$column_name, $column_name]; - } - $this->source = new MigrateSourceCSV($source_file, $columns, ['header_rows' => 1]); - - $destination_class = $destination_classes[$this->entityType]; - $this->destination = new $destination_class($this->bundle); - - $key = [ - 'id' => [ - 'type' => 'varchar', - 'length' => 255, - 'not null' => TRUE, - ], - ]; - - $this->map = new MigrateSQLMap($this->machineName, $key, $this->destination->getKeySchema($this->entityType)); - - // These are common to all. - $this->addSimpleMappings([ - 'field_session', - 'field_child', - ]); - - // Common to all, and requires some processing. - $this->addDateFields(['field_date_measured']); - - // Add specific mappings. - if ($this->simpleMappings) { - $this->addSimpleMappings($this->simpleMappings); - } - - foreach ($this->simpleMultipleMappings as $field) { - $this - ->addFieldMapping($field, $field) - ->separator('|'); - } - - if ($this->entityType == 'node') { - // Set the first user as the author. - $this - ->addFieldMapping('uid', 'author') - ->defaultValue(1); - // Map the title field to the default title. - if (in_array('title', $this->csvColumns)) { - $this->addFieldMapping('title', 'title'); - } - elseif (in_array('title_field', $this->csvColumns)) { - $this->addFieldMapping('title', 'title_field'); - } - } - elseif ($this->entityType == 'taxonomy_term') { - // Map the translated name field to the default term name. - if (in_array('name', $this->csvColumns)) { - $this->addFieldMapping('name', 'name'); - } - } - - } - - /** - * Returns the migrate directory. - * - * @return string - * The migrate directory. - */ - protected function getMigrateDirectory() { - return variable_get('hedley_migrate_directory', FALSE) ? variable_get('hedley_migrate_directory') : drupal_get_path('module', 'hedley_migrate'); - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - return strtotime($date); - } - - /** - * Add date fields. - * - * @param array $field_names - * The date related field names. - */ - public function addDateFields(array $field_names) { - foreach ($field_names as $field_name) { - $this->addFieldMapping($field_name, $field_name) - ->callbacks([$this, 'dateProcess']); - } - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateChildren201902.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateChildren201902.php deleted file mode 100644 index 8aec8bc119..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateChildren201902.php +++ /dev/null @@ -1,155 +0,0 @@ - ['id', 'id'], - 1 => ['mother', 'mother'], - 2 => ['first_name', 'first_name'], - 3 => ['middle_name', 'middle_name'], - 4 => ['second_name', 'second_name'], - 5 => ['birth_date', 'birth_date'], - 8 => ['gender', 'gender'], - 20 => ['cell', 'cell'], - 22 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - ]; - - /** - * HedleyMigrateChildren201902 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateMothers_2019_02', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_gender', 'gender'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_mother', 'mother') - ->sourceMigration('HedleyMigrateMothers_2019_02'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // We only want to import the children of mothers we have imported. - // (We are selecting mothers based on their health center). - $migratedMother = db_select('migrate_map_hedleymigratemothers_2019_02', 'm') - ->condition('sourceid1', $row->mother) - ->isNotNull('destid1') - ->countQuery() - ->execute() - ->fetchField(); - - if ($migratedMother == 0) { - // We didn't migrate the mother. - return FALSE; - } - - // Calculate the child's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Normalize Gender. - if ($row->gender) { - $row->gender = trim(strtolower($row->gender)); - - if ($row->gender == 'm') { - $row->gender = 'male'; - } - - if ($row->gender == 'f') { - $row->gender = 'female'; - } - - if ($row->gender != 'female' && $row->gender != 'male') { - throw new Exception("{$row->gender} is not a recognized gender"); - } - } - - return TRUE; - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateClinics201902.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateClinics201902.php deleted file mode 100644 index 15dc3f5a86..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateClinics201902.php +++ /dev/null @@ -1,54 +0,0 @@ -dependencies = [ - 'HedleyMigrateHealthCenters', - ]; - - $this - ->addFieldMapping('field_health_center', 'field_health_center') - ->sourceMigration('HedleyMigrateHealthCenters'); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateMothers201902.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateMothers201902.php deleted file mode 100644 index 43f2bd533d..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-02/HedleyMigrateMothers201902.php +++ /dev/null @@ -1,165 +0,0 @@ - ['id', 'id'], - 1 => ['first_name', 'first_name'], - 2 => ['middle_name', 'middle_name'], - 3 => ['second_name', 'second_name'], - 4 => ['birth_date', 'birth_date'], - 8 => ['ubudehe', 'ubudehe'], - 9 => ['education', 'education'], - 19 => ['cell', 'cell'], - 21 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - 'clinic' => 'clinic', - ]; - - /** - * HedleyMigrateClinics constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateClinics_2019_02', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_education_level', 'education'); - $this->addFieldMapping('field_ubudehe', 'ubudehe'); - - $this - ->addFieldMapping('field_relationship', 'relationship') - ->defaultValue('mother'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_clinic', 'clinic') - ->sourceMigration('HedleyMigrateClinics_2019_02'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - $health_center = strtoupper($row->health_center); - - // Calculate which clinic to put the mother into. - if ($health_center === 'COKO') { - // The COKO mothers are all in one clinic. - $row->clinic = 'COKO'; - } - elseif ($health_center === 'RWANKUBA') { - // For the RWANKUBA mothers, we're dividing into clinics according to - // cell. - $row->clinic = $row->cell; - } - else { - // For now, we're only importing for some health centers. - return FALSE; - } - - // Calculate the mother's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Education. - if ($row->education) { - if ($row->education === 'Primary') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($row->education === 'NTABWOYIZE') { - // Means "no education". - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif (preg_match('/^P[1-8]$/', $row->education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif (preg_match('/^S[1-6]$/', $row->education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - else { - throw new Exception("{$row->education} is not a recognized education level."); - } - } - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-03/HedleyMigrateChildren201903.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-03/HedleyMigrateChildren201903.php deleted file mode 100644 index c65b5976fe..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-03/HedleyMigrateChildren201903.php +++ /dev/null @@ -1,143 +0,0 @@ - ['id', 'id'], - 2 => ['first_name', 'first_name'], - 3 => ['middle_name', 'middle_name'], - 4 => ['second_name', 'second_name'], - 5 => ['birth_date', 'birth_date'], - 8 => ['gender', 'gender'], - 12 => ['mother_national_id', 'mother_national_id'], - 20 => ['cell', 'cell'], - 22 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - ]; - - /** - * HedleyMigrateChildren201903 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateMothers_2019_03', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_gender', 'gender'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - // In this batch, our unique ID for the mother in the source data is the - // national ID. - $this - ->addFieldMapping('field_mother', 'mother_national_id') - ->sourceMigration('HedleyMigrateMothers_2019_03'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the child's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Normalize Gender. - if ($row->gender) { - $row->gender = trim(strtolower($row->gender)); - - if ($row->gender == 'm') { - $row->gender = 'male'; - } - - if ($row->gender == 'f') { - $row->gender = 'female'; - } - - if ($row->gender != 'female' && $row->gender != 'male') { - throw new Exception("{$row->gender} is not a recognized gender"); - } - } - - return TRUE; - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-03/HedleyMigrateMothers201903.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-03/HedleyMigrateMothers201903.php deleted file mode 100644 index 117c23d1cb..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-03/HedleyMigrateMothers201903.php +++ /dev/null @@ -1,177 +0,0 @@ - ['first_name', 'first_name'], - 2 => ['second_name', 'second_name'], - 3 => ['birth_date', 'birth_date'], - 5 => ['national_id', 'national_id'], - 7 => ['ubudehe', 'ubudehe'], - 8 => ['education', 'education'], - 18 => ['cell', 'cell'], - 20 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - 'clinic' => 'clinic', - ]; - - /** - * The name of the key. - * - * @var string - */ - public $keyName = 'national_id'; - - /** - * HedleyMigrateClinics constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - // We need the clinics from the previous migration. - $this->dependencies = [ - 'HedleyMigrateClinics_2019_02', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_education_level', 'education'); - $this->addFieldMapping('field_ubudehe', 'ubudehe'); - - $this - ->addFieldMapping('field_relationship', 'relationship') - ->defaultValue('mother'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_clinic', 'clinic') - ->sourceMigration('HedleyMigrateClinics_2019_02'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - $health_center = strtoupper($row->health_center); - - // Calculate which clinic to put the mother into. - if ($health_center === 'COKO') { - // The COKO mothers are all in one clinic. - $row->clinic = 'COKO'; - } - elseif ($health_center === 'RWANKUBA') { - // For the RWANKUBA mothers, we're dividing into clinics according to - // cell. - $row->clinic = $row->cell; - } - else { - // For now, we're only importing for some health centers. - return FALSE; - } - - // Calculate the mother's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Education. - if ($row->education) { - if ($row->education === 'Primary') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($row->education === 'NTABWOYIZE') { - // Means "no education". - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif (preg_match('/^P[1-8]$/', $row->education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif (preg_match('/^S[1-6]$/', $row->education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - else { - throw new Exception("{$row->education} is not a recognized education level."); - } - } - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - // Some dates are year-only ... we'll make those Jan. 1. - if (preg_match('/^\\d\\d\\d\\d$/', $trimmed)) { - $trimmed = "$trimmed-01-01"; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04-2/HedleyMigrateChildren2019042.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04-2/HedleyMigrateChildren2019042.php deleted file mode 100644 index db69988ccc..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04-2/HedleyMigrateChildren2019042.php +++ /dev/null @@ -1,155 +0,0 @@ - ['id', 'id'], - 1 => ['mother_id', 'mother_id'], - 2 => ['first_name', 'first_name'], - 3 => ['middle_name', 'middle_name'], - 4 => ['second_name', 'second_name'], - 5 => ['birth_date', 'birth_date'], - 8 => ['gender', 'gender'], - 22 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - ]; - - /** - * HedleyMigrateChildren201904 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateMothers_2019_04_2', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_gender', 'gender'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_mother', 'mother_id') - ->sourceMigration('HedleyMigrateMothers_2019_04_2'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the child's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Normalize Gender. - if ($row->gender) { - $row->gender = trim(strtolower($row->gender)); - - if ($row->gender == 'm') { - $row->gender = 'male'; - } - - if ($row->gender == 'f') { - $row->gender = 'female'; - } - - if ($row->gender != 'female' && $row->gender != 'male') { - throw new Exception("{$row->gender} is not a recognized gender for {$row->id}"); - } - } - - return TRUE; - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - $matches = []; - - if (preg_match('/^(\\d\\d?)-(\\d\\d?)-(\\d\\d?)$/', $trimmed, $matches)) { - // This is sometimes y-m-d and sometimes m-d-y, so we need to figure - // that out. - if (intval($matches[2]) > 12) { - return DateTime::createFromFormat('!m-d-y', $trimmed)->getTimestamp(); - } - - if (intval($matches[1]) > 12) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - // The first part is 12 or less, so if the last part is 17 or 18 then - // we're probably m-d-y. - if (($matches[3] === '17') || ($matches[3] === '18')) { - return DateTime::createFromFormat('!m-d-y', $trimmed)->getTimestamp(); - } - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04-2/HedleyMigrateMothers2019042.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04-2/HedleyMigrateMothers2019042.php deleted file mode 100644 index 5fd37ea512..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04-2/HedleyMigrateMothers2019042.php +++ /dev/null @@ -1,192 +0,0 @@ - ['id', 'id'], - 1 => ['first_name', 'first_name'], - 2 => ['middle_name', 'middle_name'], - 3 => ['second_name', 'second_name'], - 4 => ['birth_date', 'birth_date'], - 8 => ['ubudehe', 'ubudehe'], - 9 => ['education', 'education'], - 19 => ['cell', 'cell'], - 21 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - 'clinic' => 'clinic', - ]; - - /** - * HedleyMigrateMothers201904 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateClinics_2019_02', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_education_level', 'education'); - $this->addFieldMapping('field_ubudehe', 'ubudehe'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_clinic', 'clinic') - ->sourceMigration('HedleyMigrateClinics_2019_02'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - $health_center = strtoupper($row->health_center); - $cell = strtoupper($row->cell); - - // Calculate the mother's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Calculate which clinic to put the mother into. - if ($health_center === 'COKO') { - $row->clinic = 'COKO'; - } - elseif ($health_center === 'RWANKUBA') { - $row->clinic = $cell; - } - elseif ($health_center === 'MUHONDO') { - $row->clinic = 'MUHONDO'; - } - elseif ($health_center === 'NYANGE') { - $row->clinic = 'NYANGE'; - } - else { - throw new Exception("{$row->health_center}, {$row->cell} is not a recognized health center/cell for {$row->id}"); - } - - $education = strtolower(trim($row->education)); - - // Education. - if ($education) { - if ($education === 'primary') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'primary school') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'primary schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'secondary') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'secondary school') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'secondary schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'advanced diploma') { - $row->education = HEDLEY_PATIENT_EDUCATION_ADVANCED; - } - elseif ($education === 'no schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif ($education === 'ntabwoyize') { - // Means "no education". - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif (preg_match('/^p[1-8]$/', $education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif (preg_match('/^s[1-6]$/', $education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - else { - throw new Exception("{$row->education} is not a recognized education level for {$row->id}."); - } - } - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - // Some dates are year-only ... we'll make those Jan. 1. - if (preg_match('/^\\d\\d\\d\\d$/', $trimmed)) { - $trimmed = "$trimmed-01-01"; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateChildren201904.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateChildren201904.php deleted file mode 100644 index fd1853f0fb..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateChildren201904.php +++ /dev/null @@ -1,140 +0,0 @@ - ['id', 'id'], - 1 => ['mother_id', 'mother_id'], - 2 => ['first_name', 'first_name'], - 3 => ['middle_name', 'middle_name'], - 4 => ['second_name', 'second_name'], - 5 => ['birth_date', 'birth_date'], - 8 => ['gender', 'gender'], - 22 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - ]; - - /** - * HedleyMigrateChildren201904 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateMothers_2019_04', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_gender', 'gender'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_mother', 'mother_id') - ->sourceMigration('HedleyMigrateMothers_2019_04'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the child's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Normalize Gender. - if ($row->gender) { - $row->gender = trim(strtolower($row->gender)); - - if ($row->gender == 'm') { - $row->gender = 'male'; - } - - if ($row->gender == 'f') { - $row->gender = 'female'; - } - - if ($row->gender != 'female' && $row->gender != 'male') { - throw new Exception("{$row->gender} is not a recognized gender"); - } - } - - return TRUE; - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateClinics201904.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateClinics201904.php deleted file mode 100644 index d5a17a8db5..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateClinics201904.php +++ /dev/null @@ -1,54 +0,0 @@ -dependencies = [ - 'HedleyMigrateHealthCenters', - ]; - - $this - ->addFieldMapping('field_health_center', 'field_health_center') - ->sourceMigration('HedleyMigrateHealthCenters'); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateMothers201904.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateMothers201904.php deleted file mode 100644 index 31a471c1d2..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-04/HedleyMigrateMothers201904.php +++ /dev/null @@ -1,183 +0,0 @@ - ['id', 'id'], - 1 => ['first_name', 'first_name'], - 2 => ['middle_name', 'middle_name'], - 3 => ['second_name', 'second_name'], - 4 => ['birth_date', 'birth_date'], - 8 => ['ubudehe', 'ubudehe'], - 9 => ['education', 'education'], - 19 => ['cell', 'cell'], - 21 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - 'clinic' => 'clinic', - ]; - - /** - * HedleyMigrateMothers201904 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateClinics_2019_04', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_education_level', 'education'); - $this->addFieldMapping('field_ubudehe', 'ubudehe'); - - $this - ->addFieldMapping('field_relationship', 'relationship') - ->defaultValue('mother'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_clinic', 'clinic') - ->sourceMigration('HedleyMigrateClinics_2019_04'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - $health_center = strtoupper($row->health_center); - $cell = strtoupper($row->cell); - - // Calculate the mother's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Calculate which clinic to put the mother into. - if ($health_center === 'RULI') { - $row->clinic = 'ruli'; - } - elseif ($cell === 'RUKURA') { - $row->clinic = 'rukura'; - } - elseif ($cell === 'SHYOMBWE') { - $row->clinic = 'shyombwe'; - } - elseif ($cell === 'MBOGO') { - $row->clinic = 'mbogo'; - } - else { - throw new Exception("{$row->health_center}, {$row->cell} is not a recognized health center/cell for {$row->id}"); - } - - // Education. - if ($row->education) { - if ($row->education === 'Primary') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($row->education === 'Primary School') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($row->education === 'Secondary') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($row->education === 'No Schooling') { - // Means "no education". - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif ($row->education === 'NTABWOYIZE') { - // Means "no education". - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif (preg_match('/^P[1-8]$/', $row->education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif (preg_match('/^S[1-6]$/', $row->education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - else { - throw new Exception("{$row->education} is not a recognized education level for {$row->id}."); - } - } - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - // Some dates are year-only ... we'll make those Jan. 1. - if (preg_match('/^\\d\\d\\d\\d$/', $trimmed)) { - $trimmed = "$trimmed-01-01"; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-2/HedleyMigrateChildren2019052.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-2/HedleyMigrateChildren2019052.php deleted file mode 100644 index 401e439269..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-2/HedleyMigrateChildren2019052.php +++ /dev/null @@ -1,156 +0,0 @@ - ['id', 'id'], - 1 => ['mother_id', 'mother_id'], - 2 => ['first_name', 'first_name'], - 3 => ['middle_name', 'middle_name'], - 4 => ['second_name', 'second_name'], - 5 => ['birth_date', 'birth_date'], - 8 => ['gender', 'gender'], - 22 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - ]; - - /** - * HedleyMigrateChildren2019052 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateMothers_2019_05_2', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_gender', 'gender'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_mother', 'mother_id') - ->sourceMigration('HedleyMigrateMothers_2019_05_2'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the child's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Normalize Gender. - if ($row->gender) { - $row->gender = trim(strtolower($row->gender)); - - if ($row->gender == 'm') { - $row->gender = 'male'; - } - - if ($row->gender == 'f') { - $row->gender = 'female'; - } - - if ($row->gender != 'female' && $row->gender != 'male') { - throw new Exception("{$row->gender} is not a recognized gender for {$row->id}"); - } - } - - return TRUE; - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - $matches = []; - - if (preg_match('/^(\\d\\d?)-(\\d\\d?)-(\\d\\d?)$/', $trimmed, $matches)) { - // This is sometimes y-m-d and sometimes m-d-y, so we need to figure - // that out. - if (intval($matches[2]) > 12) { - return DateTime::createFromFormat('!m-d-y', $trimmed)->getTimestamp(); - } - - if (intval($matches[1]) > 12) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - // The first part is 12 or less, so if the last part is 17 or 18 then - // we're probably m-d-y. - if (($matches[3] === '17') || ($matches[3] === '18')) { - return DateTime::createFromFormat('!m-d-y', $trimmed)->getTimestamp(); - } - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-2/HedleyMigrateMothers2019052.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-2/HedleyMigrateMothers2019052.php deleted file mode 100644 index 8f5a43b155..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-2/HedleyMigrateMothers2019052.php +++ /dev/null @@ -1,174 +0,0 @@ - ['id', 'id'], - 1 => ['first_name', 'first_name'], - 2 => ['middle_name', 'middle_name'], - 3 => ['second_name', 'second_name'], - 4 => ['birth_date', 'birth_date'], - 8 => ['ubudehe', 'ubudehe'], - 9 => ['education', 'education'], - 19 => ['cell', 'cell'], - 21 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - 'clinic' => 'clinic', - ]; - - /** - * HedleyMigrateMothers2019052 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateClinics_2019_02', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_education_level', 'education'); - $this->addFieldMapping('field_ubudehe', 'ubudehe'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_clinic', 'clinic') - ->sourceMigration('HedleyMigrateClinics_2019_02'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the mother's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - $row->clinic = 'MUYONGWE'; - - $education = strtolower(trim($row->education)); - - // Education. - if ($education) { - if ($education === 'primary') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'primary school') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'primary schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'secondary') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'secondary school') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'secondary schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'advanced diploma') { - $row->education = HEDLEY_PATIENT_EDUCATION_ADVANCED; - } - elseif ($education === 'no schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif ($education === 'ntabwoyize') { - // Means "no education". - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif (preg_match('/^p[1-8]$/', $education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif (preg_match('/^s[1-6]$/', $education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - else { - throw new Exception("{$row->education} is not a recognized education level for {$row->id}."); - } - } - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - // Some dates are year-only ... we'll make those Jan. 1. - if (preg_match('/^\\d\\d\\d\\d$/', $trimmed)) { - $trimmed = "$trimmed-01-01"; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-3/HedleyMigrateChildren2019053.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-3/HedleyMigrateChildren2019053.php deleted file mode 100644 index bdf56a5118..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-3/HedleyMigrateChildren2019053.php +++ /dev/null @@ -1,160 +0,0 @@ - ['id', 'id'], - 1 => ['mother_id', 'mother_id'], - 2 => ['first_name', 'first_name'], - 3 => ['middle_name', 'middle_name'], - 4 => ['second_name', 'second_name'], - 5 => ['birth_date', 'birth_date'], - 8 => ['gender', 'gender'], - 22 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - ]; - - /** - * HedleyMigrateChildren2019053 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateMothers_2019_05_3', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_gender', 'gender'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_mother', 'mother_id') - ->sourceMigration('HedleyMigrateMothers_2019_05_3'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the child's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Normalize Gender. - if ($row->gender) { - $row->gender = trim(strtolower($row->gender)); - - if ($row->gender == 'm') { - $row->gender = 'male'; - } - - if ($row->gender == 'f') { - $row->gender = 'female'; - } - - if ($row->gender != 'female' && $row->gender != 'male') { - throw new Exception("{$row->gender} is not a recognized gender for {$row->id}"); - } - } - - return TRUE; - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - $matches = []; - - if (preg_match('/^(\\d\\d?)-(\\d\\d?)-(\\d\\d?)$/', $trimmed, $matches)) { - // This is sometimes y-m-d and sometimes m-d-y, so we need to figure - // that out. - if (intval($matches[2]) > 12) { - return DateTime::createFromFormat('!m-d-y', $trimmed)->getTimestamp(); - } - - if (intval($matches[1]) > 12) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - // The first part is 12 or less, so if the last part is 17 or 18 then - // we're probably m-d-y. - if (($matches[3] === '17') || ($matches[3] === '18')) { - return DateTime::createFromFormat('!m-d-y', $trimmed)->getTimestamp(); - } - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!d-m-Y', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-3/HedleyMigrateMothers2019053.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-3/HedleyMigrateMothers2019053.php deleted file mode 100644 index b9eaac49ef..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05-3/HedleyMigrateMothers2019053.php +++ /dev/null @@ -1,174 +0,0 @@ - ['id', 'id'], - 1 => ['first_name', 'first_name'], - 2 => ['middle_name', 'middle_name'], - 3 => ['second_name', 'second_name'], - 4 => ['birth_date', 'birth_date'], - 8 => ['ubudehe', 'ubudehe'], - 9 => ['education', 'education'], - 19 => ['cell', 'cell'], - 21 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - 'clinic' => 'clinic', - ]; - - /** - * HedleyMigrateMothers2019053 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateClinics_2019_02', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_education_level', 'education'); - $this->addFieldMapping('field_ubudehe', 'ubudehe'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_clinic', 'clinic') - ->sourceMigration('HedleyMigrateClinics_2019_02'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the mother's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - $row->clinic = 'MINAZI'; - - $education = strtolower(trim($row->education)); - - // Education. - if ($education) { - if ($education === 'primary') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'primary school') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'primary schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'secondary') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'secondary school') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'secondary schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'advanced diploma') { - $row->education = HEDLEY_PATIENT_EDUCATION_ADVANCED; - } - elseif ($education === 'no schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif ($education === 'ntabwoyize') { - // Means "no education". - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif (preg_match('/^p[1-8]$/', $education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif (preg_match('/^s[1-6]$/', $education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - else { - throw new Exception("{$row->education} is not a recognized education level for {$row->id}."); - } - } - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - // Some dates are year-only ... we'll make those Jan. 1. - if (preg_match('/^\\d\\d\\d\\d$/', $trimmed)) { - $trimmed = "$trimmed-01-01"; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05/HedleyMigrateChildren201905.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05/HedleyMigrateChildren201905.php deleted file mode 100644 index a8ecb49ffd..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05/HedleyMigrateChildren201905.php +++ /dev/null @@ -1,156 +0,0 @@ - ['id', 'id'], - 1 => ['mother_id', 'mother_id'], - 2 => ['first_name', 'first_name'], - 3 => ['middle_name', 'middle_name'], - 4 => ['second_name', 'second_name'], - 5 => ['birth_date', 'birth_date'], - 8 => ['gender', 'gender'], - 22 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - ]; - - /** - * HedleyMigrateChildren201905 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateMothers_2019_05', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_gender', 'gender'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_mother', 'mother_id') - ->sourceMigration('HedleyMigrateMothers_2019_05'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the child's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - // Normalize Gender. - if ($row->gender) { - $row->gender = trim(strtolower($row->gender)); - - if ($row->gender == 'm') { - $row->gender = 'male'; - } - - if ($row->gender == 'f') { - $row->gender = 'female'; - } - - if ($row->gender != 'female' && $row->gender != 'male') { - throw new Exception("{$row->gender} is not a recognized gender for {$row->id}"); - } - } - - return TRUE; - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - $matches = []; - - if (preg_match('/^(\\d\\d?)-(\\d\\d?)-(\\d\\d?)$/', $trimmed, $matches)) { - // This is sometimes y-m-d and sometimes m-d-y, so we need to figure - // that out. - if (intval($matches[2]) > 12) { - return DateTime::createFromFormat('!m-d-y', $trimmed)->getTimestamp(); - } - - if (intval($matches[1]) > 12) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - // The first part is 12 or less, so if the last part is 17 or 18 then - // we're probably m-d-y. - if (($matches[3] === '17') || ($matches[3] === '18')) { - return DateTime::createFromFormat('!m-d-y', $trimmed)->getTimestamp(); - } - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05/HedleyMigrateMothers201905.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05/HedleyMigrateMothers201905.php deleted file mode 100644 index 0b15e02e2a..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/2019-05/HedleyMigrateMothers201905.php +++ /dev/null @@ -1,174 +0,0 @@ - ['id', 'id'], - 1 => ['first_name', 'first_name'], - 2 => ['middle_name', 'middle_name'], - 3 => ['second_name', 'second_name'], - 4 => ['birth_date', 'birth_date'], - 8 => ['ubudehe', 'ubudehe'], - 9 => ['education', 'education'], - 19 => ['cell', 'cell'], - 21 => ['health_center', 'health_center'], - ]; - - /** - * {@inheritdoc} - */ - public $fields = [ - 'title' => 'title', - 'clinic' => 'clinic', - ]; - - /** - * HedleyMigrateMothers201905 constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateClinics_2019_02', - ]; - - $this->addFieldMapping('title', 'title'); - $this->addFieldMapping('field_education_level', 'education'); - $this->addFieldMapping('field_ubudehe', 'ubudehe'); - - $this - ->addFieldMapping('field_date_birth', 'birth_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_clinic', 'clinic') - ->sourceMigration('HedleyMigrateClinics_2019_02'); - } - - /** - * Calculate some values. - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - // Calculate the mother's name. - $row->title = implode(' ', array_filter([ - trim($row->second_name), - trim($row->first_name), - trim($row->middle_name), - ])); - - $row->clinic = 'RUSHASHI'; - - $education = strtolower(trim($row->education)); - - // Education. - if ($education) { - if ($education === 'primary') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'primary school') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'primary schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif ($education === 'secondary') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'secondary school') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'secondary schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - elseif ($education === 'advanced diploma') { - $row->education = HEDLEY_PATIENT_EDUCATION_ADVANCED; - } - elseif ($education === 'no schooling') { - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif ($education === 'ntabwoyize') { - // Means "no education". - $row->education = HEDLEY_PATIENT_EDUCATION_NONE; - } - elseif (preg_match('/^p[1-8]$/', $education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_PRIMARY; - } - elseif (preg_match('/^s[1-6]$/', $education)) { - $row->education = HEDLEY_PATIENT_EDUCATION_SECONDARY; - } - else { - throw new Exception("{$row->education} is not a recognized education level for {$row->id}."); - } - } - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - // Some dates are year-only ... we'll make those Jan. 1. - if (preg_match('/^\\d\\d\\d\\d$/', $trimmed)) { - $trimmed = "$trimmed-01-01"; - } - - if (preg_match('/^\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - } - - if (preg_match('@^\\d\\d?/\\d\\d?/\\d\\d\\d\\d@', $trimmed)) { - return DateTime::createFromFormat('!d/m/Y', $trimmed)->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - -} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateAcuteIllnessEncounters.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateAcuteIllnessEncounters.php new file mode 100644 index 0000000000..1756d5d4a5 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateAcuteIllnessEncounters.php @@ -0,0 +1,49 @@ +dependencies[] = 'HedleyMigrateAcuteIllnessEncounters'; + + $this + ->addFieldMapping('field_acute_illness_encounter', 'field_acute_illness_encounter') + ->sourceMigration('HedleyMigrateAcuteIllnessEncounters'); + } + +} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateAttendances.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateAttendances.php deleted file mode 100644 index a53e1a288e..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateAttendances.php +++ /dev/null @@ -1,38 +0,0 @@ -dependencies[] = 'HedleyMigrateSessions'; + + $this + ->addFieldMapping('field_session', 'field_session') + ->sourceMigration('HedleyMigrateSessions'); + } + +} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateHealthCenters.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateHealthCenters.php index e9b4fa2b86..4eb1bab24f 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateHealthCenters.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateHealthCenters.php @@ -23,12 +23,18 @@ class HedleyMigrateHealthCenters extends HedleyMigrateBase { /** * {@inheritdoc} */ - protected $csvColumns = [ - 'id', - 'title_field', - 'field_catchment_area', - 'created', - ]; + protected function csvColumns() { + $columns = parent::csvColumns(); + + return array_merge( + $columns, [ + 'id', + 'title_field', + 'field_catchment_area', + 'created', + ] + ); + } /** * HedleyMigrateHealthCenters constructor. diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateHeights.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateHeights.php deleted file mode 100644 index b9b7a3a79b..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateHeights.php +++ /dev/null @@ -1,40 +0,0 @@ -dependencies = [ + 'HedleyMigrateIndividualParticipants', + ]; + + $this + ->addFieldMapping('field_scheduled_date', 'field_scheduled_date') + ->callbacks([$this, 'date2Process']); + + $this + ->addFieldMapping('field_individual_participant', 'field_individual_participant') + ->sourceMigration('HedleyMigrateIndividualParticipants'); + } + +} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateIndividualParticipants.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateIndividualParticipants.php index 7dc9863799..324bd78614 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateIndividualParticipants.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateIndividualParticipants.php @@ -23,19 +23,38 @@ class HedleyMigrateIndividualParticipants extends HedleyMigrateBase { /** * {@inheritdoc} */ - protected $csvColumns = [ - 'id', - 'field_person', - 'field_expected', - 'field_encounter_type', - ]; + protected function csvColumns() { + $columns = parent::csvColumns(); + + return array_merge( + $columns, [ + 'id', + 'field_person', + 'field_expected', + 'field_encounter_type', + 'field_date_concluded', + 'field_outcome', + 'field_outcome_location', + 'field_expected_date_concluded', + 'created', + ] + ); + } /** * {@inheritdoc} */ - protected $simpleMappings = [ - 'field_encounter_type', - ]; + protected function simpleMappings() { + $mappings = parent::simpleMappings(); + + return array_merge( + $mappings, [ + 'field_encounter_type', + 'field_outcome', + 'field_outcome_location', + ] + ); + } /** * HedleyMigrateRelationships constructor. @@ -55,35 +74,15 @@ public function __construct($arguments) { $this ->addFieldMapping('field_expected', 'field_expected') - ->callbacks([$this, 'dateProcess']); - } + ->callbacks([$this, 'date2Process']); - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return array - * A start date. - */ - public function dateProcess($date) { - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - $stamp = DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - - return [ - 'value' => $stamp, - 'value2' => NULL, - ]; - } + $this + ->addFieldMapping('field_date_concluded', 'field_date_concluded') + ->callbacks([$this, 'dateProcess']); - throw new Exception("$date was not a recognized date format."); + $this + ->addFieldMapping('field_expected_date_concluded', 'field_expected_date_concluded') + ->callbacks([$this, 'dateProcess']); } } diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateMeasurementBase.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateMeasurementBase.php similarity index 77% rename from server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateMeasurementBase.php rename to server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateMeasurementBase.php index 93d603460d..9f37e35d00 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/HedleyMigrateMeasurementBase.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateMeasurementBase.php @@ -17,6 +17,23 @@ abstract class HedleyMigrateMeasurementBase extends HedleyMigrateBase { */ protected $entityType = 'node'; + /** + * {@inheritdoc} + */ + protected function csvColumns() { + $columns = parent::csvColumns(); + + return array_merge( + $columns, [ + 'id', + 'field_person', + 'field_date_measured', + 'field_nurse', + 'created', + ] + ); + } + /** * HedleyMigrateMeasurementBase constructor. * @@ -28,7 +45,6 @@ public function __construct($arguments) { $this->dependencies = [ 'HedleyMigratePeople', 'HedleyMigrateNurses', - 'HedleyMigrateSessions', 'HedleyMigrateHealthCenters', ]; @@ -43,10 +59,6 @@ public function __construct($arguments) { $this ->addFieldMapping('field_nurse', 'field_nurse') ->sourceMigration('HedleyMigrateNurses'); - - $this - ->addFieldMapping('field_session', 'field_session') - ->sourceMigration('HedleyMigrateSessions'); } } diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateMissingHeights.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateMissingHeights.php deleted file mode 100644 index 8ab7100310..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateMissingHeights.php +++ /dev/null @@ -1,25 +0,0 @@ -dependencies[] = 'HedleyMigrateNutritionEncounters'; + + $this + ->addFieldMapping('field_nutrition_encounter', 'field_nutrition_encounter') + ->sourceMigration('HedleyMigrateNutritionEncounters'); + } + +} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateNutritions.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateNutritions.php deleted file mode 100644 index 97740e439b..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateNutritions.php +++ /dev/null @@ -1,38 +0,0 @@ -defaultValue($this->getMigrateDirectory() . '/images/'); } - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - return DateTime::createFromFormat('!Y-m-d', $trimmed, new DateTimeZone("UTC"))->getTimestamp(); - } - - throw new Exception("$date was not a recognized date format."); - } - } diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePmtctParticipants.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePmtctParticipants.php index 6da5938ee8..5365f50649 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePmtctParticipants.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePmtctParticipants.php @@ -23,22 +23,34 @@ class HedleyMigratePmtctParticipants extends HedleyMigrateBase { /** * {@inheritdoc} */ - protected $csvColumns = [ - 'id', - 'field_person', - 'field_adult', - 'field_adult_activities', - 'field_expected', - 'field_clinic', - 'created', - ]; + protected function csvColumns() { + $columns = parent::csvColumns(); + + return array_merge( + $columns, [ + 'id', + 'field_person', + 'field_adult', + 'field_adult_activities', + 'field_expected', + 'field_clinic', + 'created', + ] + ); + } /** * {@inheritdoc} */ - protected $simpleMappings = [ - 'field_adult_activities', - ]; + protected function simpleMappings() { + $mappings = parent::simpleMappings(); + + return array_merge( + $mappings, [ + 'field_adult_activities', + ] + ); + } /** * HedleyMigratePmtctParticipants constructor. diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePrenatalEncounters.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePrenatalEncounters.php index 40c3f54692..51525df2ca 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePrenatalEncounters.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePrenatalEncounters.php @@ -8,7 +8,7 @@ /** * Class HedleyMigratePrenatalEncounters. */ -class HedleyMigratePrenatalEncounters extends HedleyMigrateBase { +class HedleyMigratePrenatalEncounters extends HedleyMigrateIndividualEncounterBase { /** * {@inheritdoc} @@ -20,63 +20,4 @@ class HedleyMigratePrenatalEncounters extends HedleyMigrateBase { */ protected $bundle = 'prenatal_encounter'; - /** - * {@inheritdoc} - */ - protected $csvColumns = [ - 'id', - 'field_individual_participant', - 'field_scheduled_date', - ]; - - /** - * HedleyMigratePrenatalEncounters constructor. - * - * {@inheritdoc} - */ - public function __construct($arguments) { - parent::__construct($arguments); - - $this->dependencies = [ - 'HedleyMigrateIndividualParticipants', - ]; - - $this - ->addFieldMapping('field_scheduled_date', 'field_scheduled_date') - ->callbacks([$this, 'dateProcess']); - - $this - ->addFieldMapping('field_individual_participant', 'field_individual_participant') - ->sourceMigration('HedleyMigrateIndividualParticipants'); - } - - /** - * Convert a date string to a timestamp. - * - * @param string $date - * A string containing a date. - * - * @return int - * A timestamp. - */ - public function dateProcess($date) { - // The source material uses several date formats. - $trimmed = trim($date); - - if (empty($trimmed)) { - return $trimmed; - } - - if (preg_match('/^\\d\\d\\d\\d-\\d\\d-\\d\\d$/', $trimmed)) { - $stamp = DateTime::createFromFormat('!Y-m-d', $trimmed)->getTimestamp(); - - return [ - 'value' => $stamp, - 'value2' => NULL, - ]; - } - - throw new Exception("$date was not a recognized date format."); - } - } diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePrenatalMeasurementBase.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePrenatalMeasurementBase.php new file mode 100644 index 0000000000..9127baf506 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigratePrenatalMeasurementBase.php @@ -0,0 +1,41 @@ +dependencies[] = 'HedleyMigratePrenatalEncounters'; + + $this + ->addFieldMapping('field_prenatal_encounter', 'field_prenatal_encounter') + ->sourceMigration('HedleyMigratePrenatalEncounters'); + } + +} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateRelationships.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateRelationships.php index a7a82a67fb..5982e257d7 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateRelationships.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateRelationships.php @@ -23,20 +23,32 @@ class HedleyMigrateRelationships extends HedleyMigrateBase { /** * {@inheritdoc} */ - protected $csvColumns = [ - 'id', - 'field_person', - 'field_related_by', - 'field_related_to', - 'created', - ]; + protected function csvColumns() { + $columns = parent::csvColumns(); + + return array_merge( + $columns, [ + 'id', + 'field_person', + 'field_related_by', + 'field_related_to', + 'created', + ] + ); + } /** * {@inheritdoc} */ - protected $simpleMappings = [ - 'field_related_by', - ]; + protected function simpleMappings() { + $mappings = parent::simpleMappings(); + + return array_merge( + $mappings, [ + 'field_related_by', + ] + ); + } /** * HedleyMigrateRelationships constructor. diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateSessions.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateSessions.php index 541d84ea31..3b854b3fd8 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateSessions.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateSessions.php @@ -23,12 +23,18 @@ class HedleyMigrateSessions extends HedleyMigrateBase { /** * {@inheritdoc} */ - protected $csvColumns = [ - 'id', - 'field_clinic', - 'field_scheduled_date', - 'created', - ]; + protected function csvColumns() { + $columns = parent::csvColumns(); + + return array_merge( + $columns, [ + 'id', + 'field_clinic', + 'field_scheduled_date', + 'created', + ] + ); + } /** * HedleyMigrateSessions constructor. diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateVillages.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateVillages.php index bad7120dcb..a444aab2e8 100644 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateVillages.php +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateVillages.php @@ -23,27 +23,39 @@ class HedleyMigrateVillages extends HedleyMigrateBase { /** * {@inheritdoc} */ - protected $csvColumns = [ - 'id', - 'field_province', - 'field_district', - 'field_sector', - 'field_cell', - 'field_village', - 'field_health_center', - 'created', - ]; + protected function csvColumns() { + $columns = parent::csvColumns(); + + return array_merge( + $columns, [ + 'id', + 'field_province', + 'field_district', + 'field_sector', + 'field_cell', + 'field_village', + 'field_health_center', + 'created', + ] + ); + } /** * {@inheritdoc} */ - protected $simpleMappings = [ - 'field_province', - 'field_district', - 'field_sector', - 'field_cell', - 'field_village', - ]; + protected function simpleMappings() { + $mappings = parent::simpleMappings(); + + return array_merge( + $mappings, [ + 'field_province', + 'field_district', + 'field_sector', + 'field_cell', + 'field_village', + ] + ); + } /** * HedleyMigrateVillages constructor. diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateWeights.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateWeights.php deleted file mode 100644 index 478db921a4..0000000000 --- a/server/hedley/modules/custom/hedley_migrate/handlers/node/HedleyMigrateWeights.php +++ /dev/null @@ -1,46 +0,0 @@ -addFieldMapping('field_photo', 'field_photo'); + $this->addFieldMapping('field_photo:file_replace') + ->defaultValue(FILE_EXISTS_REPLACE); + $this->addFieldMapping('field_photo:source_dir') + ->defaultValue($this->getMigrateDirectory() . '/images/'); + } + +} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/nutrition/HedleyMigrateNutritionWeight.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/nutrition/HedleyMigrateNutritionWeight.php new file mode 100644 index 0000000000..5639928edc --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/nutrition/HedleyMigrateNutritionWeight.php @@ -0,0 +1,52 @@ +addFieldMapping('field_last_menstrual_period', 'field_last_menstrual_period') + ->callbacks([$this, 'dateProcess']); + } + +} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/prenatal/HedleyMigrateMedicalHistory.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/prenatal/HedleyMigrateMedicalHistory.php new file mode 100644 index 0000000000..3a8742f4e7 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/prenatal/HedleyMigrateMedicalHistory.php @@ -0,0 +1,44 @@ +addFieldMapping('field_photo', 'field_photo'); + $this->addFieldMapping('field_photo:file_replace') + ->defaultValue(FILE_EXISTS_REPLACE); + $this->addFieldMapping('field_photo:source_dir') + ->defaultValue($this->getMigrateDirectory() . '/images/'); + } + +} diff --git a/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/prenatal/HedleyMigrateResource.php b/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/prenatal/HedleyMigrateResource.php new file mode 100644 index 0000000000..8a27aa6d18 --- /dev/null +++ b/server/hedley/modules/custom/hedley_migrate/handlers/node/activity/prenatal/HedleyMigrateResource.php @@ -0,0 +1,44 @@ + 2, 'groups' => [ - 'missing' => [ - 'title' => t('Missing Data'), - ], - 'batch_2019_02' => [ - 'title' => t('Batch data added 2019/02'), - ], - 'batch_2019_03' => [ - 'title' => t('Batch data added 2019/03'), - ], 'counseling' => [ 'title' => t('Counseling'), ], 'forms' => [ 'title' => t('Forms'), ], - 'batch_2019_04' => [ - 'title' => t('Batch data added 2019/04'), - ], - 'batch_2019_04_2' => [ - 'title' => t('Second batch data added 2019/04'), - ], - 'batch_2019_05' => [ - 'title' => t('Batch data added 2019/05'), - ], - 'batch_2019_05_2' => [ - 'title' => t('Second batch data added 2019/05'), - ], - 'batch_2019_05_3' => [ - 'title' => t('Third batch data added 2019/05'), - ], - 'chw_deploy' => [ - 'title' => t('CHW deploy'), - ], ], 'migrations' => [ - 'HedleyMigrateClinics_2019_02' => [ - 'class_name' => 'HedleyMigrateClinics201902', - 'group_name' => 'batch_2019_02', + 'HedleyMigrateAcuteFindings' => [ + 'class_name' => 'HedleyMigrateAcuteFindings', ], - 'HedleyMigrateMothers_2019_02' => [ - 'class_name' => 'HedleyMigrateMothers201902', - 'group_name' => 'batch_2019_02', + 'HedleyMigrateAcuteIllnessDangerSigns' => [ + 'class_name' => 'HedleyMigrateAcuteIllnessDangerSigns', ], - 'HedleyMigrateChildren_2019_02' => [ - 'class_name' => 'HedleyMigrateChildren201902', - 'group_name' => 'batch_2019_02', + 'HedleyMigrateAcuteIllnessEncounters' => [ + 'class_name' => 'HedleyMigrateAcuteIllnessEncounters', ], - 'HedleyMigrateMothers_2019_03' => [ - 'class_name' => 'HedleyMigrateMothers201903', - 'group_name' => 'batch_2019_03', + 'HedleyMigrateAcuteIllnessMuac' => [ + 'class_name' => 'HedleyMigrateAcuteIllnessMuac', ], - 'HedleyMigrateChildren_2019_03' => [ - 'class_name' => 'HedleyMigrateChildren201903', - 'group_name' => 'batch_2019_03', + 'HedleyMigrateAcuteIllnessNutrition' => [ + 'class_name' => 'HedleyMigrateAcuteIllnessNutrition', ], - 'HedleyMigrateMothers_2019_04' => [ - 'class_name' => 'HedleyMigrateMothers201904', - 'group_name' => 'batch_2019_04', + 'HedleyMigrateAcuteIllnessVitals' => [ + 'class_name' => 'HedleyMigrateAcuteIllnessVitals', ], - 'HedleyMigrateChildren_2019_04' => [ - 'class_name' => 'HedleyMigrateChildren201904', - 'group_name' => 'batch_2019_04', + 'HedleyMigrateAttendances' => [ + 'class_name' => 'HedleyMigrateAttendances', ], - 'HedleyMigrateClinics_2019_04' => [ - 'class_name' => 'HedleyMigrateClinics201904', - 'group_name' => 'batch_2019_04', + 'HedleyMigrateBreastExams' => [ + 'class_name' => 'HedleyMigrateBreastExams', ], - 'HedleyMigrateMothers_2019_04_2' => [ - 'class_name' => 'HedleyMigrateMothers2019042', - 'group_name' => 'batch_2019_04_2', + 'HedleyMigrateCall114' => [ + 'class_name' => 'HedleyMigrateCall114', ], - 'HedleyMigrateChildren_2019_04_2' => [ - 'class_name' => 'HedleyMigrateChildren2019042', - 'group_name' => 'batch_2019_04_2', + 'HedleyMigrateCatchmentAreas' => [ + 'class_name' => 'HedleyMigrateCatchmentAreas', ], - 'HedleyMigrateMothers_2019_05' => [ - 'class_name' => 'HedleyMigrateMothers201905', - 'group_name' => 'batch_2019_05', + 'HedleyMigrateChildFbfs' => [ + 'class_name' => 'HedleyMigrateChildFbfs', ], - 'HedleyMigrateChildren_2019_05' => [ - 'class_name' => 'HedleyMigrateChildren201905', - 'group_name' => 'batch_2019_05', + 'HedleyMigrateClinics' => [ + 'class_name' => 'HedleyMigrateClinics', ], - 'HedleyMigrateMothers_2019_05_2' => [ - 'class_name' => 'HedleyMigrateMothers2019052', - 'group_name' => 'batch_2019_05_2', + 'HedleyMigrateCorePhysicalExam' => [ + 'class_name' => 'HedleyMigrateCorePhysicalExam', ], - 'HedleyMigrateChildren_2019_05_2' => [ - 'class_name' => 'HedleyMigrateChildren2019052', - 'group_name' => 'batch_2019_05_2', + 'HedleyMigrateCounselingSchedules' => [ + 'class_name' => 'HedleyMigrateCounselingSchedules', + 'group_name' => 'counseling', ], - 'HedleyMigrateMothers_2019_05_3' => [ - 'class_name' => 'HedleyMigrateMothers2019053', - 'group_name' => 'batch_2019_05_3', + 'HedleyMigrateCounselingSessions' => [ + 'class_name' => 'HedleyMigrateCounselingSessions', + 'group_name' => 'counseling', ], - 'HedleyMigrateChildren_2019_05_3' => [ - 'class_name' => 'HedleyMigrateChildren2019053', - 'group_name' => 'batch_2019_05_3', + 'HedleyMigrateCounselingTopics' => [ + 'class_name' => 'HedleyMigrateCounselingTopics', + 'group_name' => 'counseling', ], - 'HedleyMigrateUsers' => [ - 'class_name' => 'HedleyMigrateUsers', + 'HedleyMigrateDangerSigns' => [ + 'class_name' => 'HedleyMigrateDangerSigns', ], 'HedleyMigrateDevices' => [ 'class_name' => 'HedleyMigrateDevices', ], - 'HedleyMigrateClinics' => [ - 'class_name' => 'HedleyMigrateClinics', + 'HedleyMigrateExposure' => [ + 'class_name' => 'HedleyMigrateExposure', ], - 'HedleyMigratePmtctParticipants' => [ - 'class_name' => 'HedleyMigratePmtctParticipants', + 'HedleyMigrateFamilyPlannings' => [ + 'class_name' => 'HedleyMigrateFamilyPlannings', ], - 'HedleyMigratePrenatalEncounters' => [ - 'class_name' => 'HedleyMigratePrenatalEncounters', + 'HedleyMigrateHealthCenters' => [ + 'class_name' => 'HedleyMigrateHealthCenters', + ], + 'HedleyMigrateHCContact' => [ + 'class_name' => 'HedleyMigrateHCContact', + ], + 'HedleyMigrateHealthEducation' => [ + 'class_name' => 'HedleyMigrateHealthEducation', + ], + 'HedleyMigrateHeights' => [ + 'class_name' => 'HedleyMigrateHeights', ], 'HedleyMigrateIndividualParticipants' => [ 'class_name' => 'HedleyMigrateIndividualParticipants', ], - 'HedleyMigrateRelationships' => [ - 'class_name' => 'HedleyMigrateRelationships', - ], - 'HedleyMigrateSessions' => [ - 'class_name' => 'HedleyMigrateSessions', + 'HedleyMigrateIsolation' => [ + 'class_name' => 'HedleyMigrateIsolation', ], - 'HedleyMigrateCatchmentAreas' => [ - 'class_name' => 'HedleyMigrateCatchmentAreas', + 'HedleyMigrateLactations' => [ + 'class_name' => 'HedleyMigrateLactations', ], - 'HedleyMigrateHealthCenters' => [ - 'class_name' => 'HedleyMigrateHealthCenters', + 'HedleyMigrateLastMenstrualPeriod' => [ + 'class_name' => 'HedleyMigrateLastMenstrualPeriod', ], - 'HedleyMigratePeople' => [ - 'class_name' => 'HedleyMigratePeople', + 'HedleyMigrateMalariaTesting' => [ + 'class_name' => 'HedleyMigrateMalariaTesting', ], - 'HedleyMigrateNurses' => [ - 'class_name' => 'HedleyMigrateNurses', + 'HedleyMigrateMedicalHistory' => [ + 'class_name' => 'HedleyMigrateMedicalHistory', ], - 'HedleyMigrateAttendances' => [ - 'class_name' => 'HedleyMigrateAttendances', + 'HedleyMigrateMedication' => [ + 'class_name' => 'HedleyMigrateMedication', ], - 'HedleyMigrateFamilyPlannings' => [ - 'class_name' => 'HedleyMigrateFamilyPlannings', + 'HedleyMigrateMedicationDistribution' => [ + 'class_name' => 'HedleyMigrateMedicationDistribution', ], - 'HedleyMigrateHeights' => [ - 'class_name' => 'HedleyMigrateHeights', + 'HedleyMigrateMotherFbfs' => [ + 'class_name' => 'HedleyMigrateMotherFbfs', ], 'HedleyMigrateMuacs' => [ 'class_name' => 'HedleyMigrateMuacs', ], + 'HedleyMigrateNurses' => [ + 'class_name' => 'HedleyMigrateNurses', + ], + 'HedleyMigrateNutritionEncounters' => [ + 'class_name' => 'HedleyMigrateNutritionEncounters', + ], 'HedleyMigrateNutritions' => [ 'class_name' => 'HedleyMigrateNutritions', ], - 'HedleyMigratePhotos' => [ - 'class_name' => 'HedleyMigratePhotos', - ], - 'HedleyMigrateWeights' => [ - 'class_name' => 'HedleyMigrateWeights', + 'HedleyMigrateNutritionHeight' => [ + 'class_name' => 'HedleyMigrateNutritionHeight', ], - 'HedleyMigrateVillages' => [ - 'class_name' => 'HedleyMigrateVillages', + 'HedleyMigrateNutritionMuac' => [ + 'class_name' => 'HedleyMigrateNutritionMuac', ], - 'HedleyMigrateMissingHeights' => [ - 'class_name' => 'HedleyMigrateMissingHeights', - 'group_name' => 'missing', + 'HedleyMigrateNutritionNutritions' => [ + 'class_name' => 'HedleyMigrateNutritionNutritions', ], - 'HedleyMigrateMissingWeights' => [ - 'class_name' => 'HedleyMigrateMissingWeights', - 'group_name' => 'missing', + 'HedleyMigrateNutritionPhoto' => [ + 'class_name' => 'HedleyMigrateNutritionPhoto', ], - 'HedleyMigrateMissingMuacs' => [ - 'class_name' => 'HedleyMigrateMissingMuacs', - 'group_name' => 'missing', + 'HedleyMigrateNutritionWeight' => [ + 'class_name' => 'HedleyMigrateNutritionWeight', ], - 'HedleyMigrateCounselingSchedules' => [ - 'class_name' => 'HedleyMigrateCounselingSchedules', - 'group_name' => 'counseling', + 'HedleyMigrateObstetricHistory' => [ + 'class_name' => 'HedleyMigrateObstetricHistory', ], - 'HedleyMigrateCounselingSessions' => [ - 'class_name' => 'HedleyMigrateCounselingSessions', - 'group_name' => 'counseling', + 'HedleyMigrateObstetricHistoryStep2' => [ + 'class_name' => 'HedleyMigrateObstetricHistoryStep2', ], - 'HedleyMigrateCounselingTopics' => [ - 'class_name' => 'HedleyMigrateCounselingTopics', - 'group_name' => 'counseling', + 'HedleyMigrateObstetricalExam' => [ + 'class_name' => 'HedleyMigrateObstetricalExam', ], 'HedleyMigrateParticipantForms' => [ 'class_name' => 'HedleyMigrateParticipantForms', 'group_name' => 'forms', ], - 'HedleyMigrateVillagesChwDeploy' => [ - 'class_name' => 'HedleyMigrateVillagesChwDeploy', - 'group_name' => 'chw_deploy', + 'HedleyMigratePeople' => [ + 'class_name' => 'HedleyMigratePeople', + ], + 'HedleyMigratePhotos' => [ + 'class_name' => 'HedleyMigratePhotos', + ], + 'HedleyMigratePmtctParticipants' => [ + 'class_name' => 'HedleyMigratePmtctParticipants', + ], + 'HedleyMigratePrenatalEncounters' => [ + 'class_name' => 'HedleyMigratePrenatalEncounters', + ], + 'HedleyMigratePrenatalFamilyPlanning' => [ + 'class_name' => 'HedleyMigratePrenatalFamilyPlanning', + ], + 'HedleyMigratePrenatalNutrition' => [ + 'class_name' => 'HedleyMigratePrenatalNutrition', + ], + 'HedleyMigratePrenatalPhoto' => [ + 'class_name' => 'HedleyMigratePrenatalPhoto', + ], + 'HedleyMigrateRelationships' => [ + 'class_name' => 'HedleyMigrateRelationships', + ], + 'HedleyMigrateResource' => [ + 'class_name' => 'HedleyMigrateResource', + ], + 'HedleyMigrateSendToHC' => [ + 'class_name' => 'HedleyMigrateSendToHC', + ], + 'HedleyMigrateSessions' => [ + 'class_name' => 'HedleyMigrateSessions', + ], + 'HedleyMigrateSocialHistory' => [ + 'class_name' => 'HedleyMigrateSocialHistory', + ], + 'HedleyMigrateSymptomsGI' => [ + 'class_name' => 'HedleyMigrateSymptomsGI', + ], + 'HedleyMigrateSymptomsGeneral' => [ + 'class_name' => 'HedleyMigrateSymptomsGeneral', + ], + 'HedleyMigrateSymptomsRespiratory' => [ + 'class_name' => 'HedleyMigrateSymptomsRespiratory', + ], + 'HedleyMigrateTravelHistory' => [ + 'class_name' => 'HedleyMigrateTravelHistory', + ], + 'HedleyMigrateTreatmentHistory' => [ + 'class_name' => 'HedleyMigrateTreatmentHistory', + ], + 'HedleyMigrateTreatmentOngoing' => [ + 'class_name' => 'HedleyMigrateTreatmentOngoing', + ], + 'HedleyMigrateUsers' => [ + 'class_name' => 'HedleyMigrateUsers', + ], + 'HedleyMigrateVillages' => [ + 'class_name' => 'HedleyMigrateVillages', + ], + 'HedleyMigrateVitals' => [ + 'class_name' => 'HedleyMigrateVitals', + ], + 'HedleyMigrateWeights' => [ + 'class_name' => 'HedleyMigrateWeights', ], ], ]; @@ -687,6 +712,23 @@ function hedley_migrate_resolve_for_export($type, $field, array $values) { return empty($result['node']) ? [] : array_keys($result['node']); } +/** + * Generates Date field for export. + * + * @param string $date + * Input date. + * + * @return string + * Date as 'yyyy-mm-dd'. If empty, returns empty string. + */ +function hedley_migrate_export_date_field($date) { + if (empty($date)) { + return ''; + } + + return date('Y-m-d', $date); +} + /** * Generates DateTime field for export. * @@ -701,7 +743,7 @@ function hedley_migrate_resolve_for_export($type, $field, array $values) { * Start date as 'yyyy-mm-dd'. * Optional End date (same format), piped by '|' separator. */ -function hedley_migrate_export_date_field(array $date, $force_end_date = FALSE) { +function hedley_migrate_export_date2_field(array $date, $force_end_date = FALSE) { $time1 = strtotime($date['value']); if (empty($date['value2'])) { diff --git a/server/hedley/modules/custom/hedley_migrate/images/baby-boy-1.jpg b/server/hedley/modules/custom/hedley_migrate/images/baby-boy-1.jpg index ac1b4db8ae..22961a0a07 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/baby-boy-1.jpg and b/server/hedley/modules/custom/hedley_migrate/images/baby-boy-1.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/baby-boy-2.jpg b/server/hedley/modules/custom/hedley_migrate/images/baby-boy-2.jpg index 20e9f9a73f..81d4a1a506 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/baby-boy-2.jpg and b/server/hedley/modules/custom/hedley_migrate/images/baby-boy-2.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/baby-boy-3.jpg b/server/hedley/modules/custom/hedley_migrate/images/baby-boy-3.jpg index cc83d98230..13717b4ecb 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/baby-boy-3.jpg and b/server/hedley/modules/custom/hedley_migrate/images/baby-boy-3.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/baby-boy-4.jpg b/server/hedley/modules/custom/hedley_migrate/images/baby-boy-4.jpg index 8062e910b0..0224e427f4 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/baby-boy-4.jpg and b/server/hedley/modules/custom/hedley_migrate/images/baby-boy-4.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/baby-girl-1.jpg b/server/hedley/modules/custom/hedley_migrate/images/baby-girl-1.jpg index 83f1429179..75f75565ed 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/baby-girl-1.jpg and b/server/hedley/modules/custom/hedley_migrate/images/baby-girl-1.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/baby-girl-2.jpg b/server/hedley/modules/custom/hedley_migrate/images/baby-girl-2.jpg index 48b519f3d0..e79a1ca04b 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/baby-girl-2.jpg and b/server/hedley/modules/custom/hedley_migrate/images/baby-girl-2.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/baby-girl-3.jpg b/server/hedley/modules/custom/hedley_migrate/images/baby-girl-3.jpg index 827aae1fc7..cbef15e01f 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/baby-girl-3.jpg and b/server/hedley/modules/custom/hedley_migrate/images/baby-girl-3.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/baby-girl-4.jpg b/server/hedley/modules/custom/hedley_migrate/images/baby-girl-4.jpg index 8b698bc018..6c72e7c509 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/baby-girl-4.jpg and b/server/hedley/modules/custom/hedley_migrate/images/baby-girl-4.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/father-1.jpg b/server/hedley/modules/custom/hedley_migrate/images/father-1.jpg index 38c8683c53..daae653df3 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/father-1.jpg and b/server/hedley/modules/custom/hedley_migrate/images/father-1.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/father-2.jpg b/server/hedley/modules/custom/hedley_migrate/images/father-2.jpg index bd3f6a6867..2574a38f7b 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/father-2.jpg and b/server/hedley/modules/custom/hedley_migrate/images/father-2.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/father-3.jpg b/server/hedley/modules/custom/hedley_migrate/images/father-3.jpg index f4482a7a6a..40e7182b3e 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/father-3.jpg and b/server/hedley/modules/custom/hedley_migrate/images/father-3.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/mother-1.jpg b/server/hedley/modules/custom/hedley_migrate/images/mother-1.jpg index 9dfc4fa8d5..af821fc159 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/mother-1.jpg and b/server/hedley/modules/custom/hedley_migrate/images/mother-1.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/mother-2.jpg b/server/hedley/modules/custom/hedley_migrate/images/mother-2.jpg index 89958ca1cf..2f022a44ec 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/mother-2.jpg and b/server/hedley/modules/custom/hedley_migrate/images/mother-2.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/mother-3.jpg b/server/hedley/modules/custom/hedley_migrate/images/mother-3.jpg index 43295390fa..18aa0d9435 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/mother-3.jpg and b/server/hedley/modules/custom/hedley_migrate/images/mother-3.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/mother-4.jpg b/server/hedley/modules/custom/hedley_migrate/images/mother-4.jpg index f3f0ebb647..2f4cc234a8 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/mother-4.jpg and b/server/hedley/modules/custom/hedley_migrate/images/mother-4.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/mother-5.jpg b/server/hedley/modules/custom/hedley_migrate/images/mother-5.jpg index 67fe0f5c61..0763218d49 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/mother-5.jpg and b/server/hedley/modules/custom/hedley_migrate/images/mother-5.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/mother-6.jpg b/server/hedley/modules/custom/hedley_migrate/images/mother-6.jpg index 073ccfa6e4..52b4820996 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/mother-6.jpg and b/server/hedley/modules/custom/hedley_migrate/images/mother-6.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/images/mother-7.jpg b/server/hedley/modules/custom/hedley_migrate/images/mother-7.jpg index 9625a750fc..90ac212bb2 100644 Binary files a/server/hedley/modules/custom/hedley_migrate/images/mother-7.jpg and b/server/hedley/modules/custom/hedley_migrate/images/mother-7.jpg differ diff --git a/server/hedley/modules/custom/hedley_migrate/scripts/export-content.php b/server/hedley/modules/custom/hedley_migrate/scripts/export-content.php index 9772b98def..18f59cf272 100644 --- a/server/hedley/modules/custom/hedley_migrate/scripts/export-content.php +++ b/server/hedley/modules/custom/hedley_migrate/scripts/export-content.php @@ -141,31 +141,72 @@ 'created', ], ]; -$measurements_fields = [ +$group_measurements_fields = [ 'id', 'field_person', 'field_date_measured', 'field_nurse', - 'field_session', 'created', + 'field_session', ]; -$measurements = [ - 'attendance' => [array_merge($measurements_fields, ['field_attended'])], +$group_measurements = [ + 'attendance' => [ + array_merge( + $group_measurements_fields, + ['field_attended'] + ), + ], + 'child_fbf' => [ + array_merge( + $group_measurements_fields, + ['field_distributed_amount', 'field_distribution_notice'] + ), + ], 'family_planning' => [ array_merge( - $measurements_fields, + $group_measurements_fields, ['field_family_planning_signs'] ), ], 'height' => [ array_merge( - $measurements_fields, + $group_measurements_fields, ['field_height', 'field_zscore_age'] ), ], + 'lactation' => [ + array_merge( + $group_measurements_fields, + ['field_lactation_signs'] + ), + ], + 'mother_fbf' => [ + array_merge( + $group_measurements_fields, + ['field_distributed_amount', 'field_distribution_notice'] + ), + ], + 'muac' => [ + array_merge( + $group_measurements_fields, + ['field_muac'] + ), + ], + 'nutrition' => [ + array_merge( + $group_measurements_fields, + ['field_nutrition_signs'] + ), + ], + 'photo' => [ + array_merge( + $group_measurements_fields, + ['field_photo'] + ), + ], 'weight' => [ array_merge( - $measurements_fields, + $group_measurements_fields, [ 'field_weight', 'field_bmi', @@ -175,282 +216,1192 @@ ] ), ], - 'muac' => [array_merge($measurements_fields, ['field_muac'])], - 'nutrition' => [array_merge($measurements_fields, ['field_nutrition_signs'])], - 'photo' => [array_merge($measurements_fields, ['field_photo'])], ]; +$individual_participants = [ + [ + 'id', + 'field_person', + 'field_expected', + 'field_encounter_type', + 'field_date_concluded', + 'field_outcome', + 'field_outcome_location', + 'field_expected_date_concluded', + 'created', + ], +]; +$acute_illness_encounters = [ + [ + 'id', + 'field_individual_participant', + 'field_scheduled_date', + 'created', + 'field_acute_illness_diagnosis', + ], +]; +$acute_illness_measurements_fields = [ + 'id', + 'field_person', + 'field_date_measured', + 'field_nurse', + 'created', + 'field_acute_illness_encounter', +]; +$acute_illness_measurements = [ + 'acute_findings' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_findings_signs_general', + 'field_findings_signs_respiratory', + ] + ), + ], + 'acute_illness_danger_signs' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_acute_illness_danger_signs', + ] + ), + ], + 'acute_illness_muac' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_muac', + ] + ), + ], + 'acute_illness_nutrition' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_nutrition_signs', + ] + ), + ], + 'acute_illness_vitals' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_respiratory_rate', + 'field_body_temperature', + ] + ), + ], + 'call_114' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_114_contact', + 'field_114_recommendation', + 'field_site_recommendation', + ] + ), + ], + 'exposure' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_exposure', + ] + ), + ], + 'hc_contact' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_hc_contact', + 'field_hc_recommendation', + 'field_hc_response_time', + 'field_ambulance_arrival_time', + ] + ), + ], + 'health_education' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_health_education_signs', + ] + ), + ], + 'isolation' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_isolation', + 'field_reason_for_not_isolating', + ] + ), + ], + 'malaria_testing' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_malaria_rapid_test', + ] + ), + ], + 'medication_distribution' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_prescribed_medication', + 'field_non_administration_reason', + ] + ), + ], + 'send_to_hc' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_send_to_hc', + ] + ), + ], + 'symptoms_general' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_fever_period', + 'field_chills_period', + 'field_night_sweats_period', + 'field_body_aches_period', + 'field_headache_period', + 'field_lethargy_period', + 'field_poor_suck_period', + 'field_unable_to_drink_period', + 'field_unable_to_eat_period', + 'field_increased_thirst_period', + 'field_dry_mouth_period', + 'field_severe_weakness_period', + 'field_yellow_eyes_period', + 'field_coke_colored_urine_period', + 'field_convulsions_period', + 'field_spontaneos_bleeding_period', + ] + ), + ], + 'symptoms_gi' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_bloody_diarrhea_period', + 'field_non_bloody_diarrhea_period', + 'field_nausea_period', + 'field_vomiting_period', + 'field_abdominal_pain_period', + 'field_symptoms_gi_derived_signs', + ] + ), + ], + 'symptoms_respiratory' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_cough_period', + 'field_shortness_of_breath_period', + 'field_nasal_congestion_period', + 'field_blood_in_sputum_period', + 'field_sore_throat_period', + 'field_loss_of_smell_period', + 'field_stabbing_chest_pain_period', + ] + ), + ], + 'travel_history' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_travel_history', + ] + ), + ], + 'treatment_history' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_treatment_history', + ] + ), + ], + 'treatment_ongoing' => [ + array_merge( + $acute_illness_measurements_fields, + [ + 'field_treatment_ongoing', + 'field_reason_for_not_taking', + 'field_missed_doses', + 'field_adverse_events', + ] + ), + ], +]; +$nutrition_encounters = [ + [ + 'id', + 'field_individual_participant', + 'field_scheduled_date', + 'created', + ], +]; +$nutrition_measurements_fields = [ + 'id', + 'field_person', + 'field_date_measured', + 'field_nurse', + 'created', + 'field_nutrition_encounter', +]; +$nutrition_measurements = [ + 'nutrition_height' => [ + array_merge( + $nutrition_measurements_fields, + [ + 'field_height', + 'field_zscore_age', + ] + ), + ], + 'nutrition_muac' => [ + array_merge( + $nutrition_measurements_fields, + [ + 'field_muac', + ] + ), + ], + 'nutrition_nutrition' => [ + array_merge( + $nutrition_measurements_fields, + [ + 'field_nutrition_signs', + ] + ), + ], + 'nutrition_photo' => [ + array_merge( + $nutrition_measurements_fields, + [ + 'field_photo', + ] + ), + ], + 'nutrition_weight' => [ + array_merge( + $nutrition_measurements_fields, + [ + 'field_weight', + 'field_bmi', + 'field_zscore_age', + 'field_zscore_length', + 'field_zscore_bmi', + ] + ), + ], +]; +$prenatal_encounters = [ + [ + 'id', + 'field_individual_participant', + 'field_scheduled_date', + 'created', + ], +]; +$prenatal_measurements_fields = [ + 'id', + 'field_person', + 'field_date_measured', + 'field_nurse', + 'created', + 'field_prenatal_encounter', +]; +$prenatal_measurements = [ + 'breast_exam' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_breast', + 'field_breast_self_exam', + ] + ), + ], + 'core_physical_exam' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_head_hair', + 'field_eyes', + 'field_neck', + 'field_heart', + 'field_heart_murmur', + 'field_lungs', + 'field_abdomen', + 'field_hands', + 'field_legs', + ] + ), + ], + 'danger_signs' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_danger_signs', + ] + ), + ], + 'last_menstrual_period' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_last_menstrual_period', + 'field_confident', + ] + ), + ], + 'medical_history' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_medical_history', + ] + ), + ], + 'medication' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_medication', + ] + ), + ], + 'obstetrical_exam' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_fundal_height', + 'field_fetal_presentation', + 'field_fetal_movement', + 'field_fetal_heart_rate', + 'field_c_section_scar', + ] + ), + ], + 'obstetric_history' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_currently_pregnant', + 'field_term_pregnancy', + 'field_preterm_pregnancy', + 'field_stillbirths_at_term', + 'field_stillbirths_preterm', + 'field_abortions', + 'field_live_children', + ] + ), + ], + 'obstetric_history_step2' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_c_sections', + 'field_c_section_reason', + 'field_previous_delivery_period', + 'field_obstetric_history', + 'field_previous_delivery', + ] + ), + ], + 'prenatal_family_planning' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_family_planning_signs', + ] + ), + ], + 'prenatal_nutrition' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_height', + 'field_weight', + 'field_muac', + ] + ), + ], + 'prenatal_photo' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_photo', + ] + ), + ], + 'resource' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_resources', + ] + ), + ], + 'social_history' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_social_history', + 'field_partner_hiv_testing', + ] + ), + ], + 'vitals' => [ + array_merge( + $prenatal_measurements_fields, + [ + 'field_sys', + 'field_dia', + 'field_heart_rate', + 'field_respiratory_rate', + 'field_body_temperature', + ] + ), + ], +]; + +$male_first_names = hedley_migrate_male_first_names(); +$female_first_names = hedley_migrate_female_first_names(); +$second_names = hedley_migrate_second_names(); +$total_male_first_names = count($male_first_names); +$total_female_first_names = count($female_first_names); +$total_second_names = count($second_names); +$total_males = 0; +$total_females = 0; + +$catchment_area_ids = []; +foreach ($health_centers_ids as $health_center_id) { + $node = node_load($health_center_id); + + if (!$node) { + drush_print("Error: can't find health center with ID $health_center_id!"); + exit; + } + + $wrapper = entity_metadata_wrapper('node', $node); + + $catchment_area_id = $wrapper->field_catchment_area->getIdentifier(); + + $health_centers[] = [ + $wrapper->getIdentifier(), + str_replace(',', ' ', $wrapper->label()), + $catchment_area_id, + $node->created, + ]; + + if (!in_array($catchment_area_id, $catchment_area_ids)) { + $wrapper = entity_metadata_wrapper('node', $catchment_area_id); + $catchment_areas[] = [ + $wrapper->getIdentifier(), + str_replace(',', ' ', $wrapper->label()), + $wrapper->created->raw(), + ]; + $catchment_area_ids[] = $catchment_area_id; + } + + $villages_ids = hedley_migrate_resolve_for_export('village', 'field_health_center', [$health_center_id]); + foreach ($villages_ids as $village_id) { + $wrapper = entity_metadata_wrapper('node', $village_id); + $villages[] = [ + $wrapper->getIdentifier(), + $wrapper->field_province->value(), + $wrapper->field_district->value(), + $wrapper->field_sector->value(), + $wrapper->field_cell->value(), + $wrapper->field_village->value(), + $wrapper->field_health_center->getIdentifier(), + $wrapper->created->raw(), + ]; + } + + $groups_ids = hedley_migrate_resolve_for_export('clinic', 'field_health_center', [$health_center_id]); + foreach ($groups_ids as $index => $group_id) { + $wrapper = entity_metadata_wrapper('node', $group_id); + $group_type = $wrapper->field_group_type->value(); + + if ($group_type == 'chw') { + // Chw groups automatically created during villages migration. + // Therefore, we skip them here. + unset($groups_ids[$index]); + continue; + } + + $groups[] = [ + $wrapper->getIdentifier(), + str_replace(',', ' ', $wrapper->label()), + $group_type, + $wrapper->field_health_center->getIdentifier(), + $wrapper->created->raw(), + ]; + } + $groups_ids = array_values($groups_ids); + + $nurses_ids = hedley_migrate_resolve_for_export('nurse', 'field_health_centers', [$health_center_id]); + foreach ($nurses_ids as $nurse_id) { + $wrapper = entity_metadata_wrapper('node', $nurse_id); + + $hc_ids = $wrapper->field_health_centers->value(['identifier' => TRUE]); + foreach ($hc_ids as $key => $hc_id) { + if (!in_array($hc_id, $health_centers_ids)) { + unset($hc_ids[$key]); + } + } + + $villages_ids = $wrapper->field_villages->value(['identifier' => TRUE]); + foreach ($villages_ids as $key => $village_id) { + $village_wrapper = entity_metadata_wrapper('node', $village_id); + $hc_id = $village_wrapper->field_health_center->getIdentifier(); + + if (!in_array($hc_id, $health_centers_ids)) { + unset($villages_ids[$key]); + } + } + + $nurses[$nurse_id] = [ + $nurse_id, + str_replace(',', ' ', $wrapper->label()), + implode('|', $wrapper->field_role->value()), + implode('|', array_values($hc_ids)), + implode('|', array_values($villages_ids)), + $wrapper->field_pin_code->value(), + $wrapper->created->raw(), + ]; + } + + $group_encounters_ids = hedley_migrate_resolve_for_export('session', 'field_clinic', $groups_ids); + foreach ($group_encounters_ids as $group_encounter_id) { + $wrapper = entity_metadata_wrapper('node', $group_encounter_id); + $group_encounters[] = [ + $wrapper->getIdentifier(), + $wrapper->field_clinic->getIdentifier(), + hedley_migrate_export_date2_field($wrapper->field_scheduled_date->value(), TRUE), + $wrapper->created->raw(), + ]; + } + + $participants_ids = hedley_migrate_resolve_for_export('pmtct_participant', 'field_clinic', $groups_ids); + $mothers_ids = $children_ids = []; + foreach ($participants_ids as $participant_id) { + $wrapper = entity_metadata_wrapper('node', $participant_id); + $mothers_ids[] = $wrapper->field_adult->getIdentifier(); + $children_ids[] = $wrapper->field_person->getIdentifier(); + + $participants[] = [ + $wrapper->getIdentifier(), + $wrapper->field_person->getIdentifier(), + $wrapper->field_adult->getIdentifier(), + $wrapper->field_adult_activities->value(), + hedley_migrate_export_date2_field($wrapper->field_expected->value()), + $wrapper->field_clinic->getIdentifier(), + $wrapper->created->raw(), + ]; + } + + $unique_mothers_ids = array_unique($mothers_ids); + $groups_patients_ids = array_merge($unique_mothers_ids, array_unique($children_ids)); + $health_center_patients_ids = hedley_migrate_resolve_for_export('person', 'field_health_center', [$health_center_id]); + + $people_ids = array_unique(array_merge($groups_patients_ids, $health_center_patients_ids)); + foreach ($people_ids as $person_id) { + $wrapper = entity_metadata_wrapper('node', $person_id); + $gender = $wrapper->field_gender->value(); + $birth_date = $wrapper->field_birth_date->value(); + + if ($health_centers_data[$health_center_id]['anonymize']) { + if ($gender == 'male') { + $total_males++; + $first_name_id = ($total_males - 1) % $total_male_first_names; + $second_name_id = (($total_males - 1) / $total_male_first_names) % $total_second_names; + $first_name = $male_first_names[$first_name_id]; + $second_name = $second_names[$second_name_id]; + } + else { + $total_females++; + $first_name_id = ($total_females - 1) % $total_female_first_names; + $second_name_id = (($total_females - 1) / $total_female_first_names) % $total_second_names; + $first_name = $female_first_names[$first_name_id]; + $second_name = $second_names[$second_name_id]; + } + + $national_id = '1199270' . $faker->numberBetween(100000000, 199999999); + $phone_number = '0' . $faker->numberBetween(700000000, 799999999); + $photo = hedley_migrate_allocate_photo_for_person($gender, $birth_date); + } + else { + $first_name = trim($wrapper->field_first_name->value()); + $second_name = trim($wrapper->field_second_name->value()); + if (empty($first_name) && empty($second_name)) { + $second_name = $wrapper->label(); + } + + $national_id = $wrapper->field_national_id_number->value(); + $phone_number = $wrapper->field_phone_number->value(); + $image = $wrapper->field_photo->value(); + $photo = empty($image) ? '' : hedley_migrate_export_real_image($image['fid'], $image['filename']); + } + + $people[$person_id] = [ + $person_id, + "$second_name $first_name", + $first_name, + $second_name, + $gender, + hedley_migrate_export_date_field($birth_date), + $wrapper->field_health_center->getIdentifier(), + $wrapper->field_birth_date_estimated->value(), + $wrapper->field_hmis_number->value(), + $wrapper->field_marital_status->value(), + $wrapper->field_education_level->value(), + $wrapper->field_ubudehe->value(), + $wrapper->field_province->value(), + $wrapper->field_district->value(), + $wrapper->field_sector->value(), + $wrapper->field_cell->value(), + $wrapper->field_village->value(), + $wrapper->field_hiv_status->value(), + $wrapper->field_mode_of_delivery->value(), + $wrapper->field_number_of_children->value(), + $photo, + $national_id, + $phone_number, + $wrapper->created->raw(), + ]; + } + + $relationships_ids = hedley_migrate_resolve_for_export('relationship', 'field_person', $unique_mothers_ids); + foreach ($relationships_ids as $relationship_id) { + $wrapper = entity_metadata_wrapper('node', $relationship_id); + + $relationships[$relationship_id] = [ + $relationship_id, + $wrapper->field_person->getIdentifier(), + $wrapper->field_related_by->value(), + $wrapper->field_related_to->getIdentifier(), + $wrapper->created->raw(), + ]; + } + + foreach ($group_measurements as $type => $values) { + $ids = hedley_migrate_resolve_for_export($type, 'field_session', $group_encounters_ids); + + foreach ($ids as $id) { + $wrapper = entity_metadata_wrapper('node', $id); + $common_values = [ + $wrapper->getIdentifier(), + $wrapper->field_person->getIdentifier(), + hedley_migrate_export_date_field($wrapper->field_date_measured->value()), + $wrapper->field_nurse->getIdentifier(), + $wrapper->created->raw(), + $wrapper->field_session->getIdentifier(), + ]; + + switch ($type) { + case 'attendance': + $type_based_values = [$wrapper->field_attended->value()]; + break; + + case 'child_fbf': + case 'mother_fbf': + $type_based_values = [ + $wrapper->field_distributed_amount->value(), + $wrapper->field_distribution_notice->value(), + ]; + break; + + case 'family_planning': + $type_based_values = [ + implode('|', $wrapper->field_family_planning_signs->value()), + ]; + break; + + case 'height': + $type_based_values = [ + $wrapper->field_height->value(), + $wrapper->field_zscore_age->value(), + ]; + break; + + case 'lactation': + $type_based_values = [ + implode('|', $wrapper->field_lactation_signs->value()), + ]; + break; + + case 'muac': + $type_based_values = [$wrapper->field_muac->value()]; + break; + + case 'nutrition': + $type_based_values = [ + implode('|', $wrapper->field_nutrition_signs->value()), + ]; + break; + + case 'photo': + if ($health_centers_data[$health_center_id]['anonymize']) { + $gender = $wrapper->field_person->field_gender->value(); + $birth_date = $wrapper->field_person->field_birth_date->value(); + $photo = hedley_migrate_allocate_photo_for_person($gender, $birth_date); + } + else { + $image = $wrapper->field_photo->value(); + $photo = empty($image) ? '' : hedley_migrate_export_real_image($image['fid'], $image['filename']); + } + $type_based_values = [$photo]; + break; + + case 'weight': + $type_based_values = [ + $wrapper->field_weight->value(), + $wrapper->field_bmi->value(), + $wrapper->field_zscore_age->value(), + $wrapper->field_zscore_length->value(), + $wrapper->field_zscore_bmi->value(), + ]; + break; + + default: + $type_based_values = []; + } + + $group_measurements[$type][] = array_merge($common_values, $type_based_values); + } + } + + // Handling individual encounters and measurements. + if (empty($health_center_patients_ids)) { + // There are no patients assigned to health center. + // Skip to next health center. + continue; + } + + $individual_participants_ids = hedley_migrate_resolve_for_export('individual_participant', 'field_person', [$health_center_patients_ids]); + if (empty($individual_participants_ids)) { + // There are no individual participations for patients assigned + // to health center. Skip to next health center. + continue; + } + + // Export individual participants. + foreach ($individual_participants_ids as $individual_participant_id) { + $wrapper = entity_metadata_wrapper('node', $individual_participant_id); + + $individual_participants[$individual_participant_id] = [ + $individual_participant_id, + $wrapper->field_person->getIdentifier(), + hedley_migrate_export_date2_field($wrapper->field_expected->value()), + $wrapper->field_encounter_type->value(), + hedley_migrate_export_date_field($wrapper->field_date_concluded->value()), + $wrapper->field_outcome->value(), + $wrapper->field_outcome_location->value(), + hedley_migrate_export_date_field($wrapper->field_expected_date_concluded->value()), + $wrapper->created->raw(), + ]; + } + + // Export acute illness encounters. + $acute_illness_encounters_ids = hedley_migrate_resolve_for_export('acute_illness_encounter', 'field_individual_participant', [$individual_participants_ids]); + foreach ($acute_illness_encounters_ids as $acute_illness_encounter_id) { + $wrapper = entity_metadata_wrapper('node', $acute_illness_encounter_id); + + $acute_illness_encounters[$acute_illness_encounter_id] = [ + $acute_illness_encounter_id, + $wrapper->field_individual_participant->getIdentifier(), + hedley_migrate_export_date2_field($wrapper->field_scheduled_date->value()), + $wrapper->created->raw(), + $wrapper->field_acute_illness_diagnosis->value(), + ]; + } + + // Export acute illness measurements. + foreach ($acute_illness_measurements as $type => $values) { + $ids = hedley_migrate_resolve_for_export($type, 'field_acute_illness_encounter', $acute_illness_encounters_ids); + + foreach ($ids as $id) { + $wrapper = entity_metadata_wrapper('node', $id); + $common_values = [ + $wrapper->getIdentifier(), + $wrapper->field_person->getIdentifier(), + hedley_migrate_export_date_field($wrapper->field_date_measured->value()), + $wrapper->field_nurse->getIdentifier(), + $wrapper->created->raw(), + $wrapper->field_acute_illness_encounter->getIdentifier(), + ]; + + switch ($type) { + case 'acute_findings': + $type_based_values = [ + implode('|', $wrapper->field_findings_signs_general->value()), + implode('|', $wrapper->field_findings_signs_respiratory->value()), + ]; + break; + + case 'acute_illness_danger_signs': + $type_based_values = [ + implode('|', $wrapper->field_acute_illness_danger_signs->value()), + ]; + break; + + case 'acute_illness_muac': + $type_based_values = [ + $wrapper->field_muac->value(), + ]; + break; + + case 'acute_illness_nutrition': + $type_based_values = [ + implode('|', $wrapper->field_nutrition_signs->value()), + ]; + break; + + case 'acute_illness_vitals': + $type_based_values = [ + $wrapper->field_respiratory_rate->value(), + $wrapper->field_body_temperature->value(), + ]; + break; + + case 'call_114': + $type_based_values = [ + implode('|', $wrapper->field_114_contact->value()), + implode('|', $wrapper->field_114_recommendation->value()), + implode('|', $wrapper->field_site_recommendation->value()), + ]; + break; + + case 'exposure': + $type_based_values = [ + implode('|', $wrapper->field_exposure->value()), + ]; + break; + + case 'hc_contact': + $type_based_values = [ + implode('|', $wrapper->field_hc_contact->value()), + implode('|', $wrapper->field_hc_recommendation->value()), + implode('|', $wrapper->field_hc_response_time->value()), + implode('|', $wrapper->field_ambulance_arrival_time->value()), + ]; + break; + + case 'health_education': + $type_based_values = [ + implode('|', $wrapper->field_health_education_signs->value()), + ]; + break; + + case 'isolation': + $type_based_values = [ + implode('|', $wrapper->field_isolation->value()), + implode('|', $wrapper->field_reason_for_not_isolating->value()), + ]; + break; + + case 'malaria_testing': + $type_based_values = [ + $wrapper->field_malaria_rapid_test->value(), + ]; + break; + + case 'medication_distribution': + $type_based_values = [ + implode('|', $wrapper->field_prescribed_medication->value()), + implode('|', $wrapper->field_non_administration_reason->value()), + ]; + break; + + case 'send_to_hc': + $type_based_values = [ + implode('|', $wrapper->field_send_to_hc->value()), + ]; + break; -$male_first_names = hedley_migrate_male_first_names(); -$female_first_names = hedley_migrate_female_first_names(); -$second_names = hedley_migrate_second_names(); -$total_male_first_names = count($male_first_names); -$total_female_first_names = count($female_first_names); -$total_second_names = count($second_names); -$total_males = 0; -$total_females = 0; - -$catchment_area_ids = []; -foreach ($health_centers_ids as $health_center_id) { - $node = node_load($health_center_id); - - if (!$node) { - drush_print("Error: can't find health center with ID $health_center_id!"); - exit; - } - - $wrapper = entity_metadata_wrapper('node', $node); - - $catchment_area_id = $wrapper->field_catchment_area->getIdentifier(); - - $health_centers[] = [ - $wrapper->getIdentifier(), - str_replace(',', ' ', $wrapper->label()), - $catchment_area_id, - $node->created, - ]; - - if (!in_array($catchment_area_id, $catchment_area_ids)) { - $wrapper = entity_metadata_wrapper('node', $catchment_area_id); - $catchment_areas[] = [ - $wrapper->getIdentifier(), - str_replace(',', ' ', $wrapper->label()), - $wrapper->created->raw(), - ]; - $catchment_area_ids[] = $catchment_area_id; - } - - $villages_ids = hedley_migrate_resolve_for_export('village', 'field_health_center', [$health_center_id]); - foreach ($villages_ids as $village_id) { - $wrapper = entity_metadata_wrapper('node', $village_id); - $villages[] = [ - $wrapper->getIdentifier(), - $wrapper->field_province->value(), - $wrapper->field_district->value(), - $wrapper->field_sector->value(), - $wrapper->field_cell->value(), - $wrapper->field_village->value(), - $wrapper->field_health_center->getIdentifier(), - $wrapper->created->raw(), - ]; - } - - $groups_ids = hedley_migrate_resolve_for_export('clinic', 'field_health_center', [$health_center_id]); - foreach ($groups_ids as $index => $group_id) { - $wrapper = entity_metadata_wrapper('node', $group_id); - $group_type = $wrapper->field_group_type->value(); - - if ($group_type == 'chw') { - // Chw groups automatically created during villages migration. - // Therefore, we skip them here. - unset($groups_ids[$index]); - continue; - } - - $groups[] = [ - $wrapper->getIdentifier(), - str_replace(',', ' ', $wrapper->label()), - $group_type, - $wrapper->field_health_center->getIdentifier(), - $wrapper->created->raw(), - ]; - } - $groups_ids = array_values($groups_ids); + case 'symptoms_general': + $type_based_values = [ + $wrapper->field_fever_period->value(), + $wrapper->field_chills_period->value(), + $wrapper->field_night_sweats_period->value(), + $wrapper->field_body_aches_period->value(), + $wrapper->field_headache_period->value(), + $wrapper->field_lethargy_period->value(), + $wrapper->field_poor_suck_period->value(), + $wrapper->field_unable_to_drink_period->value(), + $wrapper->field_unable_to_eat_period->value(), + $wrapper->field_increased_thirst_period->value(), + $wrapper->field_dry_mouth_period->value(), + $wrapper->field_severe_weakness_period->value(), + $wrapper->field_yellow_eyes_period->value(), + $wrapper->field_coke_colored_urine_period->value(), + $wrapper->field_convulsions_period->value(), + $wrapper->field_spontaneos_bleeding_period->value(), + ]; + break; - $nurses_ids = hedley_migrate_resolve_for_export('nurse', 'field_health_centers', [$health_center_id]); - foreach ($nurses_ids as $nurse_id) { - $wrapper = entity_metadata_wrapper('node', $nurse_id); + case 'symptoms_gi': + $type_based_values = [ + $wrapper->field_bloody_diarrhea_period->value(), + $wrapper->field_non_bloody_diarrhea_period->value(), + $wrapper->field_nausea_period->value(), + $wrapper->field_vomiting_period->value(), + $wrapper->field_abdominal_pain_period->value(), + implode('|', $wrapper->field_symptoms_gi_derived_signs->value()), + ]; + break; - $hc_ids = $wrapper->field_health_centers->value(['identifier' => TRUE]); - foreach ($hc_ids as $key => $hc_id) { - if (!in_array($hc_id, $health_centers_ids)) { - unset($hc_ids[$key]); - } - } + case 'symptoms_respiratory': + $type_based_values = [ + $wrapper->field_cough_period->value(), + $wrapper->field_shortness_of_breath_period->value(), + $wrapper->field_nasal_congestion_period->value(), + $wrapper->field_blood_in_sputum_period->value(), + $wrapper->field_sore_throat_period->value(), + $wrapper->field_loss_of_smell_period->value(), + $wrapper->field_stabbing_chest_pain_period->value(), + ]; + break; - $villages_ids = $wrapper->field_villages->value(['identifier' => TRUE]); - foreach ($villages_ids as $key => $village_id) { - $village_wrapper = entity_metadata_wrapper('node', $village_id); - $hc_id = $village_wrapper->field_health_center->getIdentifier(); + case 'travel_history': + $type_based_values = [ + implode('|', $wrapper->field_travel_history->value()), + ]; + break; - if (!in_array($hc_id, $health_centers_ids)) { - unset($villages_ids[$key]); + case 'treatment_history': + $type_based_values = [ + implode('|', $wrapper->field_treatment_history->value()), + ]; + break; + + case 'treatment_ongoing': + $type_based_values = [ + implode('|', $wrapper->field_treatment_ongoing->value()), + $wrapper->field_reason_for_not_taking->value(), + $wrapper->field_missed_doses->value(), + implode('|', $wrapper->field_adverse_events->value()), + ]; + break; + + default: + $type_based_values = []; } - } - $nurses[$nurse_id] = [ - $nurse_id, - str_replace(',', ' ', $wrapper->label()), - implode('|', $wrapper->field_role->value()), - implode('|', array_values($hc_ids)), - implode('|', array_values($villages_ids)), - $wrapper->field_pin_code->value(), - $wrapper->created->raw(), - ]; + $acute_illness_measurements[$type][] = array_merge($common_values, $type_based_values); + } } - $group_encounters_ids = hedley_migrate_resolve_for_export('session', 'field_clinic', $groups_ids); - foreach ($group_encounters_ids as $group_encounter_id) { - $wrapper = entity_metadata_wrapper('node', $group_encounter_id); - $group_encounters[] = [ - $wrapper->getIdentifier(), - $wrapper->field_clinic->getIdentifier(), - hedley_migrate_export_date_field($wrapper->field_scheduled_date->value(), TRUE), + // Export nutrition encounters. + $nutrition_encounters_ids = hedley_migrate_resolve_for_export('nutrition_encounter', 'field_individual_participant', [$individual_participants_ids]); + foreach ($nutrition_encounters_ids as $nutrition_encounter_id) { + $wrapper = entity_metadata_wrapper('node', $nutrition_encounter_id); + + $nutrition_encounters[$nutrition_encounter_id] = [ + $nutrition_encounter_id, + $wrapper->field_individual_participant->getIdentifier(), + hedley_migrate_export_date2_field($wrapper->field_scheduled_date->value()), $wrapper->created->raw(), ]; } - $participants_ids = hedley_migrate_resolve_for_export('pmtct_participant', 'field_clinic', $groups_ids); - $mothers_ids = $children_ids = []; - foreach ($participants_ids as $participant_id) { - $wrapper = entity_metadata_wrapper('node', $participant_id); - $mothers_ids[] = $wrapper->field_adult->getIdentifier(); - $children_ids[] = $wrapper->field_person->getIdentifier(); + // Export nutrition measurements. + foreach ($nutrition_measurements as $type => $values) { + $ids = hedley_migrate_resolve_for_export($type, 'field_nutrition_encounter', $nutrition_encounters_ids); - $participants[] = [ - $wrapper->getIdentifier(), - $wrapper->field_person->getIdentifier(), - $wrapper->field_adult->getIdentifier(), - $wrapper->field_adult_activities->value(), - hedley_migrate_export_date_field($wrapper->field_expected->value()), - $wrapper->field_clinic->getIdentifier(), - $wrapper->created->raw(), - ]; - } + foreach ($ids as $id) { + $wrapper = entity_metadata_wrapper('node', $id); + $common_values = [ + $wrapper->getIdentifier(), + $wrapper->field_person->getIdentifier(), + hedley_migrate_export_date_field($wrapper->field_date_measured->value()), + $wrapper->field_nurse->getIdentifier(), + $wrapper->created->raw(), + $wrapper->field_nutrition_encounter->getIdentifier(), + ]; - $unique_mothers_ids = array_unique($mothers_ids); - $people_ids = array_merge($unique_mothers_ids, array_unique($children_ids)); - foreach ($people_ids as $person_id) { - $wrapper = entity_metadata_wrapper('node', $person_id); - $gender = $wrapper->field_gender->value(); - $birth_date = $wrapper->field_birth_date->value(); + switch ($type) { + case 'nutrition_height': + $type_based_values = [ + $wrapper->field_height->value(), + $wrapper->field_zscore_age->value(), + ]; + break; - if ($health_centers_data[$health_center_id]['anonymize']) { - if ($gender == 'male') { - $total_males++; - $first_name_id = ($total_males - 1) % $total_male_first_names; - $second_name_id = (($total_males - 1) / $total_male_first_names) % $total_second_names; - $first_name = $male_first_names[$first_name_id]; - $second_name = $second_names[$second_name_id]; - } - else { - $total_females++; - $first_name_id = ($total_females - 1) % $total_female_first_names; - $second_name_id = (($total_females - 1) / $total_female_first_names) % $total_second_names; - $first_name = $female_first_names[$first_name_id]; - $second_name = $second_names[$second_name_id]; - } + case 'nutrition_muac': + $type_based_values = [ + $wrapper->field_muac->value(), + ]; + break; - $national_id = '1199270' . $faker->numberBetween(100000000, 199999999); - $phone_number = '0' . $faker->numberBetween(700000000, 799999999); - $photo = hedley_migrate_allocate_photo_for_person($gender, $birth_date); - } - else { - $first_name = trim($wrapper->field_first_name->value()); - $second_name = trim($wrapper->field_second_name->value()); - if (empty($first_name) && empty($second_name)) { - $second_name = $wrapper->label(); + case 'nutrition_nutrition': + $type_based_values = [ + implode('|', $wrapper->field_nutrition_signs->value()), + ]; + break; + + case 'nutrition_photo': + if ($health_centers_data[$health_center_id]['anonymize']) { + $gender = $wrapper->field_person->field_gender->value(); + $birth_date = $wrapper->field_person->field_birth_date->value(); + $photo = hedley_migrate_allocate_photo_for_person($gender, $birth_date); + } + else { + $image = $wrapper->field_photo->value(); + $photo = empty($image) ? '' : hedley_migrate_export_real_image($image['fid'], $image['filename']); + } + $type_based_values = [$photo]; + break; + + case 'nutrition_weight': + $type_based_values = [ + $wrapper->field_weight->value(), + $wrapper->field_bmi->value(), + $wrapper->field_zscore_age->value(), + $wrapper->field_zscore_length->value(), + $wrapper->field_zscore_bmi->value(), + ]; + break; + + default: + $type_based_values = []; } - $national_id = $wrapper->field_national_id_number->value(); - $phone_number = $wrapper->field_phone_number->value(); - $image = $wrapper->field_photo->value(); - $photo = empty($image) ? '' : hedley_migrate_export_real_image($image['fid'], $image['filename']); + $nutrition_measurements[$type][] = array_merge($common_values, $type_based_values); } - - $people[$person_id] = [ - $person_id, - "$second_name $first_name", - $first_name, - $second_name, - $gender, - date('Y-m-d', $birth_date), - $wrapper->field_health_center->getIdentifier(), - $wrapper->field_birth_date_estimated->value(), - $wrapper->field_hmis_number->value(), - $wrapper->field_marital_status->value(), - $wrapper->field_education_level->value(), - $wrapper->field_ubudehe->value(), - $wrapper->field_province->value(), - $wrapper->field_district->value(), - $wrapper->field_sector->value(), - $wrapper->field_cell->value(), - $wrapper->field_village->value(), - $wrapper->field_hiv_status->value(), - $wrapper->field_mode_of_delivery->value(), - $wrapper->field_number_of_children->value(), - $photo, - $national_id, - $phone_number, - $wrapper->created->raw(), - ]; } - $relationships_ids = hedley_migrate_resolve_for_export('relationship', 'field_person', $unique_mothers_ids); - foreach ($relationships_ids as $relationship_id) { - $wrapper = entity_metadata_wrapper('node', $relationship_id); + // Export prenatal encounters. + $prenatal_encounters_ids = hedley_migrate_resolve_for_export('prenatal_encounter', 'field_individual_participant', [$individual_participants_ids]); + foreach ($prenatal_encounters_ids as $prenatal_encounter_id) { + $wrapper = entity_metadata_wrapper('node', $prenatal_encounter_id); - $relationships[$relationship_id] = [ - $relationship_id, - $wrapper->field_person->getIdentifier(), - $wrapper->field_related_by->value(), - $wrapper->field_related_to->getIdentifier(), + $prenatal_encounters[$prenatal_encounter_id] = [ + $prenatal_encounter_id, + $wrapper->field_individual_participant->getIdentifier(), + hedley_migrate_export_date2_field($wrapper->field_scheduled_date->value()), $wrapper->created->raw(), ]; } - foreach ($measurements as $type => $values) { - $ids = hedley_migrate_resolve_for_export($type, 'field_session', $group_encounters_ids); + // Export prenatal measurements. + foreach ($prenatal_measurements as $type => $values) { + $ids = hedley_migrate_resolve_for_export($type, 'field_prenatal_encounter', $prenatal_encounters_ids); foreach ($ids as $id) { $wrapper = entity_metadata_wrapper('node', $id); $common_values = [ $wrapper->getIdentifier(), $wrapper->field_person->getIdentifier(), - date('Y-m-d', $wrapper->field_date_measured->value()), + hedley_migrate_export_date_field($wrapper->field_date_measured->value()), $wrapper->field_nurse->getIdentifier(), - $wrapper->field_session->getIdentifier(), $wrapper->created->raw(), + $wrapper->field_prenatal_encounter->getIdentifier(), ]; switch ($type) { - case 'attendance': - $type_based_values = [$wrapper->field_attended->value()]; + case 'breast_exam': + $type_based_values = [ + implode('|', $wrapper->field_breast->value()), + $wrapper->field_breast_self_exam->value(), + ]; break; - case 'family_planning': + case 'core_physical_exam': $type_based_values = [ - implode('|', $wrapper->field_family_planning_signs->value()), + implode('|', $wrapper->field_head_hair->value()), + implode('|', $wrapper->field_eyes->value()), + implode('|', $wrapper->field_neck->value()), + implode('|', $wrapper->field_heart->value()), + $wrapper->field_heart_murmur->value(), + implode('|', $wrapper->field_lungs->value()), + implode('|', $wrapper->field_abdomen->value()), + implode('|', $wrapper->field_hands->value()), + implode('|', $wrapper->field_legs->value()), ]; break; - case 'height': + case 'danger_signs': $type_based_values = [ - $wrapper->field_height->value(), - $wrapper->field_zscore_age->value(), + implode('|', $wrapper->field_danger_signs->value()), ]; break; - case 'weight': + case 'last_menstrual_period': $type_based_values = [ - $wrapper->field_weight->value(), - $wrapper->field_bmi->value(), - $wrapper->field_zscore_age->value(), - $wrapper->field_zscore_length->value(), - $wrapper->field_zscore_bmi->value(), + hedley_migrate_export_date_field($wrapper->field_last_menstrual_period->value()), + $wrapper->field_confident->value(), ]; break; - case 'muac': - $type_based_values = [$wrapper->field_muac->value()]; + case 'medical_history': + $type_based_values = [ + implode('|', $wrapper->field_medical_history->value()), + ]; break; - case 'nutrition': + case 'medication': $type_based_values = [ - implode('|', $wrapper->field_nutrition_signs->value()), + implode('|', $wrapper->field_medication->value()), ]; break; - case 'photo': + case 'obstetrical_exam': + $type_based_values = [ + $wrapper->field_fundal_height->value(), + $wrapper->field_fetal_presentation->value(), + $wrapper->field_fetal_movement->value(), + $wrapper->field_fetal_heart_rate->value(), + $wrapper->field_c_section_scar->value(), + ]; + break; + + case 'obstetric_history': + $type_based_values = [ + $wrapper->field_currently_pregnant->value(), + $wrapper->field_term_pregnancy->value(), + $wrapper->field_preterm_pregnancy->value(), + $wrapper->field_stillbirths_at_term->value(), + $wrapper->field_stillbirths_preterm->value(), + $wrapper->field_abortions->value(), + $wrapper->field_live_children->value(), + ]; + break; + + case 'obstetric_history_step2': + $type_based_values = [ + $wrapper->field_c_sections->value(), + implode('|', $wrapper->field_c_section_reason->value()), + implode('|', $wrapper->field_previous_delivery_period->value()), + implode('|', $wrapper->field_obstetric_history->value()), + implode('|', $wrapper->field_previous_delivery->value()), + ]; + break; + + case 'prenatal_family_planning': + $type_based_values = [ + implode('|', $wrapper->field_family_planning_signs->value()), + ]; + break; + + case 'prenatal_nutrition': + $type_based_values = [ + $wrapper->field_height->value(), + $wrapper->field_height->value(), + $wrapper->field_height->value(), + ]; + break; + + case 'prenatal_photo': if ($health_centers_data[$health_center_id]['anonymize']) { $gender = $wrapper->field_person->field_gender->value(); $birth_date = $wrapper->field_person->field_birth_date->value(); @@ -463,11 +1414,34 @@ $type_based_values = [$photo]; break; + case 'resource': + $type_based_values = [ + implode('|', $wrapper->field_resources->value()), + ]; + break; + + case 'social_history': + $type_based_values = [ + implode('|', $wrapper->field_social_history->value()), + $wrapper->field_partner_hiv_testing->value(), + ]; + break; + + case 'vitals': + $type_based_values = [ + $wrapper->field_sys->value(), + $wrapper->field_dia->value(), + $wrapper->field_heart_rate->value(), + $wrapper->field_respiratory_rate->value(), + $wrapper->field_body_temperature->value(), + ]; + break; + default: $type_based_values = []; } - $measurements[$type][] = array_merge($common_values, $type_based_values); + $prenatal_measurements[$type][] = array_merge($common_values, $type_based_values); } } } @@ -482,15 +1456,26 @@ 'pmtct_participant' => $participants, 'person' => array_values($people), 'relationship' => array_values($relationships), - 'attendance' => $measurements['attendance'], - 'family_planning' => $measurements['family_planning'], - 'height' => $measurements['height'], - 'weight' => $measurements['weight'], - 'muac' => $measurements['muac'], - 'nutrition' => $measurements['nutrition'], - 'photo' => $measurements['photo'], + 'individual_participant' => array_values($individual_participants), + 'acute_illness_encounter' => array_values($acute_illness_encounters), + 'nutrition_encounter' => array_values($nutrition_encounters), + 'prenatal_encounter' => array_values($prenatal_encounters), ]; +// Measurements mapping. +foreach (array_keys($group_measurements) as $type) { + $mapping[$type] = $group_measurements[$type]; +} +foreach (array_keys($acute_illness_measurements) as $type) { + $mapping[$type] = $acute_illness_measurements[$type]; +} +foreach (array_keys($nutrition_measurements) as $type) { + $mapping[$type] = $nutrition_measurements[$type]; +} +foreach (array_keys($prenatal_measurements) as $type) { + $mapping[$type] = $prenatal_measurements[$type]; +} + foreach ($mapping as $name => $rows) { $content = []; foreach ($rows as $row) { diff --git a/server/hedley/modules/custom/hedley_patient/hedley_patient.drush.inc b/server/hedley/modules/custom/hedley_patient/hedley_patient.drush.inc index 5b82de03eb..48e2ec6b9c 100644 --- a/server/hedley/modules/custom/hedley_patient/hedley_patient.drush.inc +++ b/server/hedley/modules/custom/hedley_patient/hedley_patient.drush.inc @@ -45,7 +45,7 @@ function hedley_patient_patient_measurements_report() { $wrapper = entity_metadata_wrapper('node', $patient); if ($wrapper->getBundle() !== 'person') { - drush_print('Error! Patient node type is not of a person. Please fix and try again.'); + drush_print('ERROR! Patient node type is not of a person. Please fix and try again.'); return; } @@ -61,47 +61,72 @@ function hedley_patient_patient_measurements_report() { $group_measurements, $antenatal_measurements, $nutrition_measurements, - $acute_illness_measurements - ) = hedley_patient_group_measurements_by_encounter_type($measurements); + $acute_illness_measurements, + $home_visit_measurements, + $well_child_measurements + ) = _group_measurements_by_encounter_type($measurements); $count = count($group_measurements); - drush_print("Duplicate got $count Group measurements."); + drush_print("Patient got $count Group measurements."); $count = count($antenatal_measurements); - drush_print("Duplicate got $count Antenatal measurements."); + drush_print("Patient got $count Antenatal measurements."); $count = count($nutrition_measurements); - drush_print("Duplicate got $count Nutrition measurements."); + drush_print("Patient got $count Nutrition measurements."); $count = count($acute_illness_measurements); - drush_print("Duplicate got $count Acute Illness measurements."); + drush_print("Patient got $count Acute Illness measurements."); + $count = count($home_visit_measurements); + drush_print("Patient got $count Home Visit measurements."); + $count = count($well_child_measurements); + drush_print("Patient got $count Well Child measurements."); } /** * Command callback for 'drush consolidate-patients'. * - * Relocates content form the 'duplicate' patient to the 'original' patient. - * Once completed, marks 'duplicate' patient as deleted. + * Validates, then executes consolidation process. * * @throws \EntityMetadataWrapperException */ function hedley_patient_consolidate_patients() { + drush_print('Running validations ...'); + drush_print(''); + $success = _consolidate_patients_validate(); + if ($success) { + drush_print('Executing consolidation ...'); + drush_print(''); + + _consolidate_patients_execute(); + } +} + +/** + * Runs validations before executing consolidation process. + * + * @return bool + * True, if all validations passed. + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_patients_validate() { $original = drush_get_option('original'); $duplicate = drush_get_option('duplicate'); if (empty($original) || empty($duplicate)) { - drush_print('You have to specify both --original and --duplicate parameter.'); - return; + drush_print('ERROR! You have to specify both --original and --duplicate parameter.'); + return FALSE; } $wrapper_original = entity_metadata_wrapper('node', $original); $wrapper_duplicate = entity_metadata_wrapper('node', $duplicate); if ($wrapper_original->getBundle() !== 'person') { - drush_print('Error! Original patient node type is not of a person. Please fix and try again.'); - return; + drush_print('ERROR! Original patient node type is not of a person. Please fix and try again.'); + return FALSE; } if ($wrapper_duplicate->getBundle() !== 'person') { - drush_print('Error! Duplicate patient node type is not of a person. Please fix and try again.'); - return; + drush_print('ERROR! Duplicate patient node type is not of a person. Please fix and try again.'); + return FALSE; } $health_center_original = $wrapper_original->field_health_center->getIdentifier(); @@ -109,46 +134,111 @@ function hedley_patient_consolidate_patients() { // Do not allow consolidation, if patients are assigned to // different health centers. if ($health_center_original !== $health_center_duplicate) { - drush_print('Error! Patients do not belong to same Health Center.'); + drush_print('ERROR! Patients do not belong to same Health Center.'); + return FALSE; } // Get all measurements that belong to duplicate patient. $measurements_of_duplicate = hedley_general_get_person_measurements($duplicate); - // If no measurements found, mark duplicate patient as 'Deleted'. - if (count($measurements_of_duplicate) == 0) { - drush_print('Duplicate patient got no measurements. Marking it as deleted.'); - $wrapper_duplicate->field_deleted->set(TRUE); - $wrapper_duplicate->save(); - return; - } list( $group_measurements, $antenatal_measurements, $nutrition_measurements, - $acute_illness_measurements - ) = hedley_patient_group_measurements_by_encounter_type($measurements_of_duplicate); + $acute_illness_measurements, + $home_visit_measurements, + $well_child_measurements + ) = _group_measurements_by_encounter_type($measurements_of_duplicate); - // Consolidate group measurements. - $success = hedley_patient_consolidate_group_content($group_measurements, $original); + // Validation before consolidating group encounters content. + $success = _consolidate_group_content_validate($group_measurements, $original); // If consolidation failed, we make no changes, so that a fix could be // applied, and command could be executed again. if (!$success) { - return; + return FALSE; } - // Consolidate group measurements. - hedley_patient_consolidate_antenatal_content($antenatal_measurements, $original, $duplicate); - hedley_patient_consolidate_nutrition_content($nutrition_measurements, $original, $duplicate); - hedley_patient_consolidate_acute_illness_content($acute_illness_measurements, $original, $duplicate); + // Validation before consolidating Nutrition encounters content. + $success = _consolidate_nutrition_content_validate($nutrition_measurements, $original, $duplicate); + if (!$success) { + return FALSE; + } + + // Validation before consolidating Home Visit encounters content. + $success = _consolidate_home_visit_content_validate($home_visit_measurements, $original, $duplicate); + if (!$success) { + return FALSE; + } + // Validation before consolidating Well Child encounters content. + $success = _consolidate_well_child_content_validate($well_child_measurements, $original, $duplicate); + if (!$success) { + return FALSE; + } + + // Validation before consolidating Antenatal encounters content. + $success = _consolidate_antenatal_content_validate($antenatal_measurements, $original, $duplicate); + if (!$success) { + return FALSE; + } + + // Validation before consolidating Acute Illness encounters content. + $success = _consolidate_acute_illness_content_validate($acute_illness_measurements, $original, $duplicate); + if (!$success) { + return FALSE; + } + + drush_print(''); + drush_print('SUCCESS! All validations passed!'); + drush_print(''); + + return TRUE; +} + +/** + * Executes consolidation process. + * + * All content is relocated from 'duplicate' patient to 'original' patient. + * Once completed, marks 'duplicate' patient as deleted. + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_patients_execute() { + $original = drush_get_option('original'); + $duplicate = drush_get_option('duplicate'); + + $wrapper_duplicate = entity_metadata_wrapper('node', $duplicate); + + // Get all measurements that belong to duplicate patient. + $measurements_of_duplicate = hedley_general_get_person_measurements($duplicate); + + list( + $group_measurements, + $antenatal_measurements, + $nutrition_measurements, + $acute_illness_measurements, + $home_visit_measurements, + $well_child_measurements + ) = _group_measurements_by_encounter_type($measurements_of_duplicate); + + // Execute consolidations. + _consolidate_group_content_execute($group_measurements, $original); + _consolidate_nutrition_content_execute($nutrition_measurements, $original, $duplicate); + _consolidate_home_visit_content_execute($home_visit_measurements, $original, $duplicate); + _consolidate_well_child_content_execute($well_child_measurements, $original, $duplicate); + _consolidate_antenatal_content_execute($antenatal_measurements, $original, $duplicate); + _consolidate_acute_illness_content_execute($acute_illness_measurements, $original, $duplicate); // Mark duplicate patient as Deleted. $wrapper_duplicate->field_deleted->set(TRUE); $wrapper_duplicate->save(); + + drush_print(''); + drush_print('SUCCESS! All consolidations completed!'); + drush_print(''); } /** - * Performs consolidation of group encounters content. + * Performs validations before consolidation of group encounters content. * * @param array $measurements * A list of group measurements that belong to the 'duplicate' patient. @@ -157,10 +247,8 @@ function hedley_patient_consolidate_patients() { * * @return bool * True, if consolidation was successful. - * - * @throws \EntityMetadataWrapperException */ -function hedley_patient_consolidate_group_content(array $measurements, $original) { +function _consolidate_group_content_validate(array $measurements, $original) { $count = count($measurements); drush_print("Duplicate got $count group measurements."); @@ -199,15 +287,58 @@ function hedley_patient_consolidate_group_content(array $measurements, $original // to which measurements of the duplicate belong. foreach ($clinics_duplicate as $clinic) { if (!in_array($clinic, $clinics_original)) { - drush_print("Error! Original is not participating in clinic $clinic. Please fix and try again."); + drush_print("ERROR! Original is not participating in clinic $clinic. Please fix and try again."); return FALSE; } } - // If we got this far, it's safe to transfer the measurements. - hedley_patient_associate_content_by_field($measurements, 'field_person', $original); + return TRUE; +} + +/** + * Performs consolidation of group encounters content. + * + * @param array $measurements + * A list of group measurements that belong to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_group_content_execute(array $measurements, $original) { + _associate_content_by_field($measurements, 'field_person', $original); + + drush_print("Consolidation of Group encounters content is completed."); + drush_print(''); +} + +/** + * Performs validations before consolidation of Prenatal encounters content. + * + * For now, it only prints some data. No failure option. + * + * @param array $measurements + * A list of Nutrition measurements that belong to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * + * @return bool + * True, if validation was successful. + */ +function _consolidate_antenatal_content_validate(array $measurements, $original, $duplicate) { + $count = count($measurements); + drush_print("Duplicate got $count Prenatal measurements."); + + $participants_original = hedley_person_individual_participants_for_person($original, 'antenatal', 'DESC'); + $count = count($participants_original); + drush_print("Original got $count Prenatal Participants."); + + $participants_duplicate = hedley_person_individual_participants_for_person($duplicate, 'antenatal', 'DESC'); + $count = count($participants_duplicate); + drush_print("Duplicate got $count Prenatal Participants."); - // Report success. return TRUE; } @@ -230,7 +361,7 @@ function hedley_patient_consolidate_group_content(array $measurements, $original * - If not, associated fully (same as step 1). * * @param array $measurements - * A list of group measurements that belong to the 'duplicate' patient. + * A list of group measurements belonging to the 'duplicate' patient. * @param int $original * Node ID of the 'original' patient. * @param int $duplicate @@ -238,17 +369,9 @@ function hedley_patient_consolidate_group_content(array $measurements, $original * * @throws \EntityMetadataWrapperException */ -function hedley_patient_consolidate_antenatal_content(array $measurements, $original, $duplicate) { - $count = count($measurements); - drush_print("Duplicate got $count Antenatal measurements."); - +function _consolidate_antenatal_content_execute(array $measurements, $original, $duplicate) { $participants_original = hedley_person_individual_participants_for_person($original, 'antenatal', 'DESC'); - $count = count($participants_original); - drush_print("Original got $count Participants."); - $participants_duplicate = hedley_person_individual_participants_for_person($duplicate, 'antenatal', 'DESC'); - $count = count($participants_duplicate); - drush_print("Duplicate got $count Participants."); // Search for ongoing participant (pregnancy) of original patient. // If found, record it's ID. @@ -266,15 +389,14 @@ function hedley_patient_consolidate_antenatal_content(array $measurements, $orig // If original patient does not have an ongoing pregnancy, associate // participants and measurements of duplicate with the original patient. if (!$participant_original_ongoing) { - drush_print('Original ongoing Participant NOT FOUND.'); + _associate_content_by_field($participants_duplicate, 'field_person', $original); + _associate_content_by_field($measurements, 'field_person', $original); - hedley_patient_associate_content_by_field($participants_duplicate, 'field_person', $original); - hedley_patient_associate_content_by_field($measurements, 'field_person', $original); + drush_print("Consolidation of Prenatal encounters content is completed."); + drush_print(''); return; } - drush_print("Original ongoing Participant: $participant_original_ongoing."); - // If we got here, we know that original patient has an ongoing pregnancy. // We search for ongoing pregnancy of duplicate patient. // If it exists, we want to associate all it's encounters with ongoing @@ -296,85 +418,256 @@ function hedley_patient_consolidate_antenatal_content(array $measurements, $orig // encounters with ongoing pregnancy of original patient. // Afterwards, mark ongoing pregnancy of duplicate as deleted. if ($participant_duplicate_ongoing) { - drush_print("Duplicate ongoing Participant: $participant_duplicate_ongoing."); - $encounters = hedley_person_encounters_for_individual_participant($participant_duplicate_ongoing); - hedley_patient_associate_content_by_field($encounters, 'field_individual_participant', $participant_original_ongoing); + _associate_content_by_field($encounters, 'field_individual_participant', $participant_original_ongoing); $wrapper_participant = entity_metadata_wrapper('node', $participant_duplicate_ongoing); $wrapper_participant->field_deleted->set(TRUE); $wrapper_participant->save(); } - else { - drush_print('Duplicate ongoing Participant NOT FOUND.'); - } // Associate remaining participants and measurements of duplicate, // with the original patient. - hedley_patient_associate_content_by_field($participants_duplicate, 'field_person', $original); - hedley_patient_associate_content_by_field($measurements, 'field_person', $original); + _associate_content_by_field($participants_duplicate, 'field_person', $original); + _associate_content_by_field($measurements, 'field_person', $original); + + drush_print("Consolidation of Prenatal encounters content is completed."); + drush_print(''); +} + +/** + * Performs validations before consolidation of Nutrition encounters content. + * + * @param array $measurements + * A list of Nutrition measurements that belong to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * + * @see: _consolidate_nutritionlike_content_validate() + * + * @return bool + * True, if validation was successful. + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_nutrition_content_validate(array $measurements, $original, $duplicate) { + return _consolidate_nutritionlike_content_validate($measurements, $original, $duplicate, 'nutrition'); } /** * Performs consolidation of Nutrition encounters content. * + * @param array $measurements + * A list of Nutrition measurements that belong to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * + * @see: _consolidate_nutritionlike_content_execute() + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_nutrition_content_execute(array $measurements, $original, $duplicate) { + _consolidate_nutritionlike_content_execute($measurements, $original, $duplicate, 'nutrition'); +} + +/** + * Performs validation before consolidation of Home Visit encounters content. + * + * @param array $measurements + * A list of Home Visit measurements belonging to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * + * @see: _consolidate_nutritionlike_content_validate() + * + * @return bool + * True, if validation was successful. + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_home_visit_content_validate(array $measurements, $original, $duplicate) { + return _consolidate_nutritionlike_content_validate($measurements, $original, $duplicate, 'home-visit'); +} + +/** + * Performs consolidation of Home Visit encounters content. + * + * @param array $measurements + * A list of Home Visit measurements belonging to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * + * @see: _consolidate_nutritionlike_content_execute() + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_home_visit_content_execute(array $measurements, $original, $duplicate) { + _consolidate_nutritionlike_content_execute($measurements, $original, $duplicate, 'home-visit'); +} + +/** + * Performs validations before consolidation of Well Child encounters content. + * + * @param array $measurements + * A list of Well Child measurements belonging to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * + * @see: _consolidate_nutritionlike_content_validate() + * + * @return bool + * True, if validation was successful. + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_well_child_content_validate(array $measurements, $original, $duplicate) { + return _consolidate_nutritionlike_content_validate($measurements, $original, $duplicate, 'well-child'); +} + +/** + * Performs consolidation of Well Child encounters content. + * + * @param array $measurements + * A list of Well Child measurements belonging to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * + * @see: _consolidate_nutritionlike_content_execute() + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_well_child_content_execute(array $measurements, $original, $duplicate) { + _consolidate_nutritionlike_content_execute($measurements, $original, $duplicate, 'well-child'); +} + +/** + * Performs validations before consolidation for Nutrition like use case. + * * This is a case where we have single participant, with multiple encounters. - * So, in case original got a participant, we transfer all associate encounters - * of duplicate with that participant. If not, we associate the participant - * as well. * - * In both cases, we associate all measurements of duplicate with the original. + * + * Original patient must not have multiple participants, since we would not + * know to which content should be transferred. + * Duplicate patient may have multiple participants (though should not, per + * system design), because all content is to be transferred. If measurements + * exist, it should have at least one participant, because otherwise we can't + * transfer encounters, to which measurements are associated. + * + * Supported encounter types: + * - Nutrition + * - Home Visit + * - Well Child * * @param array $measurements - * A list of group measurements that belong to the 'duplicate' patient. + * A list of measurements belonging to the 'duplicate' patient. * @param int $original * Node ID of the 'original' patient. * @param int $duplicate * Node ID of the 'duplicate' patient. + * @param string $encounter_type + * The type of encounter. + * + * @return bool + * True, if validation was successful. * * @throws \EntityMetadataWrapperException */ -function hedley_patient_consolidate_nutrition_content(array $measurements, $original, $duplicate) { - $count = count($measurements); - drush_print("Duplicate got $count Nutrition measurements."); +function _consolidate_nutritionlike_content_validate(array $measurements, $original, $duplicate, $encounter_type) { + if (!in_array($encounter_type, ['nutrition', 'home-visit', 'well-child'])) { + drush_print('Error: Allowed encounter types: nutrition, home-visit, well-child'); + return FALSE; + } + + $count_measurements = count($measurements); + drush_print("Duplicate got $count_measurements $encounter_type measurements."); + + $participants_original = hedley_person_individual_participants_for_person($original, $encounter_type, 'DESC'); + $count_original = count($participants_original); + if ($count_original > 1) { + drush_print('Error: There are multiple participants for original, while only one is allowed.'); + drush_print('Can not determine with which participant to consolidate.'); + return FALSE; + } - $participants_original = hedley_person_individual_participants_for_person($original, 'nutrition', 'DESC'); - $count = count($participants_original); $list = implode(',', $participants_original); - drush_print("Original got $count Participants: $list"); + drush_print("Original got $count_original $encounter_type Participants: $list"); - $participants_duplicate = hedley_person_individual_participants_for_person($duplicate, 'nutrition', 'DESC'); - $count = count($participants_duplicate); - $list = implode(',', $participants_duplicate); - drush_print("Duplicate got $count Participants: $list"); + $participants_duplicate = hedley_person_individual_participants_for_person($duplicate, $encounter_type, 'DESC'); + $count_duplicate = count($participants_duplicate); + if ($count_duplicate == 0 && $count_measurements > 0) { + drush_print("Error: Duplicate got 0 $encounter_type participants. Can not pull encounters data for duplicate."); + return FALSE; + } - // Search for ongoing participant of original patient. - // If found, record it's ID. - $participant_original_ongoing = FALSE; - foreach ($participants_original as $participant) { - $wrapper_participant = entity_metadata_wrapper('node', $participant); - if (empty($wrapper_participant->field_date_concluded->value())) { - $participant_original_ongoing = $participant; - // There can be only one ongoing pregnancy, therefore, there's not - // point to continue. - break; + return TRUE; +} + +/** + * Performs consolidation for Nutrition like use case. + * + * This is a case where we have single participant, with multiple encounters. + * So, in case original got a participant, we associate all encounters + * of duplicate with that participant. If not, we associate the participant + * as well. + * In both cases, we associate all measurements of duplicate with the original. + * + * Supported encounter types: + * - Nutrition + * - Home Visit + * - Well Child + * + * @param array $measurements + * A list of measurements belonging to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * @param string $encounter_type + * The type of encounter. + * + * @throws \EntityMetadataWrapperException + */ +function _consolidate_nutritionlike_content_execute(array $measurements, $original, $duplicate, $encounter_type) { + $participants_original = hedley_person_individual_participants_for_person($original, $encounter_type, 'DESC'); + $count_original = count($participants_original); + $participants_duplicate = hedley_person_individual_participants_for_person($duplicate, $encounter_type, 'DESC'); + + if ($count_original == 0) { + // If original patient does not have a participant, associate + // one (last, if multiple) participant with the original patient. + $original_participant = array_pop($participants_duplicate); + // If there's no such participant, we can skip - validation has passed, + // so there are no more measurements. + if (empty($original_participant)) { + drush_print("Consolidation of $encounter_type encounters content is completed."); + drush_print(''); + return; } - } - // If original patient does not have an ongoing participant, associate - // participants and measurements of duplicate with the original patient. - if (!$participant_original_ongoing) { - hedley_patient_associate_content_by_field($participants_duplicate, 'field_person', $original); - hedley_patient_associate_content_by_field($measurements, 'field_person', $original); - return; + _associate_content_by_field([$original_participant], 'field_person', $original); + } + else { + // We know there is single participant. + $original_participant = $participants_original[0]; } - // If we got here, we know that original patient has an ongoing participant. - // We associate all encounters of the duplicate with it. - // The participants of the duplicate are marked as deleted. + // Associate all encounters of the duplicate with participant of + // original patient. The participants of the duplicate are marked as deleted. foreach ($participants_duplicate as $participant) { $encounters = hedley_person_encounters_for_individual_participant($participant); - hedley_patient_associate_content_by_field($encounters, 'field_individual_participant', $participant_original_ongoing); + _associate_content_by_field($encounters, 'field_individual_participant', $original_participant); $wrapper_participant = entity_metadata_wrapper('node', $participant); $wrapper_participant->field_deleted->set(TRUE); @@ -382,7 +675,36 @@ function hedley_patient_consolidate_nutrition_content(array $measurements, $orig } // Associate all the measurements with the 'original' patient. - hedley_patient_associate_content_by_field($measurements, 'field_person', $original); + _associate_content_by_field($measurements, 'field_person', $original); + + drush_print("Consolidation of $encounter_type encounters content is completed."); + drush_print(''); +} + +/** + * Performs validations before consolidation of Acute Illness content. + * + * For now, it only prints some data. No failure option. + * + * @param array $measurements + * A list of Nutrition measurements that belong to the 'duplicate' patient. + * @param int $original + * Node ID of the 'original' patient. + * @param int $duplicate + * Node ID of the 'duplicate' patient. + * + * @return bool + * True, if validation was successful. + */ +function _consolidate_acute_illness_content_validate(array $measurements, $original, $duplicate) { + $count = count($measurements); + drush_print("Duplicate got $count Acute Illness measurements."); + + $participants_duplicate = hedley_person_individual_participants_for_person($duplicate, 'acute_illness', 'DESC'); + $count = count($participants_duplicate); + drush_print("Duplicate got $count Acute Illness Participants."); + + return TRUE; } /** @@ -393,7 +715,7 @@ function hedley_patient_consolidate_nutrition_content(array $measurements, $orig * any additional logic. * * @param array $measurements - * A list of group measurements that belong to the 'duplicate' patient. + * A list of Acute Illness measurements belonging to the 'duplicate' patient. * @param int $original * Node ID of the 'original' patient. * @param int $duplicate @@ -401,18 +723,16 @@ function hedley_patient_consolidate_nutrition_content(array $measurements, $orig * * @throws \EntityMetadataWrapperException */ -function hedley_patient_consolidate_acute_illness_content(array $measurements, $original, $duplicate) { - $count = count($measurements); - drush_print("Duplicate got $count Acute Illness measurements."); - +function _consolidate_acute_illness_content_execute(array $measurements, $original, $duplicate) { $participants_duplicate = hedley_person_individual_participants_for_person($duplicate, 'acute_illness', 'DESC'); - $count = count($participants_duplicate); - drush_print("Duplicate got $count Participants."); // Associate all participants and measurements of duplicate, // with the original patient. - hedley_patient_associate_content_by_field($participants_duplicate, 'field_person', $original); - hedley_patient_associate_content_by_field($measurements, 'field_person', $original); + _associate_content_by_field($participants_duplicate, 'field_person', $original); + _associate_content_by_field($measurements, 'field_person', $original); + + drush_print("Consolidation of Acute Illness encounters content is completed."); + drush_print(''); } /** @@ -431,12 +751,13 @@ function hedley_patient_consolidate_acute_illness_content(array $measurements, $ * @return array[] * List of measurements, grouped by encounter type. */ -function hedley_patient_group_measurements_by_encounter_type(array $measurements) { +function _group_measurements_by_encounter_type(array $measurements) { $group_measurements = []; $antenatal_measurements = []; $nutrition_measurements = []; $acute_illness_measurements = []; $home_visit_measurements = []; + $well_child_measurements = []; // Group the measurements using encounter type indicator field. foreach ($measurements as $measurement) { @@ -459,12 +780,17 @@ function hedley_patient_group_measurements_by_encounter_type(array $measurements if ($wrapper->__isset('field_acute_illness_encounter')) { $acute_illness_measurements[] = $measurement; + continue; } if ($wrapper->__isset('field_home_visit_encounter')) { - $nutrition_measurements[] = $measurement; + $home_visit_measurements[] = $measurement; continue; } + + if ($wrapper->__isset('field_well_child_encounter')) { + $well_child_measurements[] = $measurement; + } } return [ @@ -473,6 +799,7 @@ function hedley_patient_group_measurements_by_encounter_type(array $measurements $nutrition_measurements, $acute_illness_measurements, $home_visit_measurements, + $well_child_measurements, ]; } @@ -490,7 +817,7 @@ function hedley_patient_group_measurements_by_encounter_type(array $measurements * * @throws \EntityMetadataWrapperException */ -function hedley_patient_associate_content_by_field(array $content_ids, $field, $target_id) { +function _associate_content_by_field(array $content_ids, $field, $target_id) { foreach ($content_ids as $id) { $wrapper = entity_metadata_wrapper('node', $id); $wrapper->{$field}->set($target_id); diff --git a/server/hedley/modules/custom/hedley_patient/hedley_patient.module b/server/hedley/modules/custom/hedley_patient/hedley_patient.module index bfa20ae975..5b5e67a7c1 100644 --- a/server/hedley/modules/custom/hedley_patient/hedley_patient.module +++ b/server/hedley/modules/custom/hedley_patient/hedley_patient.module @@ -205,7 +205,7 @@ function hedley_patient_shards_for_person_by_pmtct_participants($nid) { $shards = $query->execute()->fetchCol(); - $shard = hedley_device_shard_by_health_center($nid); + $shard = hedley_general_shard_by_health_center($nid); if ($shard && !in_array($shard, $shards)) { $shards[] = $shard; } diff --git a/server/hedley/modules/custom/hedley_restful/hedley_restful.module b/server/hedley/modules/custom/hedley_restful/hedley_restful.module index d37ccd0ec5..2c177a642d 100644 --- a/server/hedley/modules/custom/hedley_restful/hedley_restful.module +++ b/server/hedley/modules/custom/hedley_restful/hedley_restful.module @@ -336,80 +336,6 @@ function hedley_restful_query_in_batches(\EntityFieldQuery $base_query, $batch_s } } -/** - * Join a field to a DB Select query, and add its main value. - * - * @param SelectQuery $query - * Query to join to. - * @param string $entity_type - * Type of the host entity of the field. Or NULL to avoid filtering the field - * table by entity type. - * @param string $field_name - * Field name. - * @param bool $require - * Whether filter out rows where this field would be NULL. - * @param string $entity_id_selector - * SQL selector for the column by which the field is joined. The entity ID is - * used by default. - * @param string $field_alias - * The field alias. - * - * @throws Exception - */ -function hedley_restful_join_field_to_query(SelectQuery $query, $entity_type, $field_name, $require = TRUE, $entity_id_selector = NULL, $field_alias = NULL, $second_value = FALSE) { - $field = field_info_field($field_name); - $table_name = _field_sql_storage_tablename($field); - - if (!$entity_id_selector) { - if (!$entity_type) { - throw new Exception('Entity type is required when ID selector is not specified'); - } - // Set default entity ID selector. - switch ($entity_type) { - case 'user': - $entity_id_selector = 'users.uid'; - break; - - case 'node': - $entity_id_selector = 'node.nid'; - break; - - default: - throw new Exception(format_string('hedley_general_join_field_to_query() is not implemented for entity_type: "@type"', ['@type' => $entity_type])); - } - } - - switch ($field['type']) { - case 'entityreference': - $column_suffix = 'target_id'; - break; - - case 'image': - case 'file': - $column_suffix = 'fid'; - break; - - default: - $column_suffix = 'value'; - } - - $field_alias = $field_alias ?: $field_name; - $query->addField($field_alias, $field_name . '_' . $column_suffix, $field_alias); - if ($second_value) { - $column_suffix = 'value2'; - $query->addField($field_alias, $field_name . '_' . $column_suffix, $field_alias); - } - - $join = $require ? 'innerJoin' : 'leftJoin'; - $arguments = [':type' => $entity_type]; - $conditions[] = "$entity_id_selector = $field_alias.entity_id"; - if ($entity_type) { - $conditions[] = "$field_alias.entity_type = :type"; - } - - $query->$join($table_name, $field_alias, implode(' AND ', $conditions), $arguments); -} - /** * Resolves UID of user that owns the access token. * diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulAcuteIllnessEncounter.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulAcuteIllnessEncounter.class.php index f81984fcd8..70bb77eda6 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulAcuteIllnessEncounter.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulAcuteIllnessEncounter.class.php @@ -39,7 +39,7 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulClinics.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulClinics.class.php index 71522084fc..9b9a7fa7b4 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulClinics.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulClinics.class.php @@ -44,14 +44,14 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // Get the UUID of the health center. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_health_center.field_health_center_target_id", 'uuid_health_center'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_health_center.field_health_center_target_id", 'uuid_health_center'); // Get the UUID of the village. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_village_ref.field_village_ref_target_id", 'uuid_village'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_village_ref.field_village_ref_target_id", 'uuid_village'); } /** diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulCounselingSchedule.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulCounselingSchedule.class.php index b116ec79a0..7858ff537a 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulCounselingSchedule.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulCounselingSchedule.class.php @@ -38,11 +38,11 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // Get the UUID of the health center. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_topics.field_topics_target_id", 'uuids_topics'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_topics.field_topics_target_id", 'uuids_topics'); $query->addExpression("GROUP_CONCAT(DISTINCT uuids_topics.field_uuid_value)", 'uuids_topics'); $query->groupBy('node.nid'); } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulCounselingTopics.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulCounselingTopics.class.php index 9dada27a9b..d50d4a4f24 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulCounselingTopics.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulCounselingTopics.class.php @@ -33,7 +33,7 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulHealthCenters.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulHealthCenters.class.php index 968dde36e5..3e635d4bc9 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulHealthCenters.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulHealthCenters.class.php @@ -38,11 +38,11 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // Get the UUID of the catchment area. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_catchment_area.field_catchment_area_target_id", 'uuid_catchment_area'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_catchment_area.field_catchment_area_target_id", 'uuid_catchment_area'); } /** diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulIndividualEncounter.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulIndividualEncounter.class.php index 4661863ad4..3005668e76 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulIndividualEncounter.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulIndividualEncounter.class.php @@ -43,13 +43,13 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } - hedley_restful_join_field_to_query($query, 'node', 'field_scheduled_date', FALSE, NULL, NULL, TRUE); + hedley_general_join_field_to_query($query, 'node', 'field_scheduled_date', FALSE, NULL, NULL, TRUE); // Get the UUIDs of the Individual participant. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_individual_participant.field_individual_participant_target_id", 'uuid_individual_participant'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_individual_participant.field_individual_participant_target_id", 'uuid_individual_participant'); return $query; } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulIndividualParticipants.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulIndividualParticipants.class.php index 0d75451ca9..84fb86f926 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulIndividualParticipants.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulIndividualParticipants.class.php @@ -85,17 +85,17 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } - hedley_restful_join_field_to_query($query, 'node', 'field_expected', FALSE, NULL, NULL, TRUE); + hedley_general_join_field_to_query($query, 'node', 'field_expected', FALSE, NULL, NULL, TRUE); // Get the UUID of the Person. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_person.field_person_target_id", 'uuid_person'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_person.field_person_target_id", 'uuid_person'); // Get the UUID of the Newborn. // Not every node may have it, so we do not defined it as required. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_newborn.field_newborn_target_id", 'uuid_newborn'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_newborn.field_newborn_target_id", 'uuid_newborn'); } /** diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulNurses.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulNurses.class.php index d3571ec047..64bc1cdf2d 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulNurses.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulNurses.class.php @@ -49,17 +49,17 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } $query->addExpression("GROUP_CONCAT(DISTINCT field_role.field_role_value)", 'field_role'); // Get the UUIDs of the health centers. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_health_centers.field_health_centers_target_id", 'uuids_health_centers'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_health_centers.field_health_centers_target_id", 'uuids_health_centers'); $query->addExpression("GROUP_CONCAT(DISTINCT uuids_health_centers.field_uuid_value)", 'uuids_health_centers'); // Get the UUIDs of the villages. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_villages.field_villages_target_id", 'uuids_villages'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_villages.field_villages_target_id", 'uuids_villages'); $query->addExpression("GROUP_CONCAT(DISTINCT uuids_villages.field_uuid_value)", 'uuids_villages'); $query->groupBy('node.nid'); } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulParticipantsForm.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulParticipantsForm.class.php index 4c9c570600..d7d9077d24 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulParticipantsForm.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulParticipantsForm.class.php @@ -46,7 +46,7 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPeople.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPeople.class.php index a2c993cc20..fefcc28611 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPeople.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPeople.class.php @@ -100,7 +100,7 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // For the Photo, get to the `file`. We'll convert the `uri` @@ -109,7 +109,7 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { $query->addField('f', 'uri'); // Get the UUID of the health center. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_health_center.field_health_center_target_id", 'uuid_health_center'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_health_center.field_health_center_target_id", 'uuid_health_center'); } /** diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPmtctParticipants.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPmtctParticipants.class.php index 6c92993edc..24663eab7e 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPmtctParticipants.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPmtctParticipants.class.php @@ -72,15 +72,15 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } - hedley_restful_join_field_to_query($query, 'node', 'field_expected', FALSE, NULL, NULL, TRUE); + hedley_general_join_field_to_query($query, 'node', 'field_expected', FALSE, NULL, NULL, TRUE); // Get the UUIDs of the Person, Adult and Clinic. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_person.field_person_target_id", 'uuid_person'); - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_adult.field_adult_target_id", 'uuid_adult'); - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_clinic.field_clinic_target_id", 'uuid_clinic'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_person.field_person_target_id", 'uuid_person'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_adult.field_adult_target_id", 'uuid_adult'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_clinic.field_clinic_target_id", 'uuid_clinic'); } /** diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPrenatalEncounter.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPrenatalEncounter.class.php index f54fc99873..91ab95de7d 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPrenatalEncounter.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulPrenatalEncounter.class.php @@ -34,7 +34,7 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulRelationships.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulRelationships.class.php index f32ed28224..39dbe291da 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulRelationships.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulRelationships.class.php @@ -59,12 +59,12 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // Get the UUIDs of the Person and 'Related to' person. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_person.field_person_target_id", 'uuid_person'); - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_related_to.field_related_to_target_id", 'uuid_related_to'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_person.field_person_target_id", 'uuid_person'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_related_to.field_related_to_target_id", 'uuid_related_to'); } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSessions.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSessions.class.php index e777ca2a1c..501ebc2562 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSessions.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSessions.class.php @@ -43,12 +43,12 @@ public function publicFieldsInfo() { * {@inheritdoc} */ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { - hedley_restful_join_field_to_query($query, 'node', 'field_clinic', FALSE); - hedley_restful_join_field_to_query($query, 'node', 'field_scheduled_date', FALSE, NULL, NULL, TRUE); + hedley_general_join_field_to_query($query, 'node', 'field_clinic', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_scheduled_date', FALSE, NULL, NULL, TRUE); // Get the UUID of the Clinic. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_clinic.field_clinic_target_id", 'uuid_clinic'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_clinic.field_clinic_target_id", 'uuid_clinic'); // Get the type of the Clinic. - hedley_restful_join_field_to_query($query, 'node', 'field_group_type', TRUE, "field_clinic.field_clinic_target_id"); + hedley_general_join_field_to_query($query, 'node', 'field_group_type', TRUE, "field_clinic.field_clinic_target_id"); } /** diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSync.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSync.class.php index bb6eb4a064..afda5f7b0f 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSync.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSync.class.php @@ -237,10 +237,10 @@ public function getForHealthCenter($uuid) { ->condition('node.vid', $base, '>'); // Filter by Shards. - hedley_restful_join_field_to_query($query, 'node', 'field_shards', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_shards', FALSE); // And the table which will give us the UUID of the shard. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_shards.field_shards_target_id", 'field_uuid_shards'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_shards.field_shards_target_id", 'field_uuid_shards'); $query->condition('field_uuid_shards.field_uuid_value', $uuid); @@ -286,48 +286,6 @@ public function getForHealthCenter($uuid) { $output = array_merge($output, $rendered_items); } - // Get the HC node ID. - if ($health_center_id = hedley_restful_resolve_nid_for_uuid($uuid)) { - $cache_data = hedley_stats_handle_cache(HEDLEY_STATS_CACHE_GET, HEDLEY_STATS_SYNC_STATS_CACHE, $health_center_id); - - $calculate_stats = FALSE; - // Check if we need to calculate the statistics for this HC. - if (!empty($cache_data) && !empty($request['stats_cache_hash'])) { - if ($cache_data != $request['stats_cache_hash']) { - // Cache hash from the frontend doesn't match the one we have in the - // backend, this means that stats has been changed because it's only - // reset when a measurement has changed. - $calculate_stats = TRUE; - } - } - else { - // We either don't have cache hash yet or this frontend doesn't have - // it, in any case, we will calculate the statistics and send it to - // the frontend. - // We don't cache here because each statistic has its own cache inside - // the function. - $calculate_stats = TRUE; - - // In case the hash is not set at all but we have cached data, this - // means the worker has calculated the stats but we still didn't send - // it to the frontend, therefore we don't need to create another - // worker. - if (!empty($cache_data) && !isset($request['stats_cache_hash'])) { - $calculate_stats = FALSE; - } - } - - if ($calculate_stats) { - // We need to create a worker which will calculate the data, if the - // worker already exists, the general function will know to not create - // a duplicated worker. - // The cache is set in the calculating function itself. - hedley_general_add_task_to_advanced_queue_by_id(HEDLEY_STATS_CALCULATE_STATS, $health_center_id, [ - 'health_center_nid' => $health_center_id, - ]); - } - } - return [ 'base_revision' => $base, // We temporary leave last_timestamp, until all @@ -345,7 +303,7 @@ public function getForHealthCenter($uuid) { * The UUID of the health center. * * @return array - * A representation of the required revisions + * A representation of the required revisions. */ public function getForHealthCenterStatistics($uuid) { $return = [ @@ -354,20 +312,30 @@ public function getForHealthCenterStatistics($uuid) { $health_center_id = hedley_restful_resolve_nid_for_uuid($uuid); if (!$health_center_id) { + // Can not resolve health center - return empty response. return $return; } - $cache_data = hedley_stats_handle_cache(HEDLEY_STATS_CACHE_GET, HEDLEY_STATS_SYNC_STATS_CACHE, $health_center_id); - if (empty($cache_data)) { + $cached_hash = hedley_stats_handle_cache(HEDLEY_STATS_CACHE_GET, HEDLEY_STATS_SYNC_STATS_CACHE, $health_center_id); + if (empty($cached_hash)) { + // There's no cached data for health center - trigger statistics + // calculation by adding an AQ item. + hedley_general_add_task_to_advanced_queue_by_id(HEDLEY_STATS_CALCULATE_STATS, $health_center_id, [ + 'health_center_nid' => $health_center_id, + ]); return $return; } $request = $this->getRequest(); - - if (!isset($request['stats_cache_hash']) || $cache_data != $request['stats_cache_hash']) { - $return['batch'][] = hedley_stats_calculate_stats_for_health_center($health_center_id); + if (!isset($request['stats_cache_hash']) || $cached_hash !== $request['stats_cache_hash']) { + // Statistics hash does not match that of the server, which indicates + // that we need to send updated statistics to client. + // Note: we just want to pull existing data, without updating cache. + $return['batch'][] = hedley_stats_calculate_stats_for_health_center($health_center_id, $cached_hash); } + // If we got this far, we know that statistics on client are + // up to date - return empty response. return $return; } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSyncBase.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSyncBase.class.php index 52758f65e7..48e23938d1 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSyncBase.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulSyncBase.class.php @@ -74,7 +74,7 @@ protected function getQueryForViewWithDbSelect(array $node_ids) { $query->fields('node', ['type', 'nid', 'vid', 'changed', 'title', 'status']); $query->condition('node.nid', $node_ids, 'IN'); - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE); return $query; } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulVillages.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulVillages.class.php index 8cb28cb56d..8146ffc8d9 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulVillages.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/HedleyRestfulVillages.class.php @@ -53,11 +53,11 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // Get the UUID of the health center. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_health_center.field_health_center_target_id", 'uuid_health_center'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_health_center.field_health_center_target_id", 'uuid_health_center'); } /** diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulActivityBase.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulActivityBase.class.php index 6e08e949c9..0c8e69dc95 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulActivityBase.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulActivityBase.class.php @@ -85,17 +85,17 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // Get the UUID of the Nurse. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_nurse.field_nurse_target_id", 'uuid_nurse'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_nurse.field_nurse_target_id", 'uuid_nurse'); // Get the UUID of the Person. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_person.field_person_target_id", 'uuid_person'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_person.field_person_target_id", 'uuid_person'); foreach (array_merge($this->fields, $this->multiFields) as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } foreach ($this->multiFields as $field_name) { diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulAcuteIllnessActivityBase.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulAcuteIllnessActivityBase.class.php index 2630321b23..51ebe3338f 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulAcuteIllnessActivityBase.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulAcuteIllnessActivityBase.class.php @@ -30,9 +30,9 @@ public function publicFieldsInfo() { protected function alterQueryForViewWithDbSelect(SelectQuery $query) { $query = parent::alterQueryForViewWithDbSelect($query); - hedley_restful_join_field_to_query($query, 'node', 'field_acute_illness_encounter', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_acute_illness_encounter', FALSE); // Get the UUID of the Prenatal encounter. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_acute_illness_encounter.field_acute_illness_encounter_target_id", 'uuid_acute_illness_encounter'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_acute_illness_encounter.field_acute_illness_encounter_target_id", 'uuid_acute_illness_encounter'); return $query; } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulCounselingSessions.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulCounselingSessions.class.php index 14a3721fd0..3595950142 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulCounselingSessions.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulCounselingSessions.class.php @@ -40,11 +40,11 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // Get the UUID of the health center. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_topics.field_topics_target_id", 'uuids_topics'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_topics.field_topics_target_id", 'uuids_topics'); $query->addExpression("GROUP_CONCAT(DISTINCT uuids_topics.field_uuid_value)", 'uuids_topics'); $query->groupBy('node.nid'); } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulGroupActivityBase.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulGroupActivityBase.class.php index ebda607988..63ecf1fa52 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulGroupActivityBase.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulGroupActivityBase.class.php @@ -35,11 +35,11 @@ protected function alterQueryForViewWithDbSelect(SelectQuery $query) { ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name, FALSE); } // Get the UUID of the Session. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_session.field_session_target_id", 'uuid_session'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_session.field_session_target_id", 'uuid_session'); return $query; } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulHomeVisitActivityBase.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulHomeVisitActivityBase.class.php index 62266eb9b1..633fee8a2b 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulHomeVisitActivityBase.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulHomeVisitActivityBase.class.php @@ -30,9 +30,9 @@ public function publicFieldsInfo() { protected function alterQueryForViewWithDbSelect(SelectQuery $query) { $query = parent::alterQueryForViewWithDbSelect($query); - hedley_restful_join_field_to_query($query, 'node', 'field_home_visit_encounter', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_home_visit_encounter', FALSE); // Get the UUID of the Prenatal encounter. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_home_visit_encounter.field_home_visit_encounter_target_id", 'uuid_home_visit_encounter'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_home_visit_encounter.field_home_visit_encounter_target_id", 'uuid_home_visit_encounter'); return $query; } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulNutritionActivityBase.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulNutritionActivityBase.class.php index e0ebbba755..78552bbcd2 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulNutritionActivityBase.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulNutritionActivityBase.class.php @@ -30,9 +30,9 @@ public function publicFieldsInfo() { protected function alterQueryForViewWithDbSelect(SelectQuery $query) { $query = parent::alterQueryForViewWithDbSelect($query); - hedley_restful_join_field_to_query($query, 'node', 'field_nutrition_encounter', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_nutrition_encounter', FALSE); // Get the UUID of the Prenatal encounter. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_nutrition_encounter.field_nutrition_encounter_target_id", 'uuid_nutrition_encounter'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_nutrition_encounter.field_nutrition_encounter_target_id", 'uuid_nutrition_encounter'); return $query; } diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulParticipantsConsent.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulParticipantsConsent.class.php index 49ee07bc4a..1d2b5325a9 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulParticipantsConsent.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulParticipantsConsent.class.php @@ -34,11 +34,11 @@ public function publicFieldsInfo() { protected function alterQueryForViewWithDbSelect(SelectQuery $query) { $query = parent::alterQueryForViewWithDbSelect($query); - hedley_restful_join_field_to_query($query, 'node', 'field_language', FALSE); - hedley_restful_join_field_to_query($query, 'node', 'field_participant_form', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_language', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_participant_form', FALSE); // Get the UUID of the Participant form. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_participant_form.field_participant_form_target_id", 'uuid_participant_form'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', TRUE, "field_participant_form.field_participant_form_target_id", 'uuid_participant_form'); } /** diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulPhotos.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulPhotos.class.php index 4d65b20414..fc49ac3a8d 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulPhotos.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulPhotos.class.php @@ -33,7 +33,7 @@ public function publicFieldsInfo() { protected function alterQueryForViewWithDbSelect(SelectQuery $query) { $query = parent::alterQueryForViewWithDbSelect($query); - hedley_restful_join_field_to_query($query, 'node', 'field_photo', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_photo', FALSE); // For the Photo, get to the `file`. We'll convert the `uri` // to `field_photo`. diff --git a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulPrenatalActivityBase.class.php b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulPrenatalActivityBase.class.php index f0661732a5..de0ef0cf94 100644 --- a/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulPrenatalActivityBase.class.php +++ b/server/hedley/modules/custom/hedley_restful/plugins/restful/node/activity/HedleyRestfulPrenatalActivityBase.class.php @@ -30,9 +30,9 @@ public function publicFieldsInfo() { protected function alterQueryForViewWithDbSelect(SelectQuery $query) { $query = parent::alterQueryForViewWithDbSelect($query); - hedley_restful_join_field_to_query($query, 'node', 'field_prenatal_encounter', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_prenatal_encounter', FALSE); // Get the UUID of the Prenatal encounter. - hedley_restful_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_prenatal_encounter.field_prenatal_encounter_target_id", 'uuid_prenatal_encounter'); + hedley_general_join_field_to_query($query, 'node', 'field_uuid', FALSE, "field_prenatal_encounter.field_prenatal_encounter_target_id", 'uuid_prenatal_encounter'); return $query; } diff --git a/server/hedley/modules/custom/hedley_stats/hedley_stats.module b/server/hedley/modules/custom/hedley_stats/hedley_stats.module index d863f13935..2e7d6b6bbc 100644 --- a/server/hedley/modules/custom/hedley_stats/hedley_stats.module +++ b/server/hedley/modules/custom/hedley_stats/hedley_stats.module @@ -15,10 +15,23 @@ define('HEDLEY_STATS_PERIOD_TWO_MONTHS_AGO', 'two_months_ago'); define('HEDLEY_STATS_PERIOD_PAST_THREE_MONTHS', 'past_three_month'); define('HEDLEY_STATS_PERIOD_ONE_YEAR', 'one_year'); define('HEDLEY_STATS_PERIOD_LAST_YEAR', 'last_year'); +define('HEDLEY_STATS_PERIOD_480_DAYS', '480_days'); +define('HEDLEY_STATS_PERIOD_PAST_SIX_MONTHS', 'past_six_month'); + + define('HEDLEY_STATS_SEVERE', 'severe_nutrition'); define('HEDLEY_STATS_MODERATE', 'moderate_nutrition'); define('HEDLEY_STATS_GOOD', 'good_nutrition'); +// Encounter types. +define('HEDLEY_STATS_PRENATAL_ENCOUNTER_TYPE', 'antenatal'); +define('HEDLEY_STATS_ACUTE_ILLNESS_ENCOUNTER_TYPE', 'acute-illness'); + +// Statistics cache types. +define('HEDLEY_STATS_NUTRITION', 'sync_stats_nutrition'); +define('HEDLEY_STATS_PRENATAL', 'sync_stats_prenatal'); +define('HEDLEY_STATS_ACUTE_ILLNESS', 'sync_stats_acute_illness'); + // Cache IDs. define('HEDLEY_STATS_SYNC_STATS_CACHE', 'sync_stats_general'); define('HEDLEY_STATS_SYNC_MEASUREMENTS_BY_PERSON', 'sync_measurements_query_grouped_by_person'); @@ -27,6 +40,8 @@ define('HEDLEY_STATS_SYNC_CHILDREN_BENEFICIARIES', 'sync_children_beneficiaries_ define('HEDLEY_STATS_SYNC_FAMILY_PLANNING', 'sync_family_planning_stats'); define('HEDLEY_STATS_SYNC_TOTAL_ENCOUNTERS', 'sync_total_encounters_stats'); define('HEDLEY_STATS_SYNC_CASE_MANAGEMENT', 'sync_case_management_stats'); +define('HEDLEY_STATS_SYNC_ACUTE_ILLNESS_DATA', 'sync_acute_illness_data'); +define('HEDLEY_STATS_SYNC_PRENATAL_DATA', 'sync_prenatal_data'); // Cache methods. define('HEDLEY_STATS_CACHE_GET', 'get'); @@ -56,19 +71,21 @@ function hedley_stats_node_update($node) { * @throws \EntityMetadataWrapperException */ function hedley_stats_trigger_stats_recalculation($node) { - if (!hedley_stats_requires_statistics_recalculation($node->type)) { + $cache_type_for_recalculation = hedley_stats_requires_statistics_recalculation($node); + + if ($cache_type_for_recalculation === FALSE) { return; } $wrapper = entity_metadata_wrapper('node', $node); - if (!$wrapper->__isset('field_shards')) { // Can't resolve to which health centers content belongs. return; } + $health_centers = $wrapper->field_shards->value(['identifier' => TRUE]); + // Get health centers. - $health_centers = $wrapper->field_shards->value(); if (empty($health_centers)) { return; } @@ -76,25 +93,52 @@ function hedley_stats_trigger_stats_recalculation($node) { // Reset statistics cache of each health center, because // content affecting it's statistics has been added / changed. foreach ($health_centers as $health_center) { - hedley_stats_clear_caches_for_health_center($health_center->nid); + hedley_stats_clear_caches_for_health_center($health_center, $cache_type_for_recalculation); // Add an AQ item to re-calculate all the statistics offline. - hedley_general_add_task_to_advanced_queue_by_id(HEDLEY_STATS_CALCULATE_STATS, $health_center->nid, [ - 'health_center_nid' => $health_center->nid, + hedley_general_add_task_to_advanced_queue_by_id(HEDLEY_STATS_CALCULATE_STATS, $health_center, [ + 'health_center_nid' => $health_center, ]); } } /** - * Checks if content type creation/update requires statistics recalculation. + * Checks if entity requires statistics recalculation. + * + * @param object $node + * The entity. + * + * @return string|bool + * The type of cache to clear. False, if clearing is not required. + */ +function hedley_stats_requires_statistics_recalculation($node) { + if (hedley_stats_requires_nutrition_statistics_recalculation($node->type)) { + return HEDLEY_STATS_NUTRITION; + } + + $wrapper = entity_metadata_wrapper('node', $node); + + if (hedley_stats_requires_prenatal_statistics_recalculation($wrapper)) { + return HEDLEY_STATS_PRENATAL; + } + + if (hedley_stats_requires_acute_illness_statistics_recalculation($wrapper)) { + return HEDLEY_STATS_ACUTE_ILLNESS; + } + + return FALSE; +} + +/** + * Checks if entity requires Nutrition statistics recalculation. * - * @param string $type - * The type of content. + * @param string $bundle + * Entity bundle. * * @return bool - * True, if give content type requires statistics recalculation. + * True, if statistics recalculation is required. */ -function hedley_stats_requires_statistics_recalculation($type) { +function hedley_stats_requires_nutrition_statistics_recalculation($bundle) { $triggering_types = array_merge( [ HEDLEY_ACTIVITY_ATTENDANCE_CONTENT_TYPE, @@ -107,7 +151,69 @@ function hedley_stats_requires_statistics_recalculation($type) { HEDLEY_ACTIVITY_WEIGHT_BUNDLES ); - return in_array($type, $triggering_types); + return in_array($bundle, $triggering_types); +} + +/** + * Checks if entity requires Prenatal statistics recalculation. + * + * @param object $wrapper + * Entity metadata wrapper. + * + * @return bool + * True, if statistics recalculation is required. + */ +function hedley_stats_requires_prenatal_statistics_recalculation($wrapper) { + $triggering_types = [ + HEDLEY_ACTIVITY_PRENATAL_ENCOUNTER_CONTENT_TYPE, + HEDLEY_ACTIVITY_DANGER_SIGNS_CONTENT_TYPE, + ]; + $bundle = $wrapper->getBundle(); + + if (in_array($bundle, $triggering_types)) { + return TRUE; + } + + if ($bundle == HEDLEY_ACTIVITY_INDIVIDUAL_PARTICIPANT_CONTENT_TYPE) { + $encounter_type = $wrapper->field_encounter_type->value(); + return $encounter_type == HEDLEY_STATS_PRENATAL_ENCOUNTER_TYPE; + } + + return FALSE; +} + +/** + * Checks if entity requires Acute illness statistics recalculation. + * + * @param object $wrapper + * Entity metadata wrapper. + * + * @return bool + * True, if statistics recalculation is required. + */ +function hedley_stats_requires_acute_illness_statistics_recalculation($wrapper) { + $triggering_types = [ + HEDLEY_ACTIVITY_ACUTE_ILLNESS_ENCOUNTER_CONTENT_TYPE, + HEDLEY_ACTIVITY_SEND_TO_HC_CONTENT_TYPE, + HEDLEY_ACTIVITY_ACUTE_ILLNESS_VITALS_CONTENT_TYPE, + HEDLEY_ACTIVITY_SYMPTOMS_GENERAL_CONTENT_TYPE, + HEDLEY_ACTIVITY_ISOLATION_CONTENT_TYPE, + HEDLEY_ACTIVITY_CALL_114_CONTENT_TYPE, + HEDLEY_ACTIVITY_HC_CONTAC_CONTENT_TYPE, + ]; + + $bundle = $wrapper->getBundle(); + + if (in_array($bundle, $triggering_types)) { + return TRUE; + } + + if ($bundle == HEDLEY_ACTIVITY_INDIVIDUAL_PARTICIPANT_CONTENT_TYPE) { + $encounter_type = $wrapper->field_encounter_type->value(); + return $encounter_type == HEDLEY_STATS_ACUTE_ILLNESS_ENCOUNTER_TYPE; + } + + return FALSE; } /** @@ -115,8 +221,22 @@ function hedley_stats_requires_statistics_recalculation($type) { * * @param int $nid * Health center node ID. + * @param string $cache_type_for_recalculation + * Type of statistics cache for recalculation. + * Possible options: Nutrition, Prenatal and Acute illness. */ -function hedley_stats_clear_caches_for_health_center($nid) { +function hedley_stats_clear_caches_for_health_center($nid, $cache_type_for_recalculation) { + switch ($cache_type_for_recalculation) { + case HEDLEY_STATS_PRENATAL: + hedley_stats_handle_cache(HEDLEY_STATS_CACHE_CLEAR, HEDLEY_STATS_SYNC_PRENATAL_DATA, $nid); + return; + + case HEDLEY_STATS_ACUTE_ILLNESS: + hedley_stats_handle_cache(HEDLEY_STATS_CACHE_CLEAR, HEDLEY_STATS_SYNC_ACUTE_ILLNESS_DATA, $nid); + return; + } + + // If we got this far, we need to clear Nutrition stats cache. $periods = [ HEDLEY_STATS_PERIOD_THIS_MONTH, HEDLEY_STATS_PERIOD_LAST_MONTH, @@ -126,9 +246,6 @@ function hedley_stats_clear_caches_for_health_center($nid) { HEDLEY_STATS_PERIOD_LAST_YEAR, ]; - // First, clear the stats hash cache. - hedley_stats_handle_cache(HEDLEY_STATS_CACHE_CLEAR, HEDLEY_STATS_SYNC_STATS_CACHE, $nid); - // Clear cache that doesn't have periods. hedley_stats_handle_cache(HEDLEY_STATS_CACHE_CLEAR, HEDLEY_STATS_SYNC_TOTAL_ENCOUNTERS, $nid); hedley_stats_handle_cache(HEDLEY_STATS_CACHE_CLEAR, HEDLEY_STATS_SYNC_SESSION_ATTENDANCE, $nid); @@ -205,61 +322,50 @@ function hedley_stats_calculate_stats_worker($queue_item) { * * @param int $health_center_id * The health center node ID. + * @param string $cached_hash + * Optional; If non empty value provided, we do not update cache hash. * - * @return array|string - * The stats or error message if anything went wrong. + * @return array + * The stats or error details if anything went wrong. */ -function hedley_stats_calculate_stats_for_health_center($health_center_id) { +function hedley_stats_calculate_stats_for_health_center($health_center_id, $cached_hash = '') { try { $wrapper = entity_metadata_wrapper('node', $health_center_id); - // UTC date and time on which statistics were generated. - $timestamp = date('d-m-Y, H:i', time() - date('Z')); - - // First check if the HC has "FBF" clinics, only those have stats for - // the dashboards and we shouldn't send any stats from a HC without - // FBF clinics. // Get all clinics of type 'FBF' for the HC. $fbf_clinics = hedley_health_center_get_clinics_by_health_center($health_center_id, 'fbf'); - if (empty($fbf_clinics)) { - // We send empty stats so we don't upset the decoder in elm. - return [ - 'vid' => 1, - 'type' => 'statistics', - // UUID of the health center. - 'uuid' => $wrapper->field_uuid->value(), - 'case_management' => [], - 'children_beneficiaries' => [], - 'completed_program' => [], - 'family_planning' => [], - 'missed_sessions' => [], - 'total_encounters' => NULL, - 'timestamp' => $timestamp, - ]; + // Calculate statistics that are provided for FBF clinics only. + $completed_program = $missed_sessions = []; + if (!empty($fbf_clinics)) { + list($completed_program, $missed_sessions) = hedley_stats_get_session_attendance_stats_by_health_center($health_center_id, $fbf_clinics); } - // Calculate the stats. - list($completed_program, $missed_sessions) = hedley_stats_get_session_attendance_stats_by_health_center($health_center_id, $fbf_clinics); $villages_with_residents = hedley_stats_get_villages_with_residents($health_center_id); + $health_center_uuid = $wrapper->field_uuid->value(); $stats = [ 'vid' => 1, 'type' => 'statistics', // UUID of the health center. - 'uuid' => $wrapper->field_uuid->value(), + 'uuid' => $health_center_uuid, 'case_management' => hedley_stats_get_case_management($health_center_id), - 'children_beneficiaries' => hedley_stats_get_children_beneficiaries_stats_by_period($health_center_id, $fbf_clinics, HEDLEY_STATS_PERIOD_ONE_YEAR), + 'children_beneficiaries' => hedley_stats_get_children_beneficiaries_stats_by_period($health_center_id), 'completed_program' => $completed_program, 'family_planning' => hedley_stats_get_family_planning_stats_by_period($health_center_id, HEDLEY_STATS_PERIOD_PAST_THREE_MONTHS), 'missed_sessions' => $missed_sessions, 'total_encounters' => hedley_stats_get_total_encounters($health_center_id, $villages_with_residents), + 'acute_illness_data' => hedley_stats_get_acute_illness_data($health_center_id), + 'prenatal_data' => hedley_stats_get_prenatal_data($health_center_id), 'villages_with_residents' => $villages_with_residents, - 'timestamp' => $timestamp, ]; - $stats['stats_cache_hash'] = md5(serialize($stats)); + $now = time(); + // UTC date and time on which statistics were generated. + $timestamp = date('d-m-Y, H:i', $now - date('Z')); + $stats['timestamp'] = $timestamp; + $stats['stats_cache_hash'] = empty($cached_hash) ? md5($now) : $cached_hash; - // Store in cache only the hash, all statistics have their own cache. + // Store in cache only the hash. All statistics have their own cache. hedley_stats_handle_cache(HEDLEY_STATS_CACHE_SET, HEDLEY_STATS_SYNC_STATS_CACHE, $health_center_id, NULL, $stats['stats_cache_hash']); return $stats; @@ -298,32 +404,316 @@ function hedley_stats_get_villages_with_residents($health_center_id) { } /** - * Return new people in a Health centers related stats. + * Return acute illnesses data that is used to generate AI statistics. + * + * We get data of all encounters for illnesses that were active during + * past 6 months. + * We need to know when encounters were created, it's diagnosis, if fever was + * recorded, and several measurements. + * Also, we add patient ID, to be able to associate it with its village. + * + * @param int $health_center_id + * The health center node ID. + * + * @return array + * List of AI encounters data. + * + * @throws \Exception + */ +function hedley_stats_get_acute_illness_data($health_center_id) { + // Return the cache if exists. + if ($cache_data = hedley_stats_handle_cache(HEDLEY_STATS_CACHE_GET, HEDLEY_STATS_SYNC_ACUTE_ILLNESS_DATA, $health_center_id)) { + return $cache_data; + } + + // Pull all acute illness encounters during past 6 month. + $query = hedley_stats_get_base_query($health_center_id, 'acute_illness_encounter', HEDLEY_STATS_PERIOD_PAST_SIX_MONTHS); + + // Resolve all illnesses associated with those encounters. + hedley_general_join_field_to_query($query, 'node', 'field_individual_participant'); + $query->groupBy('field_individual_participant.field_individual_participant_target_id'); + + $result = $query + ->execute() + ->fetchAllAssoc('field_individual_participant'); + + $individual_participants = array_keys($result); + if (empty($individual_participants)) { + return []; + } + + // For each illness, pull the patient and outcome data. + $query = hedley_stats_get_base_query($health_center_id, 'individual_participant'); + $query->condition('node.nid', $individual_participants, 'IN'); + + $fields_to_join = [ + 'field_person', + 'field_outcome', + 'field_date_concluded', + ]; + foreach ($fields_to_join as $field) { + hedley_general_join_field_to_query($query, 'node', $field, FALSE); + } + + $result = $query + ->execute() + ->fetchAllAssoc('nid'); + + $items = []; + // Prepare illnesses data to be consumed by client side. + foreach ($result as $index => $row) { + $items[$index] = [ + 'id' => $row->field_person, + // Field for 'created' is added at hedley_stats_get_base_query(). + 'created' => date_format(date_create($row->field_expected), 'Y-m-d'), + // We use the 'end date' of expected fields here, because the + // 'date concluded' field is not set when illness is resolved. + // While we could do that for illness, 'date concluded' field was meant + // to capture the date when pregnancy has ended - some date in past. + 'date_concluded' => !empty($row->field_expected_field_expected_value2) ? date_format(date_create($row->field_date_concluded), 'Y-m-d') : NULL, + 'outcome' => $row->field_outcome, + 'encounters' => [], + ]; + } + + // Resolve encounters data. + $query = hedley_stats_get_base_query($health_center_id, 'acute_illness_encounter'); + $fields_to_join = [ + 'field_individual_participant', + 'field_sequence_number', + 'field_acute_illness_diagnosis', + ]; + foreach ($fields_to_join as $field) { + hedley_general_join_field_to_query($query, 'node', $field, FALSE); + } + $query->condition('field_individual_participant.field_individual_participant_target_id', $individual_participants, 'IN'); + + // Join with AI Encounter table, through which we can join measurements data. + $query->leftJoin('field_data_field_acute_illness_encounter', 'ai_encounter', 'ai_encounter.field_acute_illness_encounter_target_id = node.nid'); + + // Pull data of health center referrals. + $query->leftJoin('field_data_field_send_to_hc', 'send_to_hc', 'send_to_hc.entity_id = ai_encounter.entity_id'); + $query->addField('send_to_hc', 'field_send_to_hc_value'); + $query->addExpression("GROUP_CONCAT(DISTINCT send_to_hc.field_send_to_hc_value)", 'send_to_hc'); + + // Pull data of recorded fever at symptoms. + $query->leftJoin('field_data_field_fever_period', 'fever_period', 'fever_period.entity_id = ai_encounter.entity_id'); + $query->addField('fever_period', 'field_fever_period_value'); + $query->addExpression("GROUP_CONCAT(fever_period.field_fever_period_value)", 'fever_period'); + + // Pull data of recorded fever at vitals. + $query->leftJoin('field_data_field_body_temperature', 'body_temperature', 'body_temperature.entity_id = ai_encounter.entity_id'); + $query->addField('body_temperature', 'field_body_temperature_value'); + $query->addExpression("GROUP_CONCAT(body_temperature.field_body_temperature_value)", 'body_temperature'); + + // Pull data of isolations - COVID suspect. + $query->leftJoin('field_data_field_isolation', 'isolation', 'isolation.entity_id = ai_encounter.entity_id'); + $query->addField('isolation', 'field_isolation_value'); + $query->addExpression("GROUP_CONCAT(DISTINCT isolation.field_isolation_value)", 'isolation'); + + // Pull data of 114 calls - COVID suspect. + $query->leftJoin('field_data_field_114_contact', '114_contact', '114_contact.entity_id = ai_encounter.entity_id'); + $query->addField('114_contact', 'field_114_contact_value'); + $query->addExpression("GROUP_CONCAT(DISTINCT 114_contact.field_114_contact_value)", 'contact_114'); + + // Pull data of 114 recommendations - COVID suspect. + $query->leftJoin('field_data_field_114_recommendation', '114_recommendation', '114_recommendation.entity_id = ai_encounter.entity_id'); + $query->addField('114_recommendation', 'field_114_recommendation_value'); + $query->addExpression("GROUP_CONCAT(DISTINCT 114_recommendation.field_114_recommendation_value)", 'recommendation_114'); + + // Pull data of HC contact - COVID suspect. + $query->leftJoin('field_data_field_hc_contact', 'hc_contact', 'hc_contact.entity_id = ai_encounter.entity_id'); + $query->addField('hc_contact', 'field_hc_contact_value'); + $query->addExpression("GROUP_CONCAT(DISTINCT hc_contact.field_hc_contact_value)", 'contact_hc'); + + // Pull data of HC recommendations - COVID suspect. + $query->leftJoin('field_data_field_hc_recommendation', 'hc_recommendation', 'hc_recommendation.entity_id = ai_encounter.entity_id'); + $query->addField('hc_recommendation', 'field_hc_recommendation_value'); + $query->addExpression("GROUP_CONCAT(DISTINCT hc_recommendation.field_hc_recommendation_value)", 'recommendation_hc'); + + $query->groupBy('node.nid'); + + $result = $query + ->execute() + ->fetchAllAssoc('nid'); + + // Populate data of the encounters. + foreach ($result as $row) { + $fever_by_signs = !empty($row->fever_period) && $row->fever_period > 0; + $fever_by_vitals = !empty($row->body_temperature) && (float) $row->body_temperature >= 37.5; + + $items[$row->field_individual_participant]['encounters'][] = [ + // Field for 'created' is added at hedley_stats_get_base_query(). + 'start_date' => date_format(date_create($row->field_scheduled_date), 'Y-m-d'), + 'sequence_number' => $row->field_sequence_number, + 'diagnosis' => $row->field_acute_illness_diagnosis, + 'fever' => $fever_by_signs || $fever_by_vitals, + 'send_to_hc' => empty($row->send_to_hc) ? [] : explode(',', $row->send_to_hc), + 'isolation' => empty($row->isolation) ? [] : explode(',', $row->isolation), + 'call_114' => empty($row->contact_114) ? [] : explode(',', $row->contact_114), + 'recommendation_114' => empty($row->recommendation_114) ? [] : explode(',', $row->recommendation_114), + 'contact_hc' => empty($row->contact_hc) ? [] : explode(',', $row->contact_hc), + 'recommendation_hc' => empty($row->recommendation_hc) ? [] : explode(',', $row->recommendation_hc), + ]; + } + + $values = array_values($items); + + // Store in cache. + hedley_stats_handle_cache(HEDLEY_STATS_CACHE_SET, HEDLEY_STATS_SYNC_ACUTE_ILLNESS_DATA, $health_center_id, NULL, $values); + + return $values; +} + +/** + * Return pregnancies data that is used to generate ANC statistics. + * + * We pull data for pregnancies started during past 480 days. + * We need to know when they were created, what was the expected delivery + * date, and if exist, real delivery date and outcome. + * Also, we add patient ID, to be able to associate it with its village. + * + * @param int $health_center_id + * The health center node ID. + * + * @return array + * List of villages UUIDs with IDs of its residents. + * + * @throws \Exception + */ +function hedley_stats_get_prenatal_data($health_center_id) { + // Return the cache if exists. + if ($cache_data = hedley_stats_handle_cache(HEDLEY_STATS_CACHE_GET, HEDLEY_STATS_SYNC_PRENATAL_DATA, $health_center_id)) { + return $cache_data; + } + + $query = hedley_stats_get_base_query($health_center_id, 'individual_participant', HEDLEY_STATS_PERIOD_480_DAYS); + + $fields_to_join = [ + 'field_person', + 'field_encounter_type', + 'field_expected_date_concluded', + 'field_date_concluded', + 'field_outcome', + 'field_outcome_location', + ]; + foreach ($fields_to_join as $field) { + hedley_general_join_field_to_query($query, 'node', $field, FALSE); + } + + // Get only participants of Antenatal type. + $query->condition('field_encounter_type.field_encounter_type_value', HEDLEY_STATS_PRENATAL_ENCOUNTER_TYPE); + + $result = $query + ->execute() + ->fetchAllAssoc('nid'); + + if (empty($result)) { + return []; + } + + $items = []; + // Prepare data to be consumed by client side. + foreach ($result as $index => $row) { + $items[$index] = [ + 'id' => $row->field_person, + // Field for 'created' is added at hedley_stats_get_base_query(). + 'created' => date_format(date_create($row->field_expected), 'Y-m-d'), + 'expected_date_concluded' => !empty($row->field_expected_date_concluded) ? date_format(date_create($row->field_expected_date_concluded), 'Y-m-d') : NULL, + 'date_concluded' => !empty($row->field_date_concluded) ? date_format(date_create($row->field_date_concluded), 'Y-m-d') : NULL, + 'outcome' => $row->field_outcome, + 'delivery_location' => $row->field_outcome_location, + 'encounters' => [], + ]; + } + + $individual_participants = array_keys($items); + + $query = hedley_stats_get_base_query($health_center_id, 'prenatal_encounter'); + $fields_to_join = [ + 'field_individual_participant', + ]; + foreach ($fields_to_join as $field) { + hedley_general_join_field_to_query($query, 'node', $field, FALSE); + } + $query->condition('field_individual_participant.field_individual_participant_target_id', $individual_participants, 'IN'); + + // Join with Prenatal Encounter table, through which we can join + // measurements data. + $query->leftJoin('field_data_field_prenatal_encounter', 'prenatal_encounter', 'prenatal_encounter.field_prenatal_encounter_target_id = node.nid'); + + // Pull data of danger signs that were recorded during encounter. + $query->leftJoin('field_data_field_danger_signs', 'danger_signs', 'danger_signs.entity_id = prenatal_encounter.entity_id'); + $query->addField('danger_signs', 'field_danger_signs_value'); + $query->addExpression("GROUP_CONCAT(DISTINCT danger_signs.field_danger_signs_value)", 'danger_signs'); + + $query->groupBy('node.nid'); + + $result = $query + ->execute() + ->fetchAllAssoc('nid'); + + foreach ($result as $row) { + $items[$row->field_individual_participant]['encounters'][] = [ + // Field for 'created' is added at hedley_stats_get_base_query(). + 'start_date' => date_format(date_create($row->field_scheduled_date), 'Y-m-d'), + 'danger_signs' => explode(',', $row->danger_signs), + ]; + } + + $values = array_values($items); + + // Store in cache. + hedley_stats_handle_cache(HEDLEY_STATS_CACHE_SET, HEDLEY_STATS_SYNC_PRENATAL_DATA, $health_center_id, NULL, $values); + + return $values; +} + +/** + * Returns active participants for HC, during provided period. + * + * Data includes both groups and individual participants. * * @param int $health_center_id * The Health center node ID. - * @param array $fbf_clinics - * A list of FBF clinics IDs that belong to health center. * @param string $period - * The period to calculate. Be default it is for one year, as on the client - * side we could filter out items, if requested to show smaller periods of - * time. + * The period to calculate. By default it is for one year. * * @return array - * Array with the result. + * Array with the participants details grouped by clinic type. * * @throws \Exception */ -function hedley_stats_get_children_beneficiaries_stats_by_period($health_center_id, array $fbf_clinics, $period = HEDLEY_STATS_PERIOD_ONE_YEAR) { +function hedley_stats_get_children_beneficiaries_stats_by_period($health_center_id, $period = HEDLEY_STATS_PERIOD_ONE_YEAR) { // Return the cache if exists. if ($cache_data = hedley_stats_handle_cache(HEDLEY_STATS_CACHE_GET, HEDLEY_STATS_SYNC_CHILDREN_BENEFICIARIES, $health_center_id, $period)) { return $cache_data; } - $query = db_select('node', 'node'); - $query->fields('node', ['type', 'nid', 'created']); - $query->condition('node.type', 'pmtct_participant'); - $query->condition('node.status', NODE_PUBLISHED); + $items = hedley_stats_get_children_beneficiaries_group_stats($health_center_id, $period); + $items['individual'] = hedley_stats_get_children_beneficiaries_individual_stats($health_center_id); + + // Store in cache. + hedley_stats_handle_cache(HEDLEY_STATS_CACHE_SET, HEDLEY_STATS_SYNC_CHILDREN_BENEFICIARIES, $health_center_id, $period, $items); + + return $items; +} + +/** + * Returns active participants for HC (per clinic type), during provided period. + * + * @param int $health_center_id + * The Health center node ID. + * @param string $period + * The period to calculate. By default it is for one year. + * + * @return array + * Array with the participants details grouped by clinic type. + * + * @throws \Exception + */ +function hedley_stats_get_children_beneficiaries_group_stats($health_center_id, $period = HEDLEY_STATS_PERIOD_ONE_YEAR) { + $query = hedley_stats_get_base_query($health_center_id, 'pmtct_participant'); $field_names = [ 'field_person', @@ -332,12 +722,10 @@ function hedley_stats_get_children_beneficiaries_stats_by_period($health_center_ ]; foreach ($field_names as $field_name) { - hedley_restful_join_field_to_query($query, 'node', $field_name, FALSE); + hedley_general_join_field_to_query($query, 'node', $field_name); } - $query->condition('field_clinic.field_clinic_target_id', $fbf_clinics); - - hedley_restful_join_field_to_query($query, 'node', 'field_expected', FALSE, NULL, NULL, TRUE); + hedley_general_join_field_to_query($query, 'node', 'field_group_type', TRUE, 'field_clinic.field_clinic_target_id'); $date = hedley_stats_get_period($period); // We want to get all participants that graduate within, or after @@ -348,37 +736,97 @@ function hedley_stats_get_children_beneficiaries_stats_by_period($health_center_ ->execute() ->fetchAllAssoc('nid'); - // Prepare data to be consumed by client side. - foreach ($result as &$row) { - $row->created = hedley_stats_convert_timestamp_to_nominal($row->created); + $items = []; + foreach (hedley_stats_get_all_clinic_types() as $clinic_type) { + $items[$clinic_type] = []; + } + foreach ($result as $row) { + $clinic_type = $row->field_group_type; $child_wrapper = entity_metadata_wrapper('node', $row->field_person); + $birth_date = $child_wrapper->field_birth_date->value(); + + if (empty($birth_date)) { + // Child got no birthdate set. We can't process + // it's data on client, so we skip it. + continue; + } + $adult_wrapper = entity_metadata_wrapper('node', $row->field_adult); - $row->name = $child_wrapper->label(); - $birth_date = $child_wrapper->field_birth_date->value(); - $row->field_birth_date = hedley_stats_convert_timestamp_to_nominal($birth_date); - $row->field_gender = $child_wrapper->field_gender->value(); - $row->mother_name = $adult_wrapper->label(); - $row->phone_number = $adult_wrapper->field_phone_number->value(); + $items[$clinic_type][] = [ + 'created' => hedley_stats_convert_timestamp_to_nominal($row->created), + 'id' => $child_wrapper->getIdentifier(), + 'name' => $child_wrapper->label(), + 'birth_date' => hedley_stats_convert_timestamp_to_nominal($birth_date), + 'gender' => $child_wrapper->field_gender->value(), + 'mother_name' => $adult_wrapper->label(), + 'phone_number' => $adult_wrapper->field_phone_number->value(), + 'graduation_date' => date_format(date_create($row->field_expected_field_expected_value2), 'Y-m-d'), + ]; + } - $graduation_date = date_format(date_create($row->field_expected_field_expected_value2), 'Y-m-d'); - $row->graduation_date = $graduation_date; + return $items; +} - // Remove unused data, to save bandwidth. - unset($row->nid); - unset($row->type); - unset($row->field_person); - unset($row->field_adult); - unset($row->field_clinic); - unset($row->field_expected); - unset($row->field_expected_field_expected_value2); +/** + * Returns active nutrition participants for HC. + * + * @param int $health_center_id + * The Health center node ID. + * + * @return array + * Array with the participants details. + * + * @throws \Exception + */ +function hedley_stats_get_children_beneficiaries_individual_stats($health_center_id) { + $query = hedley_stats_get_base_query($health_center_id, 'individual_participant'); + + $field_names = [ + 'field_person', + 'field_encounter_type', + ]; + + foreach ($field_names as $field_name) { + hedley_general_join_field_to_query($query, 'node', $field_name); } - // Store in cache. - hedley_stats_handle_cache(HEDLEY_STATS_CACHE_SET, HEDLEY_STATS_SYNC_CHILDREN_BENEFICIARIES, $health_center_id, $period, array_values($result)); + $query->condition('field_encounter_type.field_encounter_type_value', 'nutrition'); - return array_values($result); + $result = $query + ->execute() + ->fetchAll(); + + $items = []; + foreach ($result as $row) { + $child_wrapper = entity_metadata_wrapper('node', $row->field_person); + $birth_date = $child_wrapper->field_birth_date->value(); + + if (empty($birth_date)) { + // Child got no birthdate set. We can't process + // it's data on client, so we skip it. + continue; + } + + // Child graduates at age of 13. + $graduation_date = strtotime('+13 years', $birth_date); + + $items[] = [ + 'created' => hedley_stats_convert_timestamp_to_nominal($row->created), + 'id' => $child_wrapper->getIdentifier(), + 'name' => $child_wrapper->label(), + 'birth_date' => hedley_stats_convert_timestamp_to_nominal($birth_date), + 'gender' => $child_wrapper->field_gender->value(), + 'graduation_date' => hedley_stats_convert_timestamp_to_nominal($graduation_date), + // No need to provide mother details, because we do not present + // it anywhere, when it comes to individual participants data. + 'mother_name' => '', + 'phone_number' => '', + ]; + } + + return $items; } /** @@ -405,12 +853,12 @@ function hedley_stats_get_family_planning_stats_by_period($health_center_id, $pe $query = hedley_stats_get_base_query($health_center_id, 'family_planning', $period); // Join `Signs` field (e.g. Pill, Condoms, etc'). - hedley_stats_join_field_to_query($query, 'node', 'field_family_planning_signs'); + hedley_general_join_field_to_query($query, 'node', 'field_family_planning_signs'); // Get the group type. - hedley_stats_join_field_to_query($query, 'node', 'field_session'); - hedley_stats_join_field_to_query($query, 'node', 'field_clinic', TRUE, "field_session.field_session_target_id"); - hedley_stats_join_field_to_query($query, 'node', 'field_group_type', TRUE, "field_clinic.field_clinic_target_id"); + hedley_general_join_field_to_query($query, 'node', 'field_session'); + hedley_general_join_field_to_query($query, 'node', 'field_clinic', TRUE, "field_session.field_session_target_id"); + hedley_general_join_field_to_query($query, 'node', 'field_group_type', TRUE, "field_clinic.field_clinic_target_id"); // Only FBF groups. $query->condition('field_group_type.field_group_type_value', 'fbf'); @@ -676,10 +1124,10 @@ function hedley_stats_get_total_encounters_by_clinic_type($health_center_id, $cl foreach ($queries as $key => $query) { // Get the group type. - hedley_stats_join_field_to_query($query, 'node', 'field_session'); - hedley_stats_join_field_to_query($query, 'node', 'field_attended'); - hedley_stats_join_field_to_query($query, 'node', 'field_clinic', TRUE, 'field_session.field_session_target_id'); - hedley_stats_join_field_to_query($query, 'node', 'field_group_type', TRUE, 'field_clinic.field_clinic_target_id'); + hedley_general_join_field_to_query($query, 'node', 'field_session'); + hedley_general_join_field_to_query($query, 'node', 'field_attended'); + hedley_general_join_field_to_query($query, 'node', 'field_clinic', TRUE, 'field_session.field_session_target_id'); + hedley_general_join_field_to_query($query, 'node', 'field_group_type', TRUE, 'field_clinic.field_clinic_target_id'); // Only participants who actually attended the sessions. $query->condition('field_attended.field_attended_value', TRUE); @@ -689,7 +1137,7 @@ function hedley_stats_get_total_encounters_by_clinic_type($health_center_id, $cl // If patients list specified values. if (is_array($patients_ids)) { - hedley_stats_join_field_to_query($query, 'node', 'field_person'); + hedley_general_join_field_to_query($query, 'node', 'field_person'); $query->condition('field_person.field_person_target_id', $patients_ids, 'IN'); } @@ -734,8 +1182,8 @@ function hedley_stats_get_total_nutrition_encounters($health_center_id, $patient foreach ($queries as $key => $query) { // If patients list specified values. if (is_array($patients_ids)) { - hedley_stats_join_field_to_query($query, 'node', 'field_individual_participant'); - hedley_stats_join_field_to_query($query, 'node', 'field_person', TRUE, 'field_individual_participant.field_individual_participant_target_id'); + hedley_general_join_field_to_query($query, 'node', 'field_individual_participant'); + hedley_general_join_field_to_query($query, 'node', 'field_person', TRUE, 'field_individual_participant.field_individual_participant_target_id'); $query->condition('field_person.field_person_target_id', $patients_ids, 'IN'); } @@ -975,6 +1423,7 @@ function hedley_stats_get_all_clinic_types() { HEDLEY_PERSON_CLINIC_TYPE_PMTCT, HEDLEY_PERSON_CLINIC_TYPE_SORWATHE, HEDLEY_PERSON_CLINIC_TYPE_ACHI, + HEDLEY_PERSON_CLINIC_TYPE_CHW, ]; } @@ -1045,21 +1494,21 @@ function hedley_stats_get_nutrition_measurements_for_clinic_type_grouped_by_pers $query = hedley_stats_get_base_query($health_center_id, array_keys($node_types), $period, $extend); // Get the group type. - hedley_stats_join_field_to_query($query, 'node', 'field_session'); - hedley_stats_join_field_to_query($query, 'node', 'field_clinic', TRUE, 'field_session.field_session_target_id'); - hedley_stats_join_field_to_query($query, 'node', 'field_group_type', TRUE, 'field_clinic.field_clinic_target_id'); + hedley_general_join_field_to_query($query, 'node', 'field_session'); + hedley_general_join_field_to_query($query, 'node', 'field_clinic', TRUE, 'field_session.field_session_target_id'); + hedley_general_join_field_to_query($query, 'node', 'field_group_type', TRUE, 'field_clinic.field_clinic_target_id'); // Get the person. - hedley_stats_join_field_to_query($query, 'node', 'field_person'); + hedley_general_join_field_to_query($query, 'node', 'field_person'); // Get the nutrition signs for this person. - hedley_stats_join_field_to_query($query, 'node', 'field_nutrition_signs', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_nutrition_signs', FALSE); // Get all other measurements for this person. - hedley_stats_join_field_to_query($query, 'node', 'field_zscore_age', FALSE); - hedley_stats_join_field_to_query($query, 'node', 'field_muac', FALSE); - hedley_stats_join_field_to_query($query, 'node', 'field_zscore_length', FALSE); - hedley_stats_join_field_to_query($query, 'node', 'field_zscore_bmi', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_zscore_age', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_muac', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_zscore_length', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_zscore_bmi', FALSE); // Filter by clinic type. $query->condition('field_group_type.field_group_type_value', $clinic_type); @@ -1107,16 +1556,16 @@ function hedley_stats_get_nutrition_measurements_for_individual_encounters_group $query = hedley_stats_get_base_query($health_center_id, array_keys($node_types), $period, $extend); // Get the person. - hedley_stats_join_field_to_query($query, 'node', 'field_person'); + hedley_general_join_field_to_query($query, 'node', 'field_person'); // Get the nutrition signs for this person. - hedley_stats_join_field_to_query($query, 'node', 'field_nutrition_signs', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_nutrition_signs', FALSE); // Get all other measurements for this person. - hedley_stats_join_field_to_query($query, 'node', 'field_zscore_age', FALSE); - hedley_stats_join_field_to_query($query, 'node', 'field_muac', FALSE); - hedley_stats_join_field_to_query($query, 'node', 'field_zscore_length', FALSE); - hedley_stats_join_field_to_query($query, 'node', 'field_zscore_bmi', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_zscore_age', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_muac', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_zscore_length', FALSE); + hedley_general_join_field_to_query($query, 'node', 'field_zscore_bmi', FALSE); $result = $query ->execute() @@ -1137,14 +1586,14 @@ function hedley_stats_get_nutrition_measurements_for_individual_encounters_group } /** - * Base query for stats - pulls measurements in given period for Health Center. + * Base query for stats - pulls content in given period for Health Center. * * @param int $health_center_id * The Health center node ID. * @param string|array $node_type - * Either single measurement type or an array of types. + * Either single content type or an array of types. * @param string $period - * The period during which measurement was taken. + * Optional; The period during which content was taken. * @param bool $extend * Optional; If True, data goes back one more month for 'one year' period. * @@ -1153,41 +1602,57 @@ function hedley_stats_get_nutrition_measurements_for_individual_encounters_group * * @throws \Exception */ -function hedley_stats_get_base_query($health_center_id, $node_type, $period, $extend = FALSE) { +function hedley_stats_get_base_query($health_center_id, $node_type, $period = FALSE, $extend = FALSE) { $query = db_select('node', 'node'); $query->fields('node', ['nid', 'type', 'created']); - // For all measurement nodes, creation date is - // resolved using 'field_date_measured'. - $date_field = 'field_date_measured'; - - // If we're dealing with encounter, creation date is - // resolved using 'field_scheduled_date'. $encounter_types = [ 'acute_illness_encounter', 'nutrition_encounter', 'prenatal_encounter', ]; + $participant_types = [ + 'individual_participant', + 'pmtct_participant', + ]; + + // If we're dealing with encounter, creation date is + // resolved using 'field_scheduled_date'. if (in_array($node_type, $encounter_types)) { $date_field = 'field_scheduled_date'; + hedley_general_join_field_to_query($query, 'node', $date_field, FALSE, NULL, NULL, TRUE); + } + // If we're dealing with individual participant, creation date is + // resolved using 'field_expected'. + elseif (in_array($node_type, $participant_types)) { + $date_field = 'field_expected'; + hedley_general_join_field_to_query($query, 'node', $date_field, FALSE, NULL, NULL, TRUE); + } + // Dealing with measurements. + // For all measurement nodes, creation date is + // resolved using 'field_date_measured'. + else { + $date_field = 'field_date_measured'; + hedley_general_join_field_to_query($query, 'node', $date_field); } - - hedley_stats_join_field_to_query($query, 'node', $date_field); - $date_field_name = $date_field . '.' . $date_field . '_value'; // All nodes have the Health center info under `field_shards`. $health_center_field = 'field_shards'; // Filter by health center. - hedley_stats_join_field_to_query($query, 'node', $health_center_field); + hedley_general_join_field_to_query($query, 'node', $health_center_field); $health_center_field_name = $health_center_field . '.' . $health_center_field . '_target_id'; $query->condition($health_center_field_name, $health_center_id); - $date = hedley_stats_get_period($period, $extend); - $query->condition($date_field_name, [ - $date['start'], - $date['end'], - ], 'BETWEEN'); + if ($period) { + $date_field_name = $date_field . '.' . $date_field . '_value'; + + $date = hedley_stats_get_period($period, $extend); + $query->condition($date_field_name, [ + $date['start'], + $date['end'], + ], 'BETWEEN'); + } $node_type_operator = is_array($node_type) ? 'IN' : '='; $query @@ -1278,62 +1743,20 @@ function hedley_stats_get_range_for_period($period, $extend = FALSE) { 'start' => strtotime("last day of -2 years") + $one_day, 'end' => strtotime("last day of -1 year") + $one_day, ]; - } -} -/** - * Join a field to a DB Select query, and add its main value. - * - * @param SelectQuery $query - * Query to join to. - * @param string $entity_type - * Type of the host entity of the field. Or NULL to avoid filtering the field - * table by entity type. - * @param string $field_name - * Field name. - * @param bool $require - * Whether filter out rows where this field would be NULL. - * @param string $entity_id_selector - * SQL selector for the column by which the field is joined. The entity ID is - * used by default. - * - * @throws Exception - */ -function hedley_stats_join_field_to_query(SelectQuery $query, $entity_type, $field_name, $require = TRUE, $entity_id_selector = NULL) { - $field = field_info_field($field_name); - $table_name = _field_sql_storage_tablename($field); + case HEDLEY_STATS_PERIOD_480_DAYS: + return [ + 'start' => strtotime("-480 days"), + 'end' => $now + $one_day, + ]; - if (!$entity_id_selector) { - if (!$entity_type) { - throw new Exception('Entity type is required when ID selector is not specified'); - } - // Set default entity ID selector. - switch ($entity_type) { - case 'user': - $entity_id_selector = 'users.uid'; - break; - - case 'node': - $entity_id_selector = 'node.nid'; - break; - - default: - throw new Exception(format_string('hedley_general_join_field_to_query() is not implemented for entity_type: "@type"', ['@type' => $entity_type])); - } - } + case HEDLEY_STATS_PERIOD_PAST_SIX_MONTHS: + return [ + 'start' => strtotime("first day of -5 months"), + 'end' => $now + $one_day, + ]; - $join = $require ? 'innerJoin' : 'leftJoin'; - $arguments = [':type' => $entity_type]; - $conditions[] = "$entity_id_selector = $field_name.entity_id"; - if ($entity_type) { - $conditions[] = "$field_name.entity_type = :type"; } - - $query->$join($table_name, $field_name, implode(' AND ', $conditions), $arguments); - - $column_suffix = $field['type'] == 'entityreference' ? 'target_id' : 'value'; - - $query->addField($field_name, $field_name . '_' . $column_suffix, $field_name); } /** diff --git a/server/hedley/modules/custom/hedley_stats/scripts/recalculate-stats.php b/server/hedley/modules/custom/hedley_stats/scripts/recalculate-stats.php index bbcf734780..adebb4b64c 100644 --- a/server/hedley/modules/custom/hedley_stats/scripts/recalculate-stats.php +++ b/server/hedley/modules/custom/hedley_stats/scripts/recalculate-stats.php @@ -61,7 +61,9 @@ $ids = array_keys($result['node']); foreach ($ids as $id) { - hedley_stats_clear_caches_for_health_center($id); + hedley_stats_clear_caches_for_health_center($id, HEDLEY_STATS_NUTRITION); + hedley_stats_clear_caches_for_health_center($id, HEDLEY_STATS_PRENATAL); + hedley_stats_clear_caches_for_health_center($id, HEDLEY_STATS_ACUTE_ILLNESS_ENCOUNTER_TYPE); // Add AQ item to re-calculate all the stats offline. hedley_general_add_task_to_advanced_queue_by_id(HEDLEY_STATS_CALCULATE_STATS, $id, [ diff --git a/server/install b/server/install index 94fad2795a..eb6a4f8906 100755 --- a/server/install +++ b/server/install @@ -5,7 +5,7 @@ # This script will setup a local copy of Drupal 7 # based on the Installation Profile. # -# Do not change the content of this file, +# Do not change the content of this file, # all configuration variables are in the config.sh file. # ################################################################################ @@ -136,7 +136,6 @@ drupal_make # Symlink extra modules (if any). symlink_externals - # Install the Drupal profile as defined in the config.sh file. install_drupal_profile