[mapguide-commits] r8927 - sandbox/adsk/3.0m/Common/MapGuideCommon/Controller

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Tue Apr 19 01:29:55 PDT 2016


Author: hubu
Date: 2016-04-19 01:29:55 -0700 (Tue, 19 Apr 2016)
New Revision: 8927

Modified:
   sandbox/adsk/3.0m/Common/MapGuideCommon/Controller/HtmlController.cpp
Log:
Integrate #8912 to 3.0m branch. Fix the issue that DateTime value cannot be displayed in selection panel.

Modified: sandbox/adsk/3.0m/Common/MapGuideCommon/Controller/HtmlController.cpp
===================================================================
--- sandbox/adsk/3.0m/Common/MapGuideCommon/Controller/HtmlController.cpp	2016-04-19 04:27:22 UTC (rev 8926)
+++ sandbox/adsk/3.0m/Common/MapGuideCommon/Controller/HtmlController.cpp	2016-04-19 08:29:55 UTC (rev 8927)
@@ -613,7 +613,7 @@
                                 //ToXmlString() won't work with dates before Jan 1, 1970, so use yyyy-mm-dd hh:mm:ss
                                 STRING dateStr;
                                 STRING str;
-                                if (dt->IsDate())
+                                if (dt->GetYear() != -1)
                                 {
                                     MgUtil::Int32ToString(dt->GetYear(), str);
                                     dateStr += str;
@@ -626,9 +626,9 @@
                                     MgUtil::PadLeft(str, 2, L'0');
                                     dateStr += str;
                                 }
-                                if (dt->IsTime())
+                                if (dt->GetHour() != -1)
                                 {
-                                    if (dt->IsDate())
+                                    if (dt->GetYear() != -1)
                                     {
                                         dateStr += L" ";
                                     }



More information about the mapguide-commits mailing list