/qwat-data-model

TEKSI Water module (project QWAT) - PostgreSQL / postgis Datamodel

Primary LanguageHTML

qwat-data-model

Build Status

This repository contains the definition of the data model used by QWAT project, a module aimed at managing a water network in QGIS.

A full web data model documentation with diagrams and relations is available here.

Model changelog (Detailed)

  • v1.3.6 : Add sia405 mapping fields for interlis Export
  • v1.3.5 : Minors typo fixes #314 #315
  • v1.3.4 : Remove SIRE from core, add value list for valve nominal diameter
  • v1.3.3 : Support for customizations
  • v1.3.2 : SIRE extension and infrastructure enhancements
  • v1.3.1 : fix z computation logic for valves
  • v1.3.0 : Switch from custom version control to generic Postgres Update Manager
  • v1.2.8 : add hardcoded schema_visible field to pipes and valves for enhanced performance on QGIS
  • v1.2.7 : AutoPrint Mapview
  • v1.2.6 : Fixes issue 177. Pipes were not audited by audit log system.
  • V1.2.5 : Adds a scale field to print maps
  • v1.2.4 : Fixes bugs when deleting objects qwat/QWAT#174
  • v1.2.2 : Integrates the new audit history system. Fixes an issue with multiple primary keys in conformity check procedure
  • v1.2.1 : Allow installation type change (done in trigger function generated by submodule meta-project generator).
  • v1.2.0 : Simplification of the trigger on views, ie there are no more triggers in cascade generated by the inheritance model. That modification does not affect the data-model code, but the change deserves a change in QWAT version number.
  • v1.1.1 : Adds the ability to use post delta files to check auto generated triggers in model
  • v1.1.0 : Remove valve inheritance from nodes.
  • v1.0.1 : Add functionnal to vl status (meaning the object is ready to be used). This is useful to allow finer printing (print inactive but functional objects)
  • v1.0.0 : First version (3 june 2016)
  • v0.1 : Proof of concept model

Release

Realeases are made using github actions when a new release is created. The tag must be of format x.y.z.

Tests

Tests are run automatically on commit by github actions.

To run them locally (please refer to run_tests.yml for up to date steps):

# start a dev postgis server
docker run --rm -d -p 5432:5432 -e POSTGRES_DB=qwat_test -e POSTGRES_PASSWORD=postgres --name=qwat_test_db postgis/postgis:9.6-2.5

# include the pgservices for test database
cat ./tests/pg_service.conf >> ~/.pg_service.conf

# install dependencies
pip install -r requirements.txt

# run tests
tests/tests.sh