[TOB-219] feat: Add selection of parent statements to workflow form

* Change API statement search interfaces for pagination
* Add pagination to statement search in store
* Include parents when fetching statement details
* Add a component for list of statements
* Add data mocks for testing
* Open collapsibles if content is focused
* Reorganize translations
* Integrate statement select in workflow data form

[TOB-211] feat: Add selection of contact information to info form

* Display zero instead of null in comments component
* Add property contactId to IAPIStatementModel
* Add property contactId to statement info form value
* Add directive to assign css class on invalid form controls
* Add components for pagination and contact data
* Reorganize forms into feature modules
* Extend task complete action to claim next camunda task
* Add back end calls for contact data
* Add utility functions for store reducers
* Add store effects for searching and fetching contact data
* Add store effect for opening contact base data module in new tab
* Integrate contact selection in info form

[TOB-246] feat: Add attachment controls to info form

* Add new back end calls for attachments and remove old code
* Add store module for attachments
* Extend store for fetching and uploading attachments
* Reorganize statement store and adjust submit effect
* Add further utility functions for store reducers
* Add action and effect to open attachments
* Include attachments when fetching statement details
* Add UI components for attachment control
* Change main overflow property to scroll

[TOB-277] feat: Display affected business section to info form

* Add back end calls for avaialable business sections
* Add action and effects for fetching business sections from back end
* Add Integrate into info form
* Fetch settings when visiting new statement form

[TOB-260] test: Increase test coverage

* Add tests for setting reducers
* Add tests for root reducers
* Add tests for process reducers
* Change style to avoid jumping text blocks

Signed-off-by: Christopher Keim <keim@develop-group.de>
288 files changed
tree: 960a8e2e1dd91fd0b104f1bc7908e6520fdc1cb5
  1. .storybook/
  2. scripts/
  3. src/
  4. .editorconfig
  5. .gitignore
  6. .huskyrc.json
  7. .stylelintrc.json
  8. angular.json
  9. browserslist
  10. karma.conf.js
  11. LICENSE.md
  12. NOTICE.md
  13. package-lock.json
  14. package.json
  15. proxy.conf.json
  16. README.md
  17. sonar-project.properties
  18. tsconfig.app.json
  19. tsconfig.json
  20. tsconfig.spec.json
  21. tslint.json
README.md

Eclipse openK User Modules - Statement Public Affairs Frontend

This application represents a user module for the Eclipse openK User Modules project.

Prerequisites

With npm in the path variable, run first npm install to download and install all dependencies of this module. After that, all npm scripts for deploying, developing and testing are available.

Additionally, archiving the build as WAR file requires also the Java Archiver command line tool in the path variable.

Configuration

The whole application can be configured via certain properties in the ./package.json. The following options are available:

  • routes.spaFrontend: Route on which the website is served
  • routes.spaBackend: Route on which the website's backend is served
  • routes.portal: Route on which the main portal is served

Changes to these properties take only effect after rebuilding the application.

Build

Building the application is done via the Angular CLI or by the provided scripts in the ./package.json (which also provide all necessary configuration steps):

  • npm run build Build the application via the Angular CLI to the ./dist/statement-public-affairs folder
  • npm run archive Archive the build as WAR file to ./dist/statement-public-affairs-frontend.war

Note that the archiving script requires the Java Archiver (jar) command line tool in the path variable.

Development

Run npm run start for setting up a local dev server which is served on http://localhost:4200/. The local dev server is also a proxy which can be configured by the file ./proxy.conf.json. It redirects all calls to the back end to a specific location.

Run npm run test to execute all tests via Karma and Jasmine. This also sets up a local dev server with live reload.

Run npm run test:report instead to generate a coverage report at the folder ./coverage/statement-public-affairs.

Run npm run lint for linting all source files, both typescript and (s)css code.

Run npm run lint:report to generate instead linting report files at ./lint.ts.report.json and ./lint.styles.report.json.

Run npm run sonar to upload the test and linting reports to a sonarqube instance via the sonar-scanner. This can be configured either by the ./sonar-projects.properties file or by arguments on the command line. For example, uploading the reports to a different port can be done via:

npm run sonar -- -Dsonar.host.url=http://localhost:9001

Storybook

Run start:storybook for setting up a local storybook server.

Run build:storybook instead for building the storybook webpage for later use.

Miscellaneous Scripts

Run npm run list-licenses to generate a listing of all packages and their licenses used for production. A file is created at ./licenses.txt. The content of this file is required in the ./NOTICE.md file.

Run npm run check-legal-headers to check if all source files have a specific legal header.

Git Hooks

Run npm run pre-commit to check if a commit passes the pre-commit script. This script concatenates npm run lint and npm run check-legal-headers.