The Capture app serves as a replacement for the Event Capture app. In the future, the intention is to incorporate the Tracker Capture app and the Data Entry app into the Capture app.
In the Capture app you register events that occurred at a particular time and place. An event can happen at any given point in time. This stands in contrast to routine data, which can be captured for predefined, regular intervals. Events are sometimes called cases or records. In DHIS2, events are linked to a program. The Capture app lets you select the organisation unit and program and specify a date when a event happened, before entering information for the event.
Find the official documentation of the Capture app here.
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
What things you need to install and how to install them.
You can download and install Node on your machine from here.
You can find a tutorial on how to install git
on your machine here.
You can install yarn 1
on your machine following the instructions here.
Step by step instructions for setting up a development environment.
Clone with SSH
git clone [email protected]:dhis2/capture-app.git
Clone with HTTPS
git clone https://github.com/dhis2/capture-app.git
To install the dependencies you will have to be at the source folder of the cloned repository. Then run:
yarn
Read about cross-site cookies and DHIS2 applications here
To start the application locally and interact with it in the browser, run:
yarn start
http://localhost:3000
should automatically open in your browser.
You will be prompted for a path to the server instance, a user name and a password.
The path to the server instance can also be set by supplying a .env.development.local
file in the root folder of the project. An example of an .env.development.local
file:
REACT_APP_DHIS2_BASE_URL="http://localhost:8080"
To run Cypress tests locally on your own machine, follow the instructions here.
To record tests in Cypress Cloud, you can use one of the following methods based on your needs:
- Commit Message: Include
[e2e record]
in your commit messages to activate recording. - GitHub Labels: Apply the
e2e record
label to your pull request to trigger recording.
This setup helps in managing Cypress Cloud credits more efficiently, ensuring recordings are only made when explicitly required.
This project was bootstrapped with Create React App.
We use Conventional Commits as convention for our commit messages.
This project is licensed under the BSD 2-Clause License - see the LICENSE.md file for details