Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
DylanVanAssche committed Jul 17, 2018
2 parents bb1e29d + 4a3c774 commit 7b47090
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 7 deletions.
4 changes: 2 additions & 2 deletions files/catalog-example.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"dcat:keyword": "http://schema.org/Service",
"dcat:distribution": [{
"@type": "dcat:Distribution",
"dcat:accessUrl": "https://www.mechelen.be/huis-van-de-mechelaar",
"dcat:accessUrl": "http://smartflanders.ilabt.imec.be/graph/service-example.json",
"dcat:mediaType": "text/html"
}]
},
Expand All @@ -22,7 +22,7 @@
"dcat:keyword": "http://purl.org/vocab/cpsv#PublicService",
"dcat:distribution": [{
"@type": "dcat:Distribution",
"dcat:accessUrl": "http://www.academiemechelen.be/",
"dcat:accessUrl": "http://smartflanders.ilabt.imec.be/graph/service-example.json",
"dcat:mediaType": "text/html"
}]
},
Expand Down
2 changes: 1 addition & 1 deletion files/master-catalog.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
},
"@type": "dcterms:Collection",
"dcterms:hasPart": [{
"foaf:page": "http://smartflanders.ilabt.imec.be/catalog-example.json",
"foaf:page": "http://smartflanders.ilabt.imec.be/graph/catalog-example.json",
"@type": "dcat:Catalog"
},
{
Expand Down
9 changes: 5 additions & 4 deletions helpers/postcodeMapper.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
const https = require('https');
const fs = require('fs');
let adressen = [];
startMapping();
async function startMapping(){
console.log('started')
await fetchAddresses("https://basisregisters.vlaanderen.be/api/v1/adressen?Postcode=9300");
console.log(addressen)
await fetchAddresses("https://basisregisters.vlaanderen.be/api/v1/adressen?Postcode=9300&limit=300");
fs.writeFile('./', JSON.parse(adressen));
}

async function fetchAddresses(url){
let _adressen = JSON.parse(await fetch(url))
_adressen.adressen.forEach(element => {
adressen.push(element.identificator.objectId)
})
if(_addressen.volgende){
await fetchAddresses(_addressen.volgende);
if(_adressen.volgende){
await fetchAddresses(_adressen.volgende);
}
}

Expand Down
Binary file added meetings/SmartFlandersResponsibilities.odg
Binary file not shown.

0 comments on commit 7b47090

Please sign in to comment.