Opened 16 years ago
Closed 16 years ago
#186 closed defect (fixed)
Legend Items do not display
Reported by: | pdeschamps | Owned by: | pdeschamps |
---|---|---|---|
Priority: | P2 | Milestone: | 2.0 |
Component: | Core | Version: | SVN |
Severity: | Minor | Keywords: | |
Cc: | Browser: | All | |
External ID: | Operating System: | All | |
state: | New |
Description
in svn rev 1694. the legend items do not render. The issue was some string => boolean conversion that was hapening in Layers.js. Aparently MapGuide is setting these booleans as strings and we needed to convert them into Booleans.
this.editable = o.editable=="true"?true:false; this.visible = o.visible=="true"?true:false; this.selectable = o.selectable=="true"?true:false; this.displayInLegend = o.displayInLegend=="true"?true:false; this.expandInLegend = o.expandInLegend=="true"?true:false; this.actuallyVisible = o.actuallyVisible=="true"?true:false;
However in Mapserver it was already a boolean and thus making all these items false causing a legend to display with no items.
For the time being until we equalize this: "To be or Not to be a string" issue I am patching up this with an if typeof = boolean This bug should remain open for us to trac this MG / MS differences. As we go deeper in the rabbit hole.
Change History (4)
comment:1 by , 16 years ago
Version: | 1.1.0 → SVN |
---|
comment:2 by , 16 years ago
comment:3 by , 16 years ago
comment:4 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
closing, flags in the LoadMap response are now being returned as booleans
In MapGuide/LoadMap.php we have a function "BooleanToString" that is converting a Boolean into a string. It has been suggested that I remove these calls so mapserver / mapguide behave the same way.
I have removed the string comparisons in Layers.js reverting it back to a boolean = boolean statement and removed all calls to BooleanToString in LoadMap.php.
If someone could explain why we are doing this anyway for mapguide that would be great. I will leave this open for that discussion.