Skip to content

Commit

Permalink
Merge pull request #1175 from TIP-Global-Health/develop
Browse files Browse the repository at this point in the history
Developments starting May 19, 2024
  • Loading branch information
anvmn authored Jun 18, 2024
2 parents 6aecf27 + 3304023 commit 5cd4ad1
Show file tree
Hide file tree
Showing 49 changed files with 1,576 additions and 380 deletions.
1 change: 0 additions & 1 deletion .ddev/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
/.dbimageExtra
/.ddev-docker-*.yaml
/.*downloads
/.global_commands
/.homeadditions
/.importdb*
/.sshimageBuild
Expand Down
1 change: 1 addition & 0 deletions .ddev/commands/web/client-install
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ npm install -g bower
cd ../../client
npm install --no-audit --no-fund
bower install
npm rebuild node-sass
1 change: 1 addition & 0 deletions .ddev/commands/web/gulp
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,5 @@ then
cp ../../eheza-infra/elm/${EHEZA_SITE}/Config.Deploy.elm ${CLIENT_PATH}/src/elm/
fi

export TZ=Europe/Budapest
cd ../../client && gulp $@
20 changes: 13 additions & 7 deletions .ddev/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,22 @@ use_dns_when_possible: true
composer_version: "1"
web_environment: []
nodejs_version: "16"
corepack_enable: false
ddev_version_constraint: '>= 1.23'

# Key features of DDEV's config.yaml:

# name: <projectname> # Name of the project, automatically provides
# http://projectname.ddev.site and https://projectname.ddev.site

# type: <projecttype> # backdrop, craftcms, django4, drupal6/7/8/9/10, laravel, magento, magento2, php, python, shopware6, silverstripe, typo3, wordpress
# See https://ddev.readthedocs.io/en/latest/users/quickstart/ for more
# type: <projecttype> # backdrop, craftcms, django4, drupal, drupal6, drupal7, laravel, magento, magento2, php, python, shopware6, silverstripe, typo3, wordpress
# See https://ddev.readthedocs.io/en/stable/users/quickstart/ for more
# information on the different project types
# "drupal" covers recent Drupal 8+

# docroot: <relative_path> # Relative path to the directory containing index.php.

# php_version: "8.1" # PHP version to use, "5.6", "7.0", "7.1", "7.2", "7.3", "7.4", "8.0", "8.1", "8.2", "8.3"
# php_version: "8.2" # PHP version to use, "5.6", "7.0", "7.1", "7.2", "7.3", "7.4", "8.0", "8.1", "8.2", "8.3"

# You can explicitly specify the webimage but this
# is not recommended, as the images are often closely tied to DDEV's' behavior,
Expand All @@ -37,7 +40,7 @@ nodejs_version: "16"

# database:
# type: <dbtype> # mysql, mariadb, postgres
# version: <version> # database version, like "10.4" or "8.0"
# version: <version> # database version, like "10.11" or "8.0"
# MariaDB versions can be 5.5-10.8 and 10.11, MySQL versions can be 5.5-8.0
# PostgreSQL versions can be 9-16.

Expand Down Expand Up @@ -78,7 +81,7 @@ nodejs_version: "16"
# Alternatively, an explicit Composer version may be specified, for example "2.2.18".
# To reinstall Composer after the image was built, run "ddev debug refresh".

# nodejs_version: "18"
# nodejs_version: "20"
# change from the default system Node.js version to any other version.
# Numeric version numbers can be complete (i.e. 18.15.0) or
# incomplete (18, 17.2, 16). 'lts' and 'latest' can be used as well along with
Expand All @@ -87,6 +90,9 @@ nodejs_version: "16"
# Note that you can continue using 'ddev nvm' or nvm inside the web container
# to change the project's installed node version if you need to.

# corepack_enable: false
# Change to 'true' to 'corepack enable' and gain access to latest versions of yarn/pnpm

