فهرست منبع

ogc:Filter add default tempate to fetch not implemented tag

Piotr Labudda 10 سال پیش
والد
کامیت
a629d3325d
1فایلهای تغییر یافته به همراه13 افزوده شده و 0 حذف شده
  1. 13 0
      SE/se-lib/Data_Source.php

+ 13 - 0
SE/se-lib/Data_Source.php

@@ -332,6 +332,12 @@ OGC_FILTER_XML_FILE;
 					$queryWhereBuilder->closeBlock($blockType);
 				}
 					break;
+				case 'not_implemented_tag': {
+					$tagName = V::get('name', '', $tag['attributes']);
+					DBG::_('DBG_DS_OGC', '>1', "Not Implemented tag '{$tagName}'", $queryWhereBuilder, __CLASS__, __FUNCTION__, __LINE__);
+					throw new HttpException("Not Implemented tag '{$tagName}'", 501);
+				}
+					break;
 				default: {
 					DBG::_('DBG_DS_OGC', '>1', "TODO: tag {$tag['tag']}", $queryWhereBuilder, __CLASS__, __FUNCTION__, __LINE__);
 					throw new Exception("TODO: tag {$tag['tag']}");
@@ -364,6 +370,13 @@ OGC_FILTER_XML_FILE;
 		<xsl:apply-templates/>
 	</xsl:template>
 
+	<xsl:template match="*">
+		<xsl:element name="not_implemented_tag">
+			<xsl:attribute name="name"><xsl:value-of select="name()"/></xsl:attribute>
+			<xsl:apply-templates/>
+		</xsl:element>
+	</xsl:template>
+
 	<xsl:template match="ogc:Or">
 		<xsl:element name="sql_filter_openBlock">
 			<xsl:attribute name="type"><xsl:value-of select="'or'" /></xsl:attribute>