Check for empty names
This commit is contained in:
parent
826781647e
commit
4b908f57ce
@ -165,6 +165,13 @@ async function checkGroundnet(data) {
|
|||||||
this.postMessage(['progress', 1]);
|
this.postMessage(['progress', 1]);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
// Check for intersecting radii
|
||||||
|
parkingNodes.forEach(parkingNode => {
|
||||||
|
if (!parkingNode.name || /^\s*$/.test(parkingNode.name)) {
|
||||||
|
notOkNodes.push({ id: parkingNode.index, message: 'Empty name' });
|
||||||
|
}
|
||||||
|
this.postMessage(['progress', 1]);
|
||||||
|
});
|
||||||
//Check for dual pushback/runway nodes
|
//Check for dual pushback/runway nodes
|
||||||
runwayNodes.forEach(runwayNode => {
|
runwayNodes.forEach(runwayNode => {
|
||||||
if (pushbackNodes.indexOf(runwayNode) >= 0) {
|
if (pushbackNodes.indexOf(runwayNode) >= 0) {
|
||||||
@ -231,7 +238,7 @@ var mapParkings = function (o) {
|
|||||||
|
|
||||||
var mapParkingNode = function (o) {
|
var mapParkingNode = function (o) {
|
||||||
if (o.type === 'parking')
|
if (o.type === 'parking')
|
||||||
return {index: o.index, lat:o.lat, lng:o.lng, radius: Number(o.radius)};
|
return { index: o.index, lat: o.lat, lng: o.lng, name: o.name, radius: Number(o.radius) };
|
||||||
console.log(o);
|
console.log(o);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -243,7 +250,9 @@ var mapRunwayNodes = function (o) {
|
|||||||
|
|
||||||
var mapEdges = function (o) {
|
var mapEdges = function (o) {
|
||||||
if (o.type === 'poly')
|
if (o.type === 'poly')
|
||||||
return {start: o.start, end: o.end, isPushBackRoute: o.isPushBackRoute !== undefined&&
|
return {
|
||||||
o.isPushBackRoute!==0};
|
start: o.start, end: o.end, isPushBackRoute: o.isPushBackRoute !== undefined &&
|
||||||
|
o.isPushBackRoute !== 0
|
||||||
|
};
|
||||||
console.log(o);
|
console.log(o);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user