[fusion-commits] r2977 - in sandbox/adsk/2.6l: layers/MapGuide widgets/Redline/classes
svn_fusion at osgeo.org
svn_fusion at osgeo.org
Tue Apr 11 00:02:39 PDT 2017
Author: liuar
Date: 2017-04-11 00:02:39 -0700 (Tue, 11 Apr 2017)
New Revision: 2977
Modified:
sandbox/adsk/2.6l/layers/MapGuide/MapGuide.js
sandbox/adsk/2.6l/widgets/Redline/classes/markupeditor.php
Log:
Merge fix for #656 Error when select redline object to adsk/2.6l branch.
Modified: sandbox/adsk/2.6l/layers/MapGuide/MapGuide.js
===================================================================
--- sandbox/adsk/2.6l/layers/MapGuide/MapGuide.js 2017-03-31 08:00:36 UTC (rev 2976)
+++ sandbox/adsk/2.6l/layers/MapGuide/MapGuide.js 2017-04-11 07:02:39 UTC (rev 2977)
@@ -1360,10 +1360,12 @@
resp.hasSelection = true;
var layerId = layer.getName();
var oLayer = this.getLayerById(layerId);
- resp.layers.push(oLayer.layerName);
- resp[oLayer.layerName] = {
- featureCount: nFeatures
- };
+ if (oLayer) {
+ resp.layers.push(oLayer.layerName);
+ resp[oLayer.layerName] = {
+ featureCount: nFeatures
+ };
+ }
}
}
r.responseText = JSON.stringify(resp);
Modified: sandbox/adsk/2.6l/widgets/Redline/classes/markupeditor.php
===================================================================
--- sandbox/adsk/2.6l/widgets/Redline/classes/markupeditor.php 2017-03-31 08:00:36 UTC (rev 2976)
+++ sandbox/adsk/2.6l/widgets/Redline/classes/markupeditor.php 2017-04-11 07:02:39 UTC (rev 2977)
@@ -65,7 +65,11 @@
$idName = $keyProp->GetName();
while ($featureReader->ReadNext())
{
- $id = $featureReader->GetInt32($idName);
+ $propType = $featureReader->GetPropertyType($idName);
+ if ($propType == MgPropertyType::Int64)
+ $id = $featureReader->GetInt64($idName);
+ else
+ $id = $featureReader->GetInt32($idName);
$text = $featureReader->IsNull('Text') ? '' : trim($featureReader->GetString('Text'));
$features[$id] = $text;
}
More information about the fusion-commits
mailing list