Commit 2898797b authored by Patrick's avatar Patrick
Browse files

some update

parent eefd4449
Showing with 333 additions and 23 deletions
+333 -23
...@@ -11,10 +11,10 @@ const request = require('ajax-request'); ...@@ -11,10 +11,10 @@ const request = require('ajax-request');
app.use(express.static('vcm')); app.use(express.static('vcm'));
app.listen(process.env.PORT || 8080); app.listen(process.env.PORT || 8080);
console.log("on 8080"); console.log("on 8080");
var url = 'http://193.196.137.147:8990/simstadt/services/SimStadt2MonthlyenergyBalance?wsdl'; var url = 'http://193.196.137.147:8990/orchestration/services/SimStadt2MonthlyenergyBalance?wsdl';
var args = { var args = {
gmlid: 'DEBW522AA0003113b', // an example of a building in Essen DENW22AL700004Lv gmlid: 'DENW22AL80000AQv', // an example of a building in Essen DENW22AL700004Lv ----DEBW522AA0003113b---in Stockach
cityID: 1,// Essen 3 // Stockach 1 cityID: 3,// Essen 3 // Stockach 1
ui: { ui: {
attic: true, attic: true,
atticHeating: true, atticHeating: true,
...@@ -22,9 +22,9 @@ var url = 'http://193.196.137.147:8990/simstadt/services/SimStadt2MonthlyenergyB ...@@ -22,9 +22,9 @@ var url = 'http://193.196.137.147:8990/simstadt/services/SimStadt2MonthlyenergyB
basementHeating: true, basementHeating: true,
buildingType: "EFH", // other options: "RH", "MFH", "GFH", "HH" buildingType: "EFH", // other options: "RH", "MFH", "GFH", "HH"
flatRoof: true, flatRoof: true,
id: 'DEBW522AA0003113b', // equal with glmid id: 'DENW22AL80000AQv', // equal with glmid
latitude: 51.44679140365339, // an example of a building in Essen latitude: 50.774414,//51.44679140365339, // an example of a building in Essen
longitude: 6.967781962878631, // an example of a building in Essen longitude: 6.086995,//6.967781962878631, // an example of a building in Essen
refurbishment: "statuQuo", // other options: "medium", "advanced" refurbishment: "statuQuo", // other options: "medium", "advanced"
simulationName: "MonthlyEnergyBalance", // just use this value for Heat/Cooling Demand simulationName: "MonthlyEnergyBalance", // just use this value for Heat/Cooling Demand
storeyCount: 3, storeyCount: 3,
...@@ -40,29 +40,30 @@ var url = 'http://193.196.137.147:8990/simstadt/services/SimStadt2MonthlyenergyB ...@@ -40,29 +40,30 @@ var url = 'http://193.196.137.147:8990/simstadt/services/SimStadt2MonthlyenergyB
try { try {
const data = req.body; const data = req.body;
// console.log("data ==============") console.log("data ==============")
// console.log(data.id); console.log(data.id);
args.gmlid = data.id args.gmlid = data.id
// console.log(data[0]); console.log(data[0]);
// console.log(data[1]); console.log(data[1]);
// console.log("args ==============") console.log("args ==============")
// console.log(args); console.log(args);
//asdf //asdf
const returnedTarget = Object.assign(args.ui,data); const returnedTarget = Object.assign(args.ui,data);
// args.ui = data; args.ui = data;
// args.gmlid = data.id; args.gmlid = data.id;
// console.log("returned ==============") console.log("returned ==============")
// console.log(returnedTarget) console.log(returnedTarget)
// console.log("args ==============") console.log("args ==============")
// console.log(args); console.log(args);
soap.createClient(url, function(err, client) { soap.createClient(url, function(err, client) {
client.getMonthlyEnergyBalance(args, function(err, result) { client.getMonthlyEnergyBalance(args, function(err, result) {
if (err) throw err; if (err) throw err;
console.log(result); console.log(result);
// const obj = JSON.parse(result); // const obj = JSON.parse(result);
// console.log(obj) // console.log(obj)
res.json(result); return res.send(result);
return result; // res.json(result);
// return result;
}); });
}); });
} }
...@@ -73,3 +74,36 @@ var url = 'http://193.196.137.147:8990/simstadt/services/SimStadt2MonthlyenergyB ...@@ -73,3 +74,36 @@ var url = 'http://193.196.137.147:8990/simstadt/services/SimStadt2MonthlyenergyB
/* *************
WSDL SimStadt (Preston)
************* */
// router.get('/monthlyEnergyBalance', function(req, res) {
// var url = 'http://193.196.137.147:8990/orchestration/services/SimStadt2MonthlyenergyBalance?wsdl'
// var args = {
// gmlid: 'DENW22AL80000AQv', // req.params.gmlID,
// cityID: 3,// Essen
// ui: {
// attic: true,
// atticHeating: true,
// basement: true,
// basementHeating: true,
// buildingType: "EFH", // "RH" , "MFH" , "GFH" , "HH"
// flatRoof: true,
// id: "DENW22AL80000AQv",
// latitude: 50.774414,
// longitude: 6.086995,
// refurbishment: "statuQuo", // "medium", "advanced"
// simulationName: "MonthlyEnergyBalance",
// storeyCount: 3,
// timestep: 1, // dummy integer, not yet integrated but mandatory
// usageProfile: "Single Family House", // "Multi Family House"
// yearOfConstruction: 1946
// }
// };
// soap.createClient(url, function(err, client) {
// client.getMonthlyEnergyBalance(args, function(err, result) {
// if (err) throw err;
// return res.send(result);
// });
// });
// });
...@@ -288,6 +288,94 @@ ...@@ -288,6 +288,94 @@
} }
], ],
"balloonHeader": "Balloon header" "balloonHeader": "Balloon header"
},{
"template": [
"<div class='balloon' id='myBalloon'>",
"<div class='balloon-content'>",
"<h1 class='balloon-title'>Balloon header</h1>",
"<% for (var key in obj) { %>",
"<% if (obj[key] instanceof Object){%>",
"<% for (var key2 in obj[key]) { %>",
"<p class='balloon-text'><span class='balloon-street'> <strong> <%=key%>.<%=key2%> </strong> : <%=obj[key][key2]%></span><br></p>",
"<% } %>",
"<% } else{ %>",
"<p class='balloon-text'>",
"<span class='balloon-street'> <strong> <%=key%> </strong> : <%=obj[key]%></span><br>",
"</p>",
"<% } %>",
"<% } %>",
"</div>",
"<div class='balloon-close-col'>",
"<button class='close-balloon'><i class='fa fa-times fa-lg'></i></button>",
"</div>",
"<div class='dialog-image-balloon'></div>",
"<div class='balloon-left-edge'></div>",
"</div>"
],
"layerTypes": [
null
],
"layerNames": [
"StuttgartLocal"
],
"minTop": "balloonHeight + 30",
"minLeft": "70",
"allAvailable": true,
"properties": [
{
"title": "creationDate",
"name": "creationDate"
},
{
"title": "gml:name",
"name": "gml:name"
}
],
"balloonHeader": "Balloon header"
},{
"template": [
"<div class='balloon' id='myBalloon'>",
"<div class='balloon-content'>",
"<h1 class='balloon-title'>Balloon header</h1>",
"<% for (var key in obj) { %>",
"<% if (obj[key] instanceof Object){%>",
"<% for (var key2 in obj[key]) { %>",
"<p class='balloon-text'><span class='balloon-street'> <strong> <%=key%>.<%=key2%> </strong> : <%=obj[key][key2]%></span><br></p>",
"<% } %>",
"<% } else{ %>",
"<p class='balloon-text'>",
"<span class='balloon-street'> <strong> <%=key%> </strong> : <%=obj[key]%></span><br>",
"</p>",
"<% } %>",
"<% } %>",
"</div>",
"<div class='balloon-close-col'>",
"<button class='close-balloon'><i class='fa fa-times fa-lg'></i></button>",
"</div>",
"<div class='dialog-image-balloon'></div>",
"<div class='balloon-left-edge'></div>",
"</div>"
],
"layerTypes": [
null
],
"layerNames": [
"StuttgartPart"
],
"minTop": "balloonHeight + 30",
"minLeft": "70",
"allAvailable": true,
"properties": [
{
"title": "creationDate",
"name": "creationDate"
},
{
"title": "gml:name",
"name": "gml:name"
}
],
"balloonHeader": "Balloon header"
}, },
{ {
"template": [ "template": [
...@@ -367,12 +455,20 @@ ...@@ -367,12 +455,20 @@
"</div><br>", "</div><br>",
"<div class='btn btn-three' onclick='oldZust()'>", "<div class='btn btn-three' onclick='oldZust()'>",
"<span>Ist Zustand</span>", "<span>Ist Zustand</span>",
"</div><br></div><div class='box-3'>", "</div><br></div>",
"<div class='switch'>", "<div class='box-3'>",
"<p>Highlight &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </p><div class='switch'>",
"<input type='checkbox' name='toggle' id='chxboxHighlight' onclick='checkboxHighlight();'>", "<input type='checkbox' name='toggle' id='chxboxHighlight' onclick='checkboxHighlight();'>",
"<label for='toggle'><i></i></label>", "<label for='toggle'><i></i></label>",
"<span></span>", "<span></span>",
"</div>", "</div>",
"</div>",
"<div class='box-3'>",
"<p>EnergyDemand</p><div class='switch'>",
"<input type='checkbox' name='toggle' id='chxboxDemand' onclick='checkboxDemand();'>",
"<label for='toggle'><i></i></label>",
"<span></span>",
"</div>", "</div>",
"</div>", "</div>",
"<% %>" "<% %>"
...@@ -766,6 +862,22 @@ ...@@ -766,6 +862,22 @@
"url": "", "url": "",
"year": "" "year": ""
} }
},{
"name": "StuttgartLocal",
"url": "./datasource-data/Stuttgart/tileset.json",
"type": "vcs.vcm.layer.cesium.Buildings",
"datasourceId": "zECwoSwXppPMrqfLoc",
"activeOnStartup": false,
"exclusive": false,
"allowPicking": true,
"screenSpaceError": 16,
"screenSpaceErrorMobile": 32,
"hiddenObjectIds": [],
"copyright": {
"provider": "",
"url": "",
"year": ""
}
},{ },{
"name": "Rosenstein", "name": "Rosenstein",
"url": "./datasource-data/Rosenstein/tileset.json", "url": "./datasource-data/Rosenstein/tileset.json",
...@@ -793,6 +905,22 @@ ...@@ -793,6 +905,22 @@
"allowPicking": true, "allowPicking": true,
"screenSpaceError": 16, "screenSpaceError": 16,
"screenSpaceErrorMobile": 32, "screenSpaceErrorMobile": 32,
"hiddenObjectIds": ["DEBW522AA00022dcc","DEBW522AA0003bf3b","DEBW522AA0000976a","DEBW522AA00001d00"],
"copyright": {
"provider": "",
"url": "",
"year": ""
}
},{
"name": "StuttgartPart",
"url": "./datasource-data/PartOfStuggi/tileset.json",
"type": "vcs.vcm.layer.cesium.Buildings",
"datasourceId": "orpdK9eKzTLaDmStu",
"activeOnStartup": true,
"exclusive": false,
"allowPicking": true,
"screenSpaceError": 16,
"screenSpaceErrorMobile": 32,
"hiddenObjectIds": [], "hiddenObjectIds": [],
"copyright": { "copyright": {
"provider": "", "provider": "",
...@@ -879,7 +1007,7 @@ ...@@ -879,7 +1007,7 @@
"style": { "style": {
"image": { "image": {
"icon": { "icon": {
"src": "./templates/lightning.png", "src": "./templates/building.png",
"scale": 0.5 "scale": 0.5
} }
} }
......
File added
{
"asset" : {
"version" : "0.0"
},
"properties" : {
"gml_id" : {},
"gml_parent_id" : {},
"citygml_target_uri" : {},
"citygml_feature_role" : {},
"citygml_feature_role_attr_name" : {},
"citygml_feature_role_attr_val" : {},
"gml_description" : {},
"gml_name" : {},
"citygml_creationDate" : {},
"citygml_terminationDate" : {},
"externalReference{}.externalObject.name" : {},
"externalReference{}.externalObject.uri" : {},
"externalReference{}.informationSystem" : {},
"citygml_generalizes_to{}.xlink_href" : {},
"citygml_relative_to_terrain" : {},
"citygml_relative_to_water" : {},
"citygml_appearance{}.xlink_href" : {},
"citygml_class" : {},
"citygml_class_codeSpace" : {},
"citygml_function{}" : {},
"citygml_function{}.codeSpace" : {},
"citygml_usage{}" : {},
"citygml_usage{}.codeSpace" : {},
"citygml_year_of_construction" : {},
"citygml_year_of_demolition" : {},
"citygml_roof_type" : {},
"citygml_roof_type_codeSpace" : {},
"citygml_measured_height" : {
"minimum" : 1.6,
"maximum" : 24.3
},
"citygml_measured_height_units" : {},
"citygml_storeys_above_ground" : {},
"citygml_storeys_below_ground" : {},
"citygml_storey_heights_above_ground" : {},
"citygml_storey_heights_above_ground_units" : {},
"citygml_storey_heights_below_ground" : {},
"citygml_storey_heights_below_ground_units" : {},
"citygml_outer_building_installation{}.xlink_href" : {},
"citygml_interior_building_installation{}.xlink_href" : {},
"citygml_bounded_by{}.xlink_href" : {},
"citygml_level_of_detail{}" : {},
"citygml_interior_room{}.xlink_href" : {},
"citygml_consists_of_building_part{}.xlink_href" : {},
"citygml_address{}.xlink_href" : {},
"LoD1_datenquelleBodenhoehe" : {},
"LoD1_datenquelleLage" : {},
"alkisId" : {},
"anzahlDerDreiBisVierZimmerWohnungen" : {},
"anzahlDerFuenfUndMehrZimmerWohnungen" : {},
"baublockNummer" : {},
"baublockseitenNummer" : {},
"dachgeschossausbau" : {},
"gebaeudekennzeichen_1" : {},
"gebaeudekennzeichen_2" : {},
"geschossflaeche" : {},
"gmlIdALKISLageBezeichnung_1" : {},
"gmlIdALKISLageBezeichnung_2" : {},
"grundflaeche" : {},
"hoeheEFH" : {},
"hoeheFirst" : {},
"hoeheTrauf" : {},
"statusDesGebaeudes" : {},
"umbauterRaum" : {},
"GMLId" : {},
"PrimaryUsageZoneArea" : {},
"PrimaryUsageZoneType" : {},
"SecondaryUsageZoneArea" : {},
"SecondaryUsageZoneType" : {},
"ALKIScode" : {},
"AprilHeatingDemand" : {},
"AtticHeating" : {},
"AugustHeatingDemand" : {},
"AverageStoreyHeight" : {},
"Basementceilingheightaboveground" : {},
"BasementHeating" : {},
"BuildingType" : {},
"Class" : {},
"DecemberHeatingDemand" : {},
"Eaves/meanHeight" : {},
"FebruaryHeatingDemand" : {},
"Footprintarea" : {},
"Grossvolume" : {},
"Heatedarea" : {},
"Heatedvolume" : {},
"IsGrossvolumeapproximated?" : {},
"JanuaryHeatingDemand" : {},
"JulyHeatingDemand" : {},
"JuneHeatingDemand" : {},
"Latitude" : {},
"LOD" : {},
"Longitude" : {},
"MarchHeatingDemand" : {},
"MayHeatingDemand" : {},
"MeanUvalue" : {},
"NovemberHeatingDemand" : {},
"Numberofhouseholds" : {},
"Numberofoccupants" : {},
"OctoberHeatingDemand" : {},
"ParentGMLId" : {},
"RefurbishmentVariant" : {},
"Ridge/meanHeight" : {},
"SA2Vratio" : {},
"SeptemberHeatingDemand" : {},
"Specificdomestichotwaterdemand" : {
"minimum" : 15.8,
"maximum" : 15.9
},
"Specificspaceheatingdemand" : {
"minimum" : 0,
"maximum" : 467.7
},
"Storeynumber" : {},
"Totaloutwallarea" : {},
"Totalroofarea" : {},
"Totalsharedwallarea" : {},
"Totalwallthermalareaaboveground" : {},
"Totalwallthermalareabelowground" : {},
"TotalYearlyHeat+DHWdemand" : {},
"X-coordinate" : {},
"Y-coordinate" : {},
"Yearofconstruction" : {},
"Yearofrefurbishment" : {},
"_matched_records" : {},
"_zmin" : {
"minimum" : 230.41,
"maximum" : 252.080521
}
},
"geometricError" : 225.65855423675384,
"root" : {
"boundingVolume" : {
"box" : [ 4155305.234884402, 672842.5487232395, 4775768.442179372, 668.5917059811763, 0, 0, 0, 783.0869944699807, 0, 0, 0, 580.2606065925211 ]
},
"refine" : "ADD",
"content" : {
"boundingVolume" : {
"box" : [ 4155305.234884402, 672842.5487232395, 4775768.442179372, 668.5917059811763, 0, 0, 0, 783.0869944699807, 0, 0, 0, 580.2606065925211 ]
},
"url" : "data/data0.b3dm"
}
}
}
\ No newline at end of file
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
File added
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment