Opened 15 years ago
Closed 14 years ago
#1281 closed defect (fixed)
Path corrections and small template extensions in mapviewerphp/layerdefinitionfactory.php
Reported by: | gabrimonfa | Owned by: | brucedechant |
---|---|---|---|
Priority: | low | Milestone: | 2.3 |
Component: | General | Version: | 2.2.0 |
Severity: | trivial | Keywords: | |
Cc: | External ID: |
Description (last modified by )
All path in mapviewerphp/layerdefinitionfactory.php pointing to ../../viewerfiles should be corrected to ../viewerfiles
CreateAreaRule can be extended to accept two more parameters, $strokeThickness and $strokeColor. CreateLineRule can be extended to accept one more parameter, $strokeThickness
This two last modifications require to modify accordingly also the areaRule and lineRule templates in viewerfiles.
All attached unified diff files refer to <file>_20100226.php (the original one) and <file>.php (the modified one)
Attachments (3)
Change History (15)
by , 15 years ago
Attachment: | layerdefinitionfactory.php.diff added |
---|
by , 15 years ago
Attachment: | arearule.templ.diff added |
---|
trivial template extension to accept also $strokeThickness and $strokeColor
by , 15 years ago
Attachment: | linerule.templ.diff added |
---|
trivial template extension to accept also $strokeThickness
comment:1 by , 15 years ago
Thanks for this but what is this fixing and how can we reproduce the problem that it is fixing?
comment:2 by , 15 years ago
Well, paths are wrong since the directory "viewerfiles" is in the parent directory, not in the parent of the parent ("mapviewerphp" and "viewerfiles" are sibling).
The enhancement allows to specify stroke thickness and color that are hard coded in the templates (we use it to have different colors redlining). Thus I propose to modify the templates and the functions in layerdefinitionfactory.php that instantiate the templates
comment:3 by , 14 years ago
Milestone: | → 2.3 |
---|---|
Owner: | set to |
comment:4 by , 14 years ago
Here is some info that will be useful for reproducing this from an email from Gabriele to mapguide-internals: redlining in php appears to be broken, since template files are not found.
comment:5 by , 14 years ago
The changes look good. However, the createlayer.php file will also need to be updated to work with these changes.
Also, I would like to change the order of parameters from what you had:
static function CreateLineRule($legendLabel, $filter, $strokeThickness, $color)
To:
static function CreateLineRule($legendLabel, $filter, $color, $strokeThickness)
This way the new parameter is on the end.
comment:6 by , 14 years ago
I take back my suggestion on changing the order of the parameters as the order you have matches the schema.
comment:7 by , 14 years ago
Description: | modified (diff) |
---|
comment:9 by , 14 years ago
Thank you for working on this. For me it's ok to close this enhancement.
comment:10 by , 14 years ago
I would like to update this ticket to refer to only the path issue as it is a defect. Could you please create a new ticket with your enhacement ideas?
comment:11 by , 14 years ago
Type: | enhancement → defect |
---|---|
Version: | 2.1.0 → 2.2.0 |
Sure, I would have differentiated the defect and the enhancement from the beginning. I've opened http://trac.osgeo.org/mapguide/ticket/1522
that addresses the "enhancement part"
comment:12 by , 14 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Closing this ticket as the defect has been fixed and the enhancement has been moved to ticket 1522
diff between the current version (ayerdefinitionfactory_20100226.php) and the proposed one