Skip to content

Latest commit

 

History

721 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Water Abstraction Licence Extractor

Pre-reqs

  • Have Brew installed
  • Install npm (can do via Brew)
  • Install dotnet
  • Run the following to install Tesseract;

brew install tesseract

  • Have an instance of PostgreSQL running, e.g.
docker run -d \
 --name postgres-dev \
 -e POSTGRES_PASSWORD=EnvironmentAgency1 \
 -e POSTGRES_USER=ea \
 -e POSTGRES_DB=wale \
 -p 5432:5432 \
 -v postgres-data:/var/lib/postgresql \
 postgres:18

Example 'PostgresConnectionString' app settings; "POSTGRESQL_HOST": "localhost", "POSTGRESQL_PORT": "5432", "POSTGRESQL_DBNAME": "wale", "POSTGRESQL_USERNAME": "ea", "POSTGRESQL_PASSWORD": "EnvironmentAgency1"

To run migrations, use the WALE.Tools.Database.PostgreSQL.MigrationRunner tool

Generating TypeScript client

(Requires NSwag CLI to be installed on your machine - dotnet tool install --global NSwag.ConsoleCore) This codegen is used to generate a TypeScript client for the API, so that we can easily consume it from the frontend.

  • Run the WALE.Api project
  • Open a terminal in the following directory:
    • /WALE.Portal/src/api/generated:
  • Run this command:
    • dotnet nswag openapi2tsclient /input:http://localhost:8080/openapi/v1.json /output:apiClient.ts

Running the web portal

(Requires Node.js to be installed on your machine)

  • Run the WALE.Api project – this is the backend for the web portal
  • Open a terminal in the WALE.Portal directory
  • Run npm install (only needs to be done once)
  • Run npm run dev

About

Extraction tools for retrieving structured data in water licences

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages