Skip to content

icrc-loliveira/openmrs-module-coreapps

 
 

Repository files navigation

Build Status Codacy Badge dependencies Status devDependencies Status

OpenMRS Core Apps Module

Provides apps for performing the common tasks

Development

Hot reloading changes is supported. Use the following three commands:

mvn openmrs-sdk:watch
mvn process-resources -Pwatch-sass
npm run watch

Dashboard Widgets

The widgets are built as part of the module (mvn clean install) without having to install Node or NPM manually. Nevertheless, if you want to develop widgets installing Node is recommended so that you can iterate faster by building widgets and executing tests continuously.

You need to have Node 6.x installed. We recommend using nvm or nvm-windows to install Node.

The code is at omod/src/main/web

The generated code is at omod/target/classes/web/module/resources/scripts/web

Installing dependencies: npm install --no-optional (once after code checkout or when dependencies change)

Development build: npm run build:dev

Continuous development build: npm run watch (whenever you make a change, a new UI build will be triggered)

Continuous test execution: npm run test:dev (in PhantomJS), npm run test:dev-chrome (in Chrome), npm run test:dev-firefox (in Firefox) (whenever you make a change, tests will be run again)

Clean development build: npm run clean && npm run build:dev

Production build: npm run build

For continuous development we recommend setting up a server using OpenMRS SDK and adding the coreapps module to watched projects (requires UI Framework 3.12.0+). Next start the server and use the npm run watch command to have js code instantly transpiled and deployed to the server. Do remember to disable caching for your browser or use Ctrl + F5 to refresh page and its cache to see changes.

Linking

Linking is a feature of npm, which allows you to modify a library and test modifications in your project.

  1. Clone https://github.com/openmrs/openmrs-web-angularjs-api
  2. Run npm link and npm run build from the lib directory
  3. Run npm link @openmrs/angularjs-openmrs-api from the coreapps project directory.
  4. Build the coreapps project.

In order to unlink do:

  1. Run npm unlink @openmrs/angularjs-openmrs-api and npm install from the coreapps project directory.
  2. Build the coreapps project.

About

Provides apps for performing the common tasks

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 46.7%
  • JavaScript 29.6%
  • Groovy 19.8%
  • HTML 2.4%
  • SCSS 1.4%
  • Ruby 0.1%