Remove null arcs (begin==end)
This commit is contained in:
parent
c7ebaccb3f
commit
0870422875
@ -136,11 +136,11 @@ exports.writeGroundnetXML = function (fDir, icao, featureList) {
|
|||||||
});
|
});
|
||||||
nodes = nodes.filter(n => n);
|
nodes = nodes.filter(n => n);
|
||||||
|
|
||||||
|
arcList = arcList.filter(a => a['@begin'] !== a['@end']);
|
||||||
|
|
||||||
nodes.sort((p, p2) => { return p['@index'] - p2['@index'] });
|
nodes.sort((p, p2) => { return p['@index'] - p2['@index'] });
|
||||||
var uniqueNodes = nodes.filter((v, i, a) => a.indexOf(v) === i);
|
var uniqueNodes = nodes.filter((v, i, a) => a.indexOf(v) === i);
|
||||||
|
|
||||||
var maxId = uniqueNodes.slice(-1)[0]['@index'];
|
|
||||||
|
|
||||||
var approachList = store.default.state.Frequencies.items.filter(f => f.type === 'APPROACH').map(mapFrequency);
|
var approachList = store.default.state.Frequencies.items.filter(f => f.type === 'APPROACH').map(mapFrequency);
|
||||||
|
|
||||||
var awosList = store.default.state.Frequencies.items.filter(f => f.type === 'AWOS').map(mapFrequency);
|
var awosList = store.default.state.Frequencies.items.filter(f => f.type === 'AWOS').map(mapFrequency);
|
||||||
@ -169,7 +169,7 @@ exports.writeGroundnetXML = function (fDir, icao, featureList) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
var mapFrequency = function (o) {
|
var mapFrequency = function (o) {
|
||||||
return o.value;
|
return mathjs.round(o.value, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
var mapParkings = function (o) {
|
var mapParkings = function (o) {
|
||||||
|
Loading…
Reference in New Issue
Block a user