# additional_hostnames:
# - somename
# - someothername
Expand Down Expand Up @@ -144,8 +150,8 @@ nodejs_version: "16"
# - "mutagen": enables Mutagen for this project.
# - "nfs": enables NFS for this project.
#
# See https://ddev.readthedocs.io/en/latest/users/install/performance/#nfs
# See https://ddev.readthedocs.io/en/latest/users/install/performance/#mutagen
# See https://ddev.readthedocs.io/en/stable/users/install/performance/#nfs
# See https://ddev.readthedocs.io/en/stable/users/install/performance/#mutagen

# fail_on_hook_fail: False
# Decide whether 'ddev start' should be interrupted by a failing hook
Expand Down
15 changes: 14 additions & 1 deletion .ddev/web-build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,20 @@
ARG BASE_IMAGE
FROM $BASE_IMAGE

RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y -o Dpkg::Options::="--force-confold" --no-install-recommends --no-install-suggests inotify-tools python2.7 build-essential
RUN apt-get update || true
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y -o Dpkg::Options::="--force-confold" --no-install-recommends --no-install-suggests inotify-tools build-essential mime-support

# Download and install Python 2.7 and dependencies from Debian 11 (Bullseye)
ADD https://deb.debian.org/debian/pool/main/libf/libffi/libffi7_3.3-6_amd64.deb /tmp/
ADD https://deb.debian.org/debian/pool/main/o/openssl/libssl1.1_1.1.1w-0+deb11u1_amd64.deb /tmp/
ADD https://deb.debian.org/debian/pool/main/p/python2.7/libpython2.7-minimal_2.7.18-8+deb11u1_amd64.deb /tmp/
ADD https://deb.debian.org/debian/pool/main/p/python2.7/python2.7-minimal_2.7.18-8+deb11u1_amd64.deb /tmp/
ADD https://deb.debian.org/debian/pool/main/p/python2.7/libpython2.7-stdlib_2.7.18-8+deb11u1_amd64.deb /tmp/
ADD https://deb.debian.org/debian/pool/main/p/python2.7/python2.7_2.7.18-8+deb11u1_amd64.deb /tmp/

# Install the downloaded packages
RUN dpkg -i /tmp/*.deb && rm /tmp/*.deb

RUN update-alternatives --install /usr/bin/python python /usr/bin/python2.7 1
# Elm - directly downloading the binary.
RUN wget https://github.com/elm/compiler/releases/download/0.19.1/binary-for-linux-64-bit.gz
Expand Down
2 changes: 1 addition & 1 deletion ci-scripts/circleci_wait.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

CMD="$*"

TIMEOUT=2700
TIMEOUT=3700
INTERVAL=240
$CMD &
CMD_PID=$!
Expand Down
2 changes: 1 addition & 1 deletion ci-scripts/install_ddev.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ then
fi

echo "Install ddev."
curl -s -L https://raw.githubusercontent.com/drud/ddev/master/scripts/install_ddev.sh | bash -s v1.22.7
curl -s -L https://raw.githubusercontent.com/drud/ddev/master/scripts/install_ddev.sh | bash -s v1.23.1

echo "Configuring ddev."
mkdir ~/.ddev
Expand Down
46 changes: 26 additions & 20 deletions client/elm.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,34 +9,34 @@
"direct": {
"Gizra/elm-all-set": "1.0.1",
"Gizra/elm-debouncer": "2.0.0",
"NoRedInk/elm-json-decode-pipeline": "1.0.0",
"NoRedInk/elm-json-decode-pipeline": "1.0.1",
"avh4/elm-color": "1.0.0",
"ccapndave/elm-update-extra": "4.0.0",
"elm/browser": "1.0.1",
"elm/core": "1.0.0",
"elm/browser": "1.0.2",
"elm/core": "1.0.5",
"elm/html": "1.0.0",
"elm/http": "1.0.0",
"elm/json": "1.1.3",
"elm/regex": "1.0.0",
"elm/svg": "1.0.1",
"elm/time": "1.0.0",
"elm/url": "1.0.0",
"elm-community/json-extra": "4.0.0",
"elm-community/list-extra": "8.1.0",
"elm-community/json-extra": "4.3.0",
"elm-community/list-extra": "8.7.0",
"elm-community/maybe-extra": "5.3.0",
"elm-community/string-extra": "4.0.1",
"elm-community/typed-svg": "5.1.0",
"elm-explorations/test": "1.2.1",
"elm-community/typed-svg": "7.0.0",
"elm-explorations/test": "1.2.2",
"etaque/elm-form": "4.0.0",
"folkertdev/one-true-path-experiment": "4.0.3",
"gampleman/elm-visualization": "2.0.1",
"hecrj/html-parser": "2.3.4",
"folkertdev/one-true-path-experiment": "6.0.0",
"gampleman/elm-visualization": "2.4.1",
"hecrj/html-parser": "2.4.0",
"ianmackenzie/elm-float-extra": "1.1.0",
"justinmimbs/date": "3.2.1",
"justinmimbs/time-extra": "1.1.0",
"justinmimbs/date": "4.1.0",
"justinmimbs/time-extra": "1.2.0",
"krisajenkins/remotedata": "5.0.0",
"lukewestby/elm-http-builder": "6.0.0",
"myrho/elm-round": "1.0.4",
"myrho/elm-round": "1.0.5",
"stoeffel/editable": "2.0.1",
"truqu/elm-base64": "2.0.4",
"truqu/elm-md5": "1.1.0",
Expand All @@ -45,16 +45,22 @@
"indirect": {
"elm/parser": "1.1.0",
"elm/random": "1.0.0",
"elm/virtual-dom": "1.0.2",
"elm/virtual-dom": "1.0.3",
"elmcraft/core-extra": "2.0.0",
"folkertdev/elm-deque": "3.0.1",
"folkertdev/svg-path-lowlevel": "3.0.0",
"ianmackenzie/elm-geometry": "1.2.1",
"ianmackenzie/elm-interval": "1.0.1",
"ianmackenzie/elm-triangular-mesh": "1.0.2",
"folkertdev/svg-path-lowlevel": "4.0.1",
"gampleman/elm-rosetree": "1.1.0",
"ianmackenzie/elm-1d-parameter": "1.0.1",
"ianmackenzie/elm-geometry": "3.11.0",
"ianmackenzie/elm-interval": "3.1.0",
"ianmackenzie/elm-triangular-mesh": "1.1.0",
"ianmackenzie/elm-units": "2.10.0",
"ianmackenzie/elm-units-interval": "3.2.0",
"ianmackenzie/elm-units-prefixed": "2.8.0",
"pzp1997/assoc-list": "1.0.0",
"rtfeldman/elm-hex": "1.0.0",
"rtfeldman/elm-iso8601-date-strings": "1.1.3",
"ryannhg/date-format": "2.3.0",
"rtfeldman/elm-iso8601-date-strings": "1.1.4",
"ryan-haskell/date-format": "1.0.0",
"zwilias/elm-utf-tools": "2.0.1"
}
},
Expand Down
10 changes: 5 additions & 5 deletions client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions client/src/assets/scss/_new.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5135,6 +5135,20 @@ div.page-activity.messaging-center {
margin-bottom: 20px;
}
}

.ui.report.unstackable.items .guide-message {
background: $color-white;
padding: 30px 25px 30px 25px;
color: $color-text;

.title {
font-weight: bold;

&.note {
font-style: italic;
}
}
}
}

div.dashboard,
Expand Down
9 changes: 6 additions & 3 deletions client/src/elm/Backend/Measurement/Decoder.elm
Original file line number Diff line number Diff line change
Expand Up @@ -475,8 +475,8 @@ decodePrenatalFollowUpValue : Decoder PrenatalFollowUpValue
decodePrenatalFollowUpValue =
succeed PrenatalFollowUpValue
|> required "follow_up_options" (decodeEverySet decodeFollowUpOption)
|> required "prenatal_assesment" decodePrenatalAssesment
|> optional "date_concluded" (nullable Gizra.NominalDate.decodeYYYYMMDD) Nothing
|> required "prenatal_assesment" decodePrenatalAssesment


decodePrenatalAssesment : Decoder PrenatalAssesment
Expand Down Expand Up @@ -2471,8 +2471,8 @@ decodeNutritionFollowUpValue : Decoder NutritionFollowUpValue
decodeNutritionFollowUpValue =
succeed NutritionFollowUpValue
|> required "follow_up_options" (decodeEverySet decodeFollowUpOption)
|> custom decodeNutritionAssessment
|> optional "date_concluded" (nullable Gizra.NominalDate.decodeYYYYMMDD) Nothing
|> custom decodeNutritionAssessment


decodeAcuteIllnessFollowUp : Decoder AcuteIllnessFollowUp
Expand All @@ -2484,8 +2484,8 @@ decodeAcuteIllnessFollowUpValue : Decoder AcuteIllnessFollowUpValue
decodeAcuteIllnessFollowUpValue =
succeed AcuteIllnessFollowUpValue
|> required "follow_up_options" (decodeEverySet decodeFollowUpOption)
|> optional "acute_illness_diagnosis" (nullable decodeAcuteIllnessDiagnosis) Nothing
|> optional "date_concluded" (nullable Gizra.NominalDate.decodeYYYYMMDD) Nothing
|> optional "acute_illness_diagnosis" (nullable decodeAcuteIllnessDiagnosis) Nothing


decodeNutritionFeeding : Decoder NutritionFeeding
Expand Down Expand Up @@ -3360,6 +3360,9 @@ decodeFollowUpOption =
"3-m" ->
succeed ThreeMonths

"none" ->
succeed FollowUpNotNeeded

_ ->
fail <|
sign
Expand Down
3 changes: 3 additions & 0 deletions client/src/elm/Backend/Measurement/Encoder.elm
Original file line number Diff line number Diff line change
Expand Up @@ -2423,6 +2423,9 @@ encodeFollowUpOption option =
ThreeMonths ->
"3-m"

FollowUpNotNeeded ->
"none"


encodeNutritionFeeding : NutritionFeeding -> List ( String, Value )
encodeNutritionFeeding =
Expand Down
7 changes: 4 additions & 3 deletions client/src/elm/Backend/Measurement/Model.elm
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,8 @@ type alias FollowUp =

type alias NutritionFollowUpValue =
{ options : EverySet FollowUpOption
, assesment : EverySet NutritionAssessment
, resolutionDate : Maybe NominalDate
, assesment : EverySet NutritionAssessment
}


Expand Down Expand Up @@ -276,6 +276,7 @@ type FollowUpOption
| OneMonth
| TwoMonths
| ThreeMonths
| FollowUpNotNeeded


type alias GroupNCDA =
Expand Down Expand Up @@ -970,8 +971,8 @@ type alias PrenatalFollowUp =

type alias PrenatalFollowUpValue =
{ options : EverySet FollowUpOption
, assesment : PrenatalAssesment
, resolutionDate : Maybe NominalDate
, assesment : PrenatalAssesment
}


Expand Down Expand Up @@ -2135,8 +2136,8 @@ type alias AcuteIllnessFollowUp =

type alias AcuteIllnessFollowUpValue =
{ options : EverySet FollowUpOption
, diagnosis : Maybe AcuteIllnessDiagnosis
, resolutionDate : Maybe NominalDate
, diagnosis : Maybe AcuteIllnessDiagnosis
}


Expand Down
6 changes: 4 additions & 2 deletions client/src/elm/Backend/ResilienceSurvey/Model.elm
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ type alias ResilienceSurvey =


type ResilienceSurveyType
= ResilienceSurveyMonthly
| ResilienceSurveyQuaterly
= ResilienceSurveyQuarterly
| ResilienceSurveyAdoption


type ResilienceSurveyQuestion
Expand All @@ -30,6 +30,8 @@ type ResilienceSurveyQuestion
| ResilienceSurveyQuestion8
| ResilienceSurveyQuestion9
| ResilienceSurveyQuestion10
| ResilienceSurveyQuestion11
| ResilienceSurveyQuestion12


type ResilienceSurveyQuestionOption
Expand Down
Loading

0 comments on commit 5cd4ad1

Please sign in to comment.