Skip to content

Commit dea3b75

Browse files
committedSep 18, 2018
Fix Operations element
1 parent e005d6e commit dea3b75

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed
 

‎src/server/services/wfs/qgswfsgetcapabilities.cpp

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -431,8 +431,13 @@ namespace QgsWfs
431431
QDomElement operationsElement = doc.createElement( QStringLiteral( "Operations" )/*wfs:Operations*/ );
432432
featureTypeListElement.appendChild( operationsElement );
433433
//wfs:Query element
434-
QDomElement queryElement = doc.createElement( QStringLiteral( "Query" )/*wfs:Query*/ );
435-
operationsElement.appendChild( queryElement );
434+
QDomElement operationElement = doc.createElement( QStringLiteral( "Operation" ) );
435+
QDomText queryText = doc.createTextNode( "Query" );
436+
operationElement.appendChild( queryText );
437+
operationsElement.appendChild( operationElement );
438+
439+
// QDomElement queryElement = doc.createElement( QStringLiteral( "Query" )/*wfs:Query*/ );
440+
// operationsElement.appendChild( queryElement );
436441

437442
const QStringList wfsLayerIds = QgsServerProjectUtils::wfsLayerIds( *project );
438443
const QStringList wfstUpdateLayersId = QgsServerProjectUtils::wfstUpdateLayerIds( *project );
@@ -575,8 +580,12 @@ namespace QgsWfs
575580
//wfs:Operations element
576581
QDomElement operationsElement = doc.createElement( QStringLiteral( "Operations" )/*wfs:Operations*/ );
577582
//wfs:Query element
578-
QDomElement queryElement = doc.createElement( QStringLiteral( "Query" )/*wfs:Query*/ );
579-
operationsElement.appendChild( queryElement );
583+
// QDomElement queryElement = doc.createElement( QStringLiteral( "Query" )/*wfs:Query*/ );
584+
// operationsElement.appendChild( queryElement );
585+
QDomElement operationElement = doc.createElement( QStringLiteral( "Operation" ) );
586+
QDomText queryText = doc.createTextNode( "Query" );
587+
operationElement.appendChild( queryText );
588+
operationsElement.appendChild( operationElement );
580589
if ( wfstUpdateLayersId.contains( layer->id() ) ||
581590
wfstInsertLayersId.contains( layer->id() ) ||
582591
wfstDeleteLayersId.contains( layer->id() ) )

0 commit comments

Comments
 (0)
Please sign in to comment.