Skip to content

Commit

Permalink
Also use DCP for transaction (if available)
Browse files Browse the repository at this point in the history
Also QgsDebugMsg->Level
  • Loading branch information
elpaso committed Feb 22, 2018
1 parent 3ce8dc1 commit 31df608
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/providers/wfs/qgswfstransactionrequest.cpp
Expand Up @@ -23,20 +23,22 @@ QgsWFSTransactionRequest::QgsWFSTransactionRequest( const QgsWFSDataSourceURI &u

bool QgsWFSTransactionRequest::send( const QDomDocument &doc, QDomDocument &serverResponse )
{
QUrl url( mUri.requestUrl( QString( ) ) );
QUrl url( mUri.requestUrl( QStringLiteral( "Transaction" ) ) );
// We don't want/need REQUEST=Transaction
url.removeQueryItem( QStringLiteral( "REQUEST" ) );

QgsDebugMsg( doc.toString() );
QgsDebugMsgLevel( doc.toString(), 4 );

if ( sendPOST( url, QStringLiteral( "text/xml" ), doc.toByteArray( -1 ) ) )
{
QString errorMsg;
if ( !serverResponse.setContent( mResponse, true, &errorMsg ) )
{
QgsDebugMsg( mResponse );
QgsDebugMsg( errorMsg );
QgsDebugMsgLevel( mResponse, 4 );
QgsDebugMsgLevel( errorMsg, 4 );
return false;
}
QgsDebugMsg( mResponse );
QgsDebugMsgLevel( mResponse, 4 );
return true;
}
return false;
Expand Down

0 comments on commit 31df608

Please sign in to comment.