Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5948f3ece6 | ||
|
|
80b72fe09d | ||
|
|
b13d6f7b03 | ||
|
|
4c356113aa | ||
|
|
68b5c67a16 | ||
|
|
ae53746323 | ||
|
|
73ff073540 |
@@ -1,11 +1,72 @@
|
|||||||
|
|
||||||
|
const PREFIXES = `
|
||||||
|
PREFIX org: <http://www.w3.org/ns/org#>
|
||||||
|
PREFIX mandaat: <http://data.vlaanderen.be/ns/mandaat#>
|
||||||
|
PREFIX lblodlg: <http://data.lblod.info/vocabularies/leidinggevenden/>
|
||||||
|
PREFIX besluit: <http://data.vlaanderen.be/ns/besluit#>`
|
||||||
|
|
||||||
const contextConfig = {
|
const contextConfig = {
|
||||||
addTypes: {
|
addTypes: {
|
||||||
scope: 'all', // 'inserts, 'deletes', 'all' or none. To add rdf:type to subjects of inserts, deletes or both
|
scope: 'all', // 'inserts, 'deletes', 'all' or none. To add rdf:type to subjects of inserts, deletes or both
|
||||||
exhausitive: false, // true or false: find all types for a subject, even if one is already present in delta
|
exhausitive: false, // true or false: find all types for a subject, even if one is already present in delta
|
||||||
},
|
},
|
||||||
contextQueries: []
|
contextQueries: [
|
||||||
|
// Case Leidnggevenden
|
||||||
|
// They can be triggered when being inserted or when their link to a bestuursfunctie is added
|
||||||
|
{
|
||||||
|
trigger: { // subjectType or predicateValue
|
||||||
|
subjectType: "lblodlg:Functionaris"
|
||||||
|
},
|
||||||
|
queryTemplate: (subject) => `
|
||||||
|
${PREFIXES}
|
||||||
|
CONSTRUCT {
|
||||||
|
?functionaris org:holds ?bestuursfunctie ;
|
||||||
|
?p ?o .
|
||||||
|
?orgaanInTime lblodlg:heeftBestuursfunctie ?bestuursfunctie ;
|
||||||
|
mandaat:isTijdspecialisatieVan ?orgaan .
|
||||||
|
?orgaan besluit:bestuurt ?eenheid .
|
||||||
|
?eenheid besluit:classificatie ?classification .
|
||||||
|
} WHERE {
|
||||||
|
GRAPH <http://mu.semte.ch/graphs/landing-zone/leidinggevenden> {
|
||||||
|
VALUES ?functionaris { ${subject} }
|
||||||
|
?functionaris org:holds ?bestuursfunctie ;
|
||||||
|
?p ?o .
|
||||||
|
?orgaanInTime lblodlg:heeftBestuursfunctie ?bestuursfunctie ;
|
||||||
|
mandaat:isTijdspecialisatieVan ?orgaan .
|
||||||
|
?orgaan besluit:bestuurt ?eenheid .
|
||||||
|
?eenheid besluit:classificatie ?classification .
|
||||||
|
}
|
||||||
|
}`
|
||||||
|
},
|
||||||
|
{
|
||||||
|
trigger: {
|
||||||
|
predicateValue: "org:holds"
|
||||||
|
},
|
||||||
|
queryTemplate: (subject) => `
|
||||||
|
${PREFIXES}
|
||||||
|
CONSTRUCT {
|
||||||
|
?functionaris org:holds ?bestuursfunctie ;
|
||||||
|
?p ?o .
|
||||||
|
?orgaanInTime lblodlg:heeftBestuursfunctie ?bestuursfunctie ;
|
||||||
|
mandaat:isTijdspecialisatieVan ?orgaan .
|
||||||
|
?orgaan besluit:bestuurt ?eenheid .
|
||||||
|
?eenheid besluit:classificatie ?classification .
|
||||||
|
} WHERE {
|
||||||
|
GRAPH <http://mu.semte.ch/graphs/landing-zone/leidinggevenden> {
|
||||||
|
VALUES ?functionaris { ${subject} }
|
||||||
|
?functionaris org:holds ?bestuursfunctie ;
|
||||||
|
?p ?o .
|
||||||
|
?orgaanInTime lblodlg:heeftBestuursfunctie ?bestuursfunctie ;
|
||||||
|
mandaat:isTijdspecialisatieVan ?orgaan .
|
||||||
|
?orgaan besluit:bestuurt ?eenheid .
|
||||||
|
?eenheid besluit:classificatie ?classification .
|
||||||
|
}
|
||||||
|
}`
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
contextConfig
|
contextConfig,
|
||||||
|
PREFIXES
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1,11 +1,72 @@
|
|||||||
|
|
||||||
|
const PREFIXES = `
|
||||||
|
PREFIX org: <http://www.w3.org/ns/org#>
|
||||||
|
PREFIX mandaat: <http://data.vlaanderen.be/ns/mandaat#>
|
||||||
|
PREFIX lblodlg: <http://data.lblod.info/vocabularies/leidinggevenden/>
|
||||||
|
PREFIX besluit: <http://data.vlaanderen.be/ns/besluit#>`
|
||||||
|
|
||||||
const contextConfig = {
|
const contextConfig = {
|
||||||
addTypes: {
|
addTypes: {
|
||||||
scope: 'all', // 'inserts, 'deletes', 'all' or none. To add rdf:type to subjects of inserts, deletes or both
|
scope: 'all', // 'inserts, 'deletes', 'all' or none. To add rdf:type to subjects of inserts, deletes or both
|
||||||
exhausitive: false, // true or false: find all types for a subject, even if one is already present in delta
|
exhausitive: false, // true or false: find all types for a subject, even if one is already present in delta
|
||||||
},
|
},
|
||||||
contextQueries: []
|
contextQueries: [
|
||||||
|
// Case Mandatarissen
|
||||||
|
// They can be triggered when being inserted or when their link to a mandate is added
|
||||||
|
{
|
||||||
|
trigger: { // subjectType or predicateValue
|
||||||
|
subjectType: "mandaat:Mandataris"
|
||||||
|
},
|
||||||
|
queryTemplate: (subject) => `
|
||||||
|
${PREFIXES}
|
||||||
|
CONSTRUCT {
|
||||||
|
?mandataris org:holds ?mandate ;
|
||||||
|
?p ?o .
|
||||||
|
?orgaanInTime org:hasPost ?mandate ;
|
||||||
|
mandaat:isTijdspecialisatieVan ?orgaan .
|
||||||
|
?orgaan besluit:bestuurt ?eenheid .
|
||||||
|
?eenheid besluit:classificatie ?classification .
|
||||||
|
} WHERE {
|
||||||
|
GRAPH <http://mu.semte.ch/graphs/landing-zone/mandatarissen> {
|
||||||
|
VALUES ?mandataris { ${subject} }
|
||||||
|
?mandataris org:holds ?mandate ;
|
||||||
|
?p ?o .
|
||||||
|
?orgaanInTime org:hasPost ?mandate ;
|
||||||
|
mandaat:isTijdspecialisatieVan ?orgaan .
|
||||||
|
?orgaan besluit:bestuurt ?eenheid .
|
||||||
|
?eenheid besluit:classificatie ?classification .
|
||||||
|
}
|
||||||
|
}`
|
||||||
|
},
|
||||||
|
{
|
||||||
|
trigger: {
|
||||||
|
predicateValue: "org:holds"
|
||||||
|
},
|
||||||
|
queryTemplate: (subject) => `
|
||||||
|
${PREFIXES}
|
||||||
|
CONSTRUCT {
|
||||||
|
?mandataris org:holds ?mandate ;
|
||||||
|
?p ?o .
|
||||||
|
?orgaanInTime org:hasPost ?mandate ;
|
||||||
|
mandaat:isTijdspecialisatieVan ?orgaan .
|
||||||
|
?orgaan besluit:bestuurt ?eenheid .
|
||||||
|
?eenheid besluit:classificatie ?classification .
|
||||||
|
} WHERE {
|
||||||
|
GRAPH <http://mu.semte.ch/graphs/landing-zone/mandatarissen> {
|
||||||
|
VALUES ?mandataris { ${subject} }
|
||||||
|
?mandataris org:holds ?mandate ;
|
||||||
|
?p ?o .
|
||||||
|
?orgaanInTime org:hasPost ?mandate ;
|
||||||
|
mandaat:isTijdspecialisatieVan ?orgaan .
|
||||||
|
?orgaan besluit:bestuurt ?eenheid .
|
||||||
|
?eenheid besluit:classificatie ?classification .
|
||||||
|
}
|
||||||
|
}`
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
contextConfig
|
contextConfig,
|
||||||
|
PREFIXES
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -0,0 +1,21 @@
|
|||||||
|
DELETE {
|
||||||
|
GRAPH <http://mu.semte.ch/graphs/administrative-unit> {
|
||||||
|
?functionaris ?pfunctionaris ?ofunctionaris .
|
||||||
|
}
|
||||||
|
} WHERE {
|
||||||
|
GRAPH <http://mu.semte.ch/graphs/administrative-unit> {
|
||||||
|
?functionaris a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?bestuursfunctie ;
|
||||||
|
?pfunctionaris ?ofunctionaris .
|
||||||
|
}
|
||||||
|
|
||||||
|
?orgaan <http://data.lblod.info/vocabularies/leidinggevenden/heeftBestuursfunctie> ?bestuursfunctie ;
|
||||||
|
<http://data.vlaanderen.be/ns/mandaat#isTijdspecialisatieVan>/<http://data.vlaanderen.be/ns/besluit#bestuurt>/<http://data.vlaanderen.be/ns/besluit#classificatie> ?classification .
|
||||||
|
|
||||||
|
FILTER(?classification NOT IN (
|
||||||
|
<http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000000>,
|
||||||
|
<http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000001>,
|
||||||
|
<http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000002>,
|
||||||
|
<http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000003>
|
||||||
|
))
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
delete {
|
||||||
|
graph ?g {
|
||||||
|
<http://data.lblod.info/id/veranderingsgebeurtenissen/6380DDD34B5FEAF28DEDE982> <http://data.lblod.info/vocabularies/contacthub/typeWijziging>
|
||||||
|
<http://lblod.data.gift/concepts/3dd7550843eaf18e1fa1ca6c6c3f2610>.
|
||||||
|
}
|
||||||
|
}
|
||||||
|
insert {
|
||||||
|
graph ?g {
|
||||||
|
<http://data.lblod.info/id/veranderingsgebeurtenissen/6380DDD34B5FEAF28DEDE982> <http://data.lblod.info/vocabularies/contacthub/typeWijziging>
|
||||||
|
<http://lblod.data.gift/concepts/9f19f14910245f9b14737f1f1a2067f2>.
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
where {
|
||||||
|
graph ?g {
|
||||||
|
<http://data.lblod.info/id/veranderingsgebeurtenissen/6380DDD34B5FEAF28DEDE982> <http://data.lblod.info/vocabularies/contacthub/typeWijziging>
|
||||||
|
<http://lblod.data.gift/concepts/3dd7550843eaf18e1fa1ca6c6c3f2610>.
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,5 +1,7 @@
|
|||||||
# Filtering classes to ingest
|
# Filtering classes to ingest
|
||||||
|
|
||||||
|
@prefix log: <http://www.w3.org/2000/10/swap/log#> .
|
||||||
|
|
||||||
{
|
{
|
||||||
?s a <http://www.w3.org/ns/person#Person> ;
|
?s a <http://www.w3.org/ns/person#Person> ;
|
||||||
?p ?o .
|
?p ?o .
|
||||||
@@ -24,17 +26,117 @@
|
|||||||
?p ?o .
|
?p ?o .
|
||||||
}.
|
}.
|
||||||
|
|
||||||
|
# Functionarissen should be linked to a gemeente, district, provincie or ocmw only (FOR NOW)
|
||||||
|
|
||||||
{
|
{
|
||||||
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?bestuursfunctie ;
|
||||||
?p ?o .
|
?p ?o .
|
||||||
|
|
||||||
|
?orgaanInTime <http://data.lblod.info/vocabularies/leidinggevenden/heeftBestuursfunctie> ?bestuursfunctie ;
|
||||||
|
<https://data.vlaanderen.be/ns/generiek#isTijdspecialisatieVan> ?orgaan .
|
||||||
|
?orgaan <http://data.vlaanderen.be/ns/besluit#bestuurt> ?bestuur .
|
||||||
|
?bestuur <http://www.w3.org/ns/org#classification> <http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000000> .
|
||||||
} => {
|
} => {
|
||||||
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
?p ?o .
|
?p ?o .
|
||||||
}.
|
}.
|
||||||
|
|
||||||
{
|
{
|
||||||
|
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?bestuursfunctie ;
|
||||||
|
?p ?o .
|
||||||
|
|
||||||
|
?orgaanInTime <http://data.lblod.info/vocabularies/leidinggevenden/heeftBestuursfunctie> ?bestuursfunctie ;
|
||||||
|
<https://data.vlaanderen.be/ns/generiek#isTijdspecialisatieVan> ?orgaan .
|
||||||
|
?orgaan <http://data.vlaanderen.be/ns/besluit#bestuurt> ?bestuur .
|
||||||
|
?bestuur <http://www.w3.org/ns/org#classification> <http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000001> .
|
||||||
|
} => {
|
||||||
|
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
|
?p ?o .
|
||||||
|
}.
|
||||||
|
|
||||||
|
{
|
||||||
|
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?bestuursfunctie ;
|
||||||
|
?p ?o .
|
||||||
|
|
||||||
|
?orgaanInTime <http://data.lblod.info/vocabularies/leidinggevenden/heeftBestuursfunctie> ?bestuursfunctie ;
|
||||||
|
<https://data.vlaanderen.be/ns/generiek#isTijdspecialisatieVan> ?orgaan .
|
||||||
|
?orgaan <http://data.vlaanderen.be/ns/besluit#bestuurt> ?bestuur .
|
||||||
|
?bestuur <http://www.w3.org/ns/org#classification> <http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000002> .
|
||||||
|
} => {
|
||||||
|
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
|
?p ?o .
|
||||||
|
}.
|
||||||
|
|
||||||
|
{
|
||||||
|
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?bestuursfunctie ;
|
||||||
|
?p ?o .
|
||||||
|
|
||||||
|
?orgaanInTime <http://data.lblod.info/vocabularies/leidinggevenden/heeftBestuursfunctie> ?bestuursfunctie ;
|
||||||
|
<https://data.vlaanderen.be/ns/generiek#isTijdspecialisatieVan> ?orgaan .
|
||||||
|
?orgaan <http://data.vlaanderen.be/ns/besluit#bestuurt> ?bestuur .
|
||||||
|
?bestuur <http://www.w3.org/ns/org#classification> <http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000003> .
|
||||||
|
} => {
|
||||||
|
?s a <http://data.lblod.info/vocabularies/leidinggevenden/Functionaris> ;
|
||||||
|
?p ?o .
|
||||||
|
}.
|
||||||
|
|
||||||
|
# Mandatarissen should be linked to a gemeente, district, provincie or ocmw only (FOR NOW)
|
||||||
|
|
||||||
|
{
|
||||||
|
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?mandate ;
|
||||||
|
?p ?o .
|
||||||
|
|
||||||
|
?orgaanInTime <http://www.w3.org/ns/org#hasPost> ?mandate ;
|
||||||
|
<https://data.vlaanderen.be/ns/generiek#isTijdspecialisatieVan> ?orgaan .
|
||||||
|
?orgaan <http://data.vlaanderen.be/ns/besluit#bestuurt> ?bestuur .
|
||||||
|
?bestuur <http://www.w3.org/ns/org#classification> <http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000000> .
|
||||||
|
} => {
|
||||||
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
||||||
?p ?o .
|
?p ?o .
|
||||||
|
}.
|
||||||
|
|
||||||
|
{
|
||||||
|
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?mandate ;
|
||||||
|
?p ?o .
|
||||||
|
|
||||||
|
?orgaanInTime <http://www.w3.org/ns/org#hasPost> ?mandate ;
|
||||||
|
<https://data.vlaanderen.be/ns/generiek#isTijdspecialisatieVan> ?orgaan .
|
||||||
|
?orgaan <http://data.vlaanderen.be/ns/besluit#bestuurt> ?bestuur .
|
||||||
|
?bestuur <http://www.w3.org/ns/org#classification> <http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000001> .
|
||||||
|
} => {
|
||||||
|
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
||||||
|
?p ?o .
|
||||||
|
}.
|
||||||
|
|
||||||
|
{
|
||||||
|
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?mandate ;
|
||||||
|
?p ?o .
|
||||||
|
|
||||||
|
?orgaanInTime <http://www.w3.org/ns/org#hasPost> ?mandate ;
|
||||||
|
<https://data.vlaanderen.be/ns/generiek#isTijdspecialisatieVan> ?orgaan .
|
||||||
|
?orgaan <http://data.vlaanderen.be/ns/besluit#bestuurt> ?bestuur .
|
||||||
|
?bestuur <http://www.w3.org/ns/org#classification> <http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000002> .
|
||||||
|
} => {
|
||||||
|
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
||||||
|
?p ?o .
|
||||||
|
}.
|
||||||
|
|
||||||
|
{
|
||||||
|
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
||||||
|
<http://www.w3.org/ns/org#holds> ?mandate ;
|
||||||
|
?p ?o .
|
||||||
|
|
||||||
|
?orgaanInTime <http://www.w3.org/ns/org#hasPost> ?mandate ;
|
||||||
|
<https://data.vlaanderen.be/ns/generiek#isTijdspecialisatieVan> ?orgaan .
|
||||||
|
?orgaan <http://data.vlaanderen.be/ns/besluit#bestuurt> ?bestuur .
|
||||||
|
?bestuur <http://www.w3.org/ns/org#classification> <http://data.vlaanderen.be/id/concept/BestuurseenheidClassificatieCode/5ab0e9b8a3b2ca7c5e000003> .
|
||||||
} => {
|
} => {
|
||||||
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
?s a <http://data.vlaanderen.be/ns/mandaat#Mandataris> ;
|
||||||
?p ?o .
|
?p ?o .
|
||||||
|
|||||||
@@ -72,7 +72,7 @@ services:
|
|||||||
restart: always
|
restart: always
|
||||||
logging: *default-logging
|
logging: *default-logging
|
||||||
resource:
|
resource:
|
||||||
image: semtech/mu-cl-resources:feature-fix-false-boolean-primitive
|
image: semtech/mu-cl-resources:1.22.2
|
||||||
environment:
|
environment:
|
||||||
CACHE_CLEAR_PATH: "http://cache/.mu/clear-keys"
|
CACHE_CLEAR_PATH: "http://cache/.mu/clear-keys"
|
||||||
links:
|
links:
|
||||||
@@ -181,7 +181,7 @@ services:
|
|||||||
restart: always
|
restart: always
|
||||||
logging: *default-logging
|
logging: *default-logging
|
||||||
frontend:
|
frontend:
|
||||||
image: lblod/frontend-organization-portal:1.17.0-1
|
image: lblod/frontend-organization-portal:1.17.1
|
||||||
volumes:
|
volumes:
|
||||||
- ./config/frontend/add-x-frame-options-header.conf:/config/add-x-frame-options.conf
|
- ./config/frontend/add-x-frame-options-header.conf:/config/add-x-frame-options.conf
|
||||||
environment:
|
environment:
|
||||||
@@ -228,7 +228,7 @@ services:
|
|||||||
restart: always
|
restart: always
|
||||||
logging: *default-logging
|
logging: *default-logging
|
||||||
reasoner:
|
reasoner:
|
||||||
image: eyereasoner/reasoning-service:1.0.2
|
image: eyereasoner/reasoning-service:increased-stack-limit
|
||||||
volumes:
|
volumes:
|
||||||
- ./config/reasoner:/config
|
- ./config/reasoner:/config
|
||||||
################################################################################
|
################################################################################
|
||||||
|
|||||||
Reference in New Issue
Block a user