Permalink
Browse files

Fix for the problem with filter when using WMS TIME parameters (#3795)

  • Loading branch information...
1 parent 665c2a0 commit ca33352d0eb8296d52d59a8271726ac7e8c78639 @szekerest szekerest committed Feb 22, 2013
Showing with 4 additions and 4 deletions.
  1. +4 −4 maplayer.c
View
@@ -893,7 +893,7 @@ makeTimeFilter(layerObj *lp,
if (&lp->filter) {
/* if the filter is set and it's a sting type, concatenate it with
the time. If not just free it */
- if (lp->filter.type == MS_EXPRESSION) {
+ if (lp->filter.type == MS_STRING) {
pszBuffer = msStringConcatenate(pszBuffer, "((");
pszBuffer = msStringConcatenate(pszBuffer, lp->filter.string);
pszBuffer = msStringConcatenate(pszBuffer, ") and ");
@@ -930,7 +930,7 @@ makeTimeFilter(layerObj *lp,
pszBuffer = msStringConcatenate(pszBuffer, ")");
/* if there was a filter, It was concatenate with an And ans should be closed*/
- if(&lp->filter && lp->filter.type == MS_EXPRESSION) {
+ if(&lp->filter && lp->filter.type == MS_STRING) {
pszBuffer = msStringConcatenate(pszBuffer, ")");
}
@@ -947,7 +947,7 @@ makeTimeFilter(layerObj *lp,
return MS_FALSE;
if (numtimes >= 1) {
- if (&lp->filter && lp->filter.type == MS_EXPRESSION) {
+ if (&lp->filter && lp->filter.type == MS_STRING) {
pszBuffer = msStringConcatenate(pszBuffer, "((");
pszBuffer = msStringConcatenate(pszBuffer, lp->filter.string);
pszBuffer = msStringConcatenate(pszBuffer, ") and ");
@@ -1070,7 +1070,7 @@ makeTimeFilter(layerObj *lp,
/* load the string to the filter */
if (pszBuffer && strlen(pszBuffer) > 0) {
- if(&lp->filter && lp->filter.type == MS_EXPRESSION)
+ if(&lp->filter && lp->filter.type == MS_STRING)
pszBuffer = msStringConcatenate(pszBuffer, ")");
/*
if(lp->filteritem)

0 comments on commit ca33352

Please sign in to comment.