diff --git a/resources/sql/queries.auto.sql b/resources/sql/queries.auto.sql index 3e66e95..d114489 100644 --- a/resources/sql/queries.auto.sql +++ b/resources/sql/queries.auto.sql @@ -1,7 +1,7 @@ ------------------------------------------------------------------------ -- File queries.sql -- --- autogenerated by adl.to-hugsql-queries at 2018-06-29T14:15:37.324Z +-- autogenerated by adl.to-hugsql-queries at 2018-06-29T16:36:18.648Z -- -- See [Application Description -- Language](https://github.com/simon-brooke/adl). diff --git a/resources/sql/youyesyet.postgres.sql b/resources/sql/youyesyet.postgres.sql index 2dbb0c6..42b0f83 100644 --- a/resources/sql/youyesyet.postgres.sql +++ b/resources/sql/youyesyet.postgres.sql @@ -5,7 +5,7 @@ -- -- auto-generated by [Application Description Language framework] -- --- (https://github.com/simon-brooke/adl) at 20180629T141538.194Z +-- (https://github.com/simon-brooke/adl) at 20180629T163619.639Z -- -- -- A web-app intended to be used by canvassers campaigning for a @@ -860,8 +860,8 @@ ALTER TABLE visits ADD CONSTRAINT ri_visits_canvassers_canvasser_id ------------------------------------------------------------------------ CREATE TABLE ln_canvassers_roles ( - canvassers_id INTEGER, - roles_id INTEGER + canvasser_id INTEGER, + role_id INTEGER ); GRANT SELECT ON ln_canvassers_roles TO admin, analysts, @@ -877,13 +877,13 @@ GRANT UPDATE ON ln_canvassers_roles TO admin, teamorganisers ; GRANT DELETE ON ln_canvassers_roles TO admin ; -ALTER TABLE ln_canvassers_roles ADD CONSTRAINT ri_ln_canvassers_roles_canvassers_canvassers_id - FOREIGN KEY( canvassers_id ) +ALTER TABLE ln_canvassers_roles ADD CONSTRAINT ri_ln_canvassers_roles_canvassers_canvasser_id + FOREIGN KEY( canvasser_id ) REFERENCES canvassers(id) ON DELETE NO ACTION ; -ALTER TABLE ln_canvassers_roles ADD CONSTRAINT ri_ln_canvassers_roles_roles_roles_id - FOREIGN KEY( roles_id ) +ALTER TABLE ln_canvassers_roles ADD CONSTRAINT ri_ln_canvassers_roles_roles_role_id + FOREIGN KEY( role_id ) REFERENCES roles(id) ON DELETE NO ACTION ; @@ -894,8 +894,8 @@ ALTER TABLE ln_canvassers_roles ADD CONSTRAINT ri_ln_canvassers_roles_roles_role ------------------------------------------------------------------------ CREATE TABLE ln_canvassers_teams ( - teams_id INTEGER, - canvassers_id INTEGER + team_id INTEGER, + canvasser_id INTEGER ); GRANT SELECT ON ln_canvassers_teams TO admin, analysts, @@ -909,13 +909,13 @@ GRANT UPDATE ON ln_canvassers_teams TO admin, teamorganisers ; GRANT DELETE ON ln_canvassers_teams TO admin ; -ALTER TABLE ln_canvassers_teams ADD CONSTRAINT ri_ln_canvassers_teams_canvassers_canvassers_id - FOREIGN KEY( canvassers_id ) +ALTER TABLE ln_canvassers_teams ADD CONSTRAINT ri_ln_canvassers_teams_canvassers_canvasser_id + FOREIGN KEY( canvasser_id ) REFERENCES canvassers(id) ON DELETE NO ACTION ; -ALTER TABLE ln_canvassers_teams ADD CONSTRAINT ri_ln_canvassers_teams_teams_teams_id - FOREIGN KEY( teams_id ) +ALTER TABLE ln_canvassers_teams ADD CONSTRAINT ri_ln_canvassers_teams_teams_team_id + FOREIGN KEY( team_id ) REFERENCES teams(id) ON DELETE NO ACTION ; diff --git a/resources/templates/auto/application-index.html b/resources/templates/auto/application-index.html index 517fd53..7305958 100644 --- a/resources/templates/auto/application-index.html +++ b/resources/templates/auto/application-index.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-addresses-Address.html b/resources/templates/auto/form-addresses-Address.html index e3dc979..083db4f 100644 --- a/resources/templates/auto/form-addresses-Address.html +++ b/resources/templates/auto/form-addresses-Address.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-authorities-Authority.html b/resources/templates/auto/form-authorities-Authority.html index 8e6a888..19283c2 100644 --- a/resources/templates/auto/form-authorities-Authority.html +++ b/resources/templates/auto/form-authorities-Authority.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-canvassers-Canvasser.html b/resources/templates/auto/form-canvassers-Canvasser.html index e1e7e41..ef82c02 100644 --- a/resources/templates/auto/form-canvassers-Canvasser.html +++ b/resources/templates/auto/form-canvassers-Canvasser.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-districts-District.html b/resources/templates/auto/form-districts-District.html index 3e73b5f..eb692a7 100644 --- a/resources/templates/auto/form-districts-District.html +++ b/resources/templates/auto/form-districts-District.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-dwellings-Dwelling.html b/resources/templates/auto/form-dwellings-Dwelling.html index 48cb518..850d68c 100644 --- a/resources/templates/auto/form-dwellings-Dwelling.html +++ b/resources/templates/auto/form-dwellings-Dwelling.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-electors-Elector.html b/resources/templates/auto/form-electors-Elector.html index 6cc58a4..1b6251a 100644 --- a/resources/templates/auto/form-electors-Elector.html +++ b/resources/templates/auto/form-electors-Elector.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-followupactions-Followupaction.html b/resources/templates/auto/form-followupactions-Followupaction.html index 3af54ce..ef4bd47 100644 --- a/resources/templates/auto/form-followupactions-Followupaction.html +++ b/resources/templates/auto/form-followupactions-Followupaction.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-followupmethods-Followupmethod.html b/resources/templates/auto/form-followupmethods-Followupmethod.html index 0d50659..5a5171c 100644 --- a/resources/templates/auto/form-followupmethods-Followupmethod.html +++ b/resources/templates/auto/form-followupmethods-Followupmethod.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-followuprequests-Followuprequest.html b/resources/templates/auto/form-followuprequests-Followuprequest.html index 2d5d382..ee12d56 100644 --- a/resources/templates/auto/form-followuprequests-Followuprequest.html +++ b/resources/templates/auto/form-followuprequests-Followuprequest.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-genders-Gender.html b/resources/templates/auto/form-genders-Gender.html index 87806cb..238a638 100644 --- a/resources/templates/auto/form-genders-Gender.html +++ b/resources/templates/auto/form-genders-Gender.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-intentions-Intention.html b/resources/templates/auto/form-intentions-Intention.html index 8d41da9..be4870d 100644 --- a/resources/templates/auto/form-intentions-Intention.html +++ b/resources/templates/auto/form-intentions-Intention.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-issues-Issue.html b/resources/templates/auto/form-issues-Issue.html index d5fab5b..085cccc 100644 --- a/resources/templates/auto/form-issues-Issue.html +++ b/resources/templates/auto/form-issues-Issue.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-options-Option.html b/resources/templates/auto/form-options-Option.html index c53b1cf..d52fcda 100644 --- a/resources/templates/auto/form-options-Option.html +++ b/resources/templates/auto/form-options-Option.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-roles-Role.html b/resources/templates/auto/form-roles-Role.html index 8fd42c4..991549a 100644 --- a/resources/templates/auto/form-roles-Role.html +++ b/resources/templates/auto/form-roles-Role.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-teams-Team.html b/resources/templates/auto/form-teams-Team.html index 3eb05d0..ef80fdf 100644 --- a/resources/templates/auto/form-teams-Team.html +++ b/resources/templates/auto/form-teams-Team.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/form-visits-Visit.html b/resources/templates/auto/form-visits-Visit.html index 65e51ea..1a504dd 100644 --- a/resources/templates/auto/form-visits-Visit.html +++ b/resources/templates/auto/form-visits-Visit.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-addresses-Addresses.html b/resources/templates/auto/list-addresses-Addresses.html index 96da5ee..8fed2b1 100644 --- a/resources/templates/auto/list-addresses-Addresses.html +++ b/resources/templates/auto/list-addresses-Addresses.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-authorities-Authorities.html b/resources/templates/auto/list-authorities-Authorities.html index 35d09f1..98e5db9 100644 --- a/resources/templates/auto/list-authorities-Authorities.html +++ b/resources/templates/auto/list-authorities-Authorities.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-canvassers-Canvassers.html b/resources/templates/auto/list-canvassers-Canvassers.html index c37423a..06f07a2 100644 --- a/resources/templates/auto/list-canvassers-Canvassers.html +++ b/resources/templates/auto/list-canvassers-Canvassers.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-districts-Districts.html b/resources/templates/auto/list-districts-Districts.html index 1ae5e72..10aa521 100644 --- a/resources/templates/auto/list-districts-Districts.html +++ b/resources/templates/auto/list-districts-Districts.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-dwellings-Dwellings.html b/resources/templates/auto/list-dwellings-Dwellings.html index 22a42e9..ff846fd 100644 --- a/resources/templates/auto/list-dwellings-Dwellings.html +++ b/resources/templates/auto/list-dwellings-Dwellings.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-electors-Electors.html b/resources/templates/auto/list-electors-Electors.html index 103b700..e55df8e 100644 --- a/resources/templates/auto/list-electors-Electors.html +++ b/resources/templates/auto/list-electors-Electors.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-followupactions-Followupactions.html b/resources/templates/auto/list-followupactions-Followupactions.html index a4c3dca..25138cd 100644 --- a/resources/templates/auto/list-followupactions-Followupactions.html +++ b/resources/templates/auto/list-followupactions-Followupactions.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-followupmethods-Followupmethods.html b/resources/templates/auto/list-followupmethods-Followupmethods.html index 457d6f5..51cab99 100644 --- a/resources/templates/auto/list-followupmethods-Followupmethods.html +++ b/resources/templates/auto/list-followupmethods-Followupmethods.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-followuprequests-Followuprequests.html b/resources/templates/auto/list-followuprequests-Followuprequests.html index c81c924..4df3180 100644 --- a/resources/templates/auto/list-followuprequests-Followuprequests.html +++ b/resources/templates/auto/list-followuprequests-Followuprequests.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-genders-Genders.html b/resources/templates/auto/list-genders-Genders.html index 64da2fe..e579f6a 100644 --- a/resources/templates/auto/list-genders-Genders.html +++ b/resources/templates/auto/list-genders-Genders.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-intentions-Intentions.html b/resources/templates/auto/list-intentions-Intentions.html index 8fc6118..3e11a92 100644 --- a/resources/templates/auto/list-intentions-Intentions.html +++ b/resources/templates/auto/list-intentions-Intentions.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-issues-Issues.html b/resources/templates/auto/list-issues-Issues.html index 1c08c80..50875c0 100644 --- a/resources/templates/auto/list-issues-Issues.html +++ b/resources/templates/auto/list-issues-Issues.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-options-Options.html b/resources/templates/auto/list-options-Options.html index fd49da7..b7bce93 100644 --- a/resources/templates/auto/list-options-Options.html +++ b/resources/templates/auto/list-options-Options.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-roles-Roles.html b/resources/templates/auto/list-roles-Roles.html index af780fe..09fe18d 100644 --- a/resources/templates/auto/list-roles-Roles.html +++ b/resources/templates/auto/list-roles-Roles.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-teams-Teams.html b/resources/templates/auto/list-teams-Teams.html index 089ef34..582741b 100644 --- a/resources/templates/auto/list-teams-Teams.html +++ b/resources/templates/auto/list-teams-Teams.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/auto/list-visits-Visits.html b/resources/templates/auto/list-visits-Visits.html index 93fe01b..ed998ee 100644 --- a/resources/templates/auto/list-visits-Visits.html +++ b/resources/templates/auto/list-visits-Visits.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - {% block head %} diff --git a/resources/templates/base-authenticated.html b/resources/templates/base-authenticated.html index 4fd1834..cc067b0 100644 --- a/resources/templates/base-authenticated.html +++ b/resources/templates/base-authenticated.html @@ -23,7 +23,7 @@ {% else %}Login{% endif %}
  • About
  • {% if user %} -
  • Logged in as {{user.username}}
  • +
  • Logged in as {{user.fullname}}
  • {% endif %} @@ -34,6 +34,9 @@ {% endblock %}
    + -
    {% block foot %}