Skip to content

Commit 9083ec6

Browse files
committed
[wfs] Proper handling of DCP POST Uri
1 parent ef24e65 commit 9083ec6

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/providers/wfs/qgswfsdatasourceuri.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ QUrl QgsWFSDataSourceURI::requestUrl( const QString &request, const Method &meth
182182
}
183183
QUrl url( endpoint );
184184
url.addQueryItem( QStringLiteral( "SERVICE" ), QStringLiteral( "WFS" ) );
185-
if ( ! request.isEmpty() )
185+
if ( method == Method::Get && ! request.isEmpty() )
186186
url.addQueryItem( QStringLiteral( "REQUEST" ), request );
187187
return url;
188188
}

src/providers/wfs/qgswfstransactionrequest.cpp

+1-3
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,7 @@ QgsWFSTransactionRequest::QgsWFSTransactionRequest( const QgsWFSDataSourceURI &u
2323

2424
bool QgsWFSTransactionRequest::send( const QDomDocument &doc, QDomDocument &serverResponse )
2525
{
26-
QUrl url( mUri.requestUrl( QStringLiteral( "Transaction" ) ) );
27-
// We don't want/need REQUEST=Transaction
28-
url.removeQueryItem( QStringLiteral( "REQUEST" ) );
26+
QUrl url( mUri.requestUrl( QStringLiteral( "Transaction" ), QgsWFSDataSourceURI::Method::Post ) );
2927

3028
QgsDebugMsgLevel( doc.toString(), 4 );
3129

0 commit comments

Comments
 (0